Return-Path: X-Original-To: apmail-axis-java-dev-archive@www.apache.org Delivered-To: apmail-axis-java-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6358E87B8 for ; Wed, 10 Aug 2011 21:27:53 +0000 (UTC) Received: (qmail 47766 invoked by uid 500); 10 Aug 2011 21:27:52 -0000 Delivered-To: apmail-axis-java-dev-archive@axis.apache.org Received: (qmail 47553 invoked by uid 500); 10 Aug 2011 21:27:51 -0000 Mailing-List: contact java-dev-help@axis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@axis.apache.org Delivered-To: mailing list java-dev@axis.apache.org Received: (qmail 47544 invoked by uid 99); 10 Aug 2011 21:27:51 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Aug 2011 21:27:51 +0000 X-ASF-Spam-Status: No, hits=-2000.8 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Aug 2011 21:27:48 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 46CC1B64EA for ; Wed, 10 Aug 2011 21:27:27 +0000 (UTC) Date: Wed, 10 Aug 2011 21:27:27 +0000 (UTC) From: "Andreas Veithen (JIRA)" To: java-dev@axis.apache.org Message-ID: <1107612664.25502.1313011647286.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <2075622569.6863.1307627879238.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (AXIS2-5067) content-type header is not generated with SAAJ API MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/AXIS2-5067?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Andreas Veithen updated AXIS2-5067: ----------------------------------- Fix Version/s: 1.6.1 > content-type header is not generated with SAAJ API > -------------------------------------------------- > > Key: AXIS2-5067 > URL: https://issues.apache.org/jira/browse/AXIS2-5067 > Project: Axis2 > Issue Type: Bug > Components: saaj > Affects Versions: 1.6.0 > Reporter: Ivan > Assignee: Andreas Veithen > Fix For: 1.6.1, 1.7.0 > > Attachments: AXIS2-5067-01.patch, AXIS2-5067.patch > > > In the scenario below : > SOAPMessage msg = MessageFactory.newInstance().createMessage(); > SOAPPart sp = msg.getSOAPPart(); > SOAPEnvelope envelope = sp.getEnvelope(); > SOAPBody bdy = envelope.getBody(); > SOAPBodyElement sbe = bdy.addBodyElement(envelope.createName("Body1", "ns1", "http://www.helloworld.org")); > sbe.addChildElement(envelope.createName("c1", "ns1", "http://www.helloworld.org")).addTextNode("HelloWorld"); > > URL url = new File("D:\\opensource\\axis2\\axis2\\axis2-1.5\\modules\\saaj\\pom.xml").toURI().toURL(); > AttachmentPart attachmentPart = msg.createAttachmentPart(new DataHandler(url)); > attachmentPart.setContentType("text/xml"); > msg.addAttachmentPart(attachmentPart); > msg.saveChanges(); > If we use SOAPMessage.writeTo method to write to the message to an servlet outputstream, those boundary, content-id values are generated on the fly. And for the client applications, there is no way to get the corresponding content-type header. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org For additional commands, e-mail: java-dev-help@axis.apache.org