I manage to setup logging. Based on the log of Content-Disposition it seems 
fine.


Code used to create and set Content-Disposition in short:

final SwiftObject object = cloudFilesClient.newSwiftObject();
object.setPayload(new ProgressInputStream(fileUpload, uploadProgress));
object.getPayload().getContentMetadata().setContentDisposition(MessageFormat.format("attachment;
 filename=\"{0}\"", fileName));


Jclouds log for Content-Disposition shows:

2014-01-07 11:40:44.762 org.jclouds.logging.slf4j.SLF4JLogger.logDebug:59 [main]
DEBUG: >> Content-Disposition: attachment; filename="cöwböys änd åliens.png"

That was the only reference of Content-Disposition in the log.


And the result for Content-Disposition "cöwböys änd åliens.png" in the 
Rackspace cdn Content-Disposition is "cöwböys änd åliens.png".


I tried setting the cdn file name to "cöwböys änd åliens.png" and that works. 
So only header gets malformed.

- Kalle -

________________________________________
Lähettäjä: Andrew Phillips [[email protected]]
Lähetetty: 7. tammikuuta 2014 11:38
Vastaanottaja: [email protected]
Aihe: Re: VS: Setting Content-Disposition header containing Finnish     
alphabets å, ä or ö

> then I will familiarize myself with either of those. Basically I
> have just followed the upload by the way provided in examples and
> tried both SwiftObject and Blobs.

Do you mean the examples in the jclouds-examples repo [1]? As far as
configuring logging, this good blog by Everett might help [2].

ap

[1] https://github.com/jclouds/jclouds-examples
[2] http://blog.phymata.com/2012/08/18/logging-in-jclouds/

Reply via email to