How can I enable SOAP Attachments?
ricmoore Apr 5, 2004 10:09 AMGreetings,
I am trying to send a SOAP message (with attachment(s)) using a JMS topic and a MessageListener. I am using JBoss 3.2.3. It works without the attachment, but if I try to add an attachment the operation fails. From the exception stack trace it appears that attachments are not enabled for my installation. (I infer this from the line:
DEBUG: Attachment support is enabled? false
in the exception trace).
I have tried searching for an answer in the Wiki & forum archives.
Below is the console exception trace, in case it might prove useful.
DEBUG: Extracting SpyConnectionFactory from reference
DEBUG: The GenericConnectionFactory is: GenericConnectionFactory:[server=org.jboss.mq.il.oil.OILServerIL@1fc2fb,connectionProperties={OIL_TCPNODELAY_KEY=yes, PingPeriod=60000, OIL_PORT_KEY=8090, ClientILService=org.jboss.mq.il.oil.OILClientILService, OIL_ADDRESS_KEY=198.6.217.231}]
DEBUG: Setting the clockDaemon's thread factory
DEBUG: Handing out ClientIL: org.jboss.mq.il.oil.OILClientILService
DEBUG: Waiting for the server to connect to me on port 2627
DEBUG: Create a SOAP message
DEBUG: getBundle(org.apache.axis,org.apache.axis.i18n,resource,null,...)
DEBUG: loadBundle: Ignoring MissingResourceException: Can't find bundle for base name org.apache.axis.resource, locale en_US
DEBUG: Created org.apache.axis.i18n.resource, linked to parent null
DEBUG: getBundle(org.apache.axis,org.apache.axis.utils,resource,null,...)
DEBUG: loadBundle: Ignoring MissingResourceException: Can't find bundle for base name org.apache.axis.utils.resource, locale en_US
DEBUG: loadBundle: Ignoring MissingResourceException: Can't find bundle for base name org.apache.axis.resource, locale en_US
DEBUG: Root package not found, cross link to org.apache.axis.i18n.resource
DEBUG: Root package not found, cross link to org.apache.axis.i18n.resource
DEBUG: org.apache.axis.i18n.resource::handleGetObject(attachEnabled)
DEBUG: Attachment support is enabled? false
DEBUG: Enter: SOAPPart ctor(FORM_SOAPENVELOPE)
DEBUG: org.apache.axis.i18n.resource::handleGetObject(setMsgForm)
DEBUG: Setting current message form to: FORM_SOAPENVELOPE (currentMessage is now org.apache.axis.message.SOAPEnvelope)
DEBUG: Exit: SOAPPart ctor()
DEBUG: Enter: SOAPPart::getAsSOAPEnvelope()
DEBUG: org.apache.axis.i18n.resource::handleGetObject(currForm)
DEBUG: current form is FORM_SOAPENVELOPE
DEBUG: Building attachment from the file from URL: file://localhost/C:/APSTS/Phase II/Software/cPath.bat
java.lang.NullPointerException
at org.apache.axis.Message.createAttachmentPart(Message.java:620)
at javax.xml.soap.SOAPMessage.createAttachmentPart(SOAPMessage.java:243)
at apsts.infobroker.SOAPMessageSource.send(SOAPMessageSource.java:169)
at apsts.infobroker.SOAPMessageSource.main(SOAPMessageSource.java:242)
Thanks, in advance, for any help.