Scala Spray serve a file attachment -
how serve file attachment spray. need set individual content headers, or there improve way of doing it. if so, how best handle content length given compression maybe enabled.
ok needed add together own custom headers, content length seems take care of itself.
respondwithmediatype(mediatypes.`application/vnd.openxmlformats-officedocument.presentationml.presentation`) { respondwithheader(httpheaders.`content-disposition`.apply("attachment", map("filename" -> "myfile.pptx"))) { scala spray
No comments:
Post a Comment