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 EA0AC4366 for ; Fri, 10 Jun 2011 21:06:20 +0000 (UTC) Received: (qmail 76463 invoked by uid 500); 10 Jun 2011 21:06:20 -0000 Delivered-To: apmail-axis-java-dev-archive@axis.apache.org Received: (qmail 76274 invoked by uid 500); 10 Jun 2011 21:06:20 -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 76013 invoked by uid 99); 10 Jun 2011 21:06:19 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Jun 2011 21:06:19 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_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; Fri, 10 Jun 2011 21:06:19 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id EBB6E10DCE7 for ; Fri, 10 Jun 2011 21:05:58 +0000 (UTC) Date: Fri, 10 Jun 2011 21:05:58 +0000 (UTC) From: "Andreas Veithen (JIRA)" To: java-dev@axis.apache.org Message-ID: <1201832404.12198.1307739958962.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 [ https://issues.apache.org/jira/browse/AXIS2-5067?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Andreas Veithen updated AXIS2-5067: ----------------------------------- Affects Version/s: (was: 1.7.0) 1.6.0 > 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 > Attachments: 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