axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thilina Gunarathne" <cset...@gmail.com>
Subject Re: Setting the Content-ID header for an MTOM attachment
Date Tue, 19 Sep 2006 20:29:17 GMT
Yes.. Possible.. He can do it at the client (using OperationClient)
program as well as at the service impl too :)....

  Then he'll be using Soap With Attachments.. Not MTOM...

Thanks,
~Thilina

On 9/20/06, Davanum Srinivas <davanum@gmail.com> wrote:
> Thilina,
>
> Can Yoram write a custom handler, get access to the message context
> and use the following method in MessageContext to set a custom
> attachment?
>
> public void addAttachment(String contentID, DataHandler dataHandler)
>
> -- dims
>
> On 9/19/06, Yoram Givon <yoram.givon@adamind.com> wrote:
> >
> > The reason I need to set the content-ID is that the Transcoding
> > web-service uses the content-id header to identify the attached content.
> > When the MTOM engine generates the content-id for me, there is no way
> > for me to tell the web service where the content is.
> >
> > When I used axis 1.4 for the same goal I just added an AttachmentPart
> > and then set the setConentID for it.
> >
> > I was just not able to find the equivalent way to do it with Axis2.
> >
> > Cheers,
> > Yoram
> >
> > -----Original Message-----
> > From: Thilina Gunarathne [mailto:csethil@gmail.com]
> > Sent: Tuesday, September 19, 2006 12:05 PM
> > To: axis-user@ws.apache.org
> > Subject: Re: Setting the Content-ID header for an MTOM attachment
> >
> > Hi Yoram,
> > You can use the OMText.getContentId()  to request the content id,
> > given that OMText object contains the binary attachment you want to
> > send.
> >
> > What is you use case..When using MTOM Axis2 will take care of  putting
> > the content-id in to the SOAP request appropriately according to the
> > specification, so that the server knows where the attachment is. I
> > don't see why somebody needs to access the content-id manually.
> >
> > ~Thilina
> >
> > On 9/19/06, Yoram Givon <yoram.givon@adamind.com> wrote:
> > >
> > >
> > >
> > >
> > > Hi All,
> > >
> > >
> > >
> > > I am using Axis2 to create a SOAP request to a web service which
> > performs
> > > Transcoding of a file I attached to the SOAP message using MTOM.
> > >
> > >
> > >
> > > My only problem is that I also have to pass the content-id of the
> > attachment
> > > as part of the SOAP request so the server will know where the file is.
> > >
> > >
> > >
> > > I have searched through the mailing list and the internet and was not
> > able
> > > so far to find a method to set the content-id header for an MTOM
> > attachment.
> > >
> > >
> > >
> > > Does any one know if there is a way to set the content-id header of an
> > MTOM
> > > attachment?
> > >
> > >
> > >
> > > Cheers,
> > >
> > >
> > >
> > > Yoram
> >
> >
> > --
> > http://webservices.apache.org/~thilina/
> > http://thilinag.blogspot.com/
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
>
>
> --
> Davanum Srinivas : http://www.wso2.net (Oxygen for Web Service Developers)
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
http://webservices.apache.org/~thilina/
http://thilinag.blogspot.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message