问题
I am trying to Set an Attachment as below:
<set-attachment attachmentName="abc" value="#[contents]" contentType="#[fileType]" doc:name="Attachment"/>
The contentType happens to be application/pdf. I get the following error for .pdf and .doc files. text/plain files go through ok.
- no object DCH for MIME type application/pdf (javax.activation.UnsupportedDataTypeException) javax.activation.ObjectDataContentHandler:891 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/activation/UnsupportedDataTypeException.html)
- Could not write attachments. (org.apache.cxf.interceptor.Fault) org.apache.cxf.interceptor.AttachmentOutInterceptor$AttachmentOutEndingInterceptor:105 (null)
Any idea how to allow for application/pdf and/or .doc files for that matter? Help would be greatly appreciated.
回答1:
This was a problem with some of the dependencies, I have just tried with 3.5.2 and it works fine for application/pdf. Please try downloading the lastest and greatest version.
来源:https://stackoverflow.com/questions/26835693/mule-no-object-dch-for-mime-type-application-pdf