List Info

Thread: Sending Attachments using WSIF




Sending Attachments using WSIF
user name
2006-12-01 08:41:10
Hi Alex 
Thanks for replying 

I am not sure of your entire questions my comments included 

in general WSIF sits on top of WSIF provider such as axis or
apache soap
and can do only as much as provider can do. did  were you
able to send
attachments using the underlying provider (was it AXIS1?)
directly?

----we are using axis 1.2 and were able to send attachment
to it using SOAP UI toolkit.

maybe you could try different version of soap toolkit? 

-- i dont understand what you mean by this ?

and what exactly version of WSIF did you try  - was it the
latest?

-- no we are not using the latest version.We are using wsif
1.0. Do you think shifting to latest version would make any
difference.
    

Also i would like to ask you whether the following scenario
will work or not
We need to send attachments to webservice method which does
not define int its parameters any thing related to
attachment to be precise datahandler
Only wsdl binding sections includes attachment
information.Will this work without service method specifying
the parameter for attachment.
If so how one can achieve this using wsif 

thanks a lot 
Amey




-----Original Message-----
From: Aleksander Slominski [mailto:aslomcs.indiana.edu]
Sent: Thursday, November 30, 2006 11:09 PM
To: wsif-userws.apache.org
Subject: Re: Sending Attachments using WSIF


Amey Rokde wrote:
> Hi All
> This is my second email concerning sending of
attachments using WSIF
> and axis as service provider.I have used the same
sample code
> specified on wsif website 
> for sending attachments
>  
> the sample code looks like
>  
>              final DataHandler dh = new DataHandler(
"sample content
> ","text/plain" );
>             final WSIFServiceFactory factory =
> WSIFServiceFactory.newInstance();
>             final WSIFService service =
factory.getService(
> "http://my.wsdl
<http://my.wsdl/>",null, null, null, null );
>             final WSIFOperation op =
> service.getPort().createOperation(
"testAttachment" );
>             final WSIFMessage in =
op.createInputMessage();
>             in.setObjectPart(
"param1","myparam");
>             in.setObjectPart( "attch", dh );
>             op.executeInputOnlyOperation( in );
>  
> snippet of my wsdl file.
>  
>      <wsdl:binding>
>             <wsdl:operation
name="testAttachment">
>             <wsdlsoap:operation
soapAction=""/>
>             <wsdl:input
name="testAttachmentRequest">
>                 <mime:multipartRelated>
>                     <mime:part>
>                             <wsdlsoap:body
> encodingStyle="http:
//schemas.xmlsoap.org/soap/encoding/"
>                                           
> namespace="http://xxx/Servi
ces/WSProvider" use="encoded"/>
>                     </mime:part>
>                     <mime:part>
>                             <wsdlsoap:content
part="attch"
> type="text/plain"/>
>                     </mime:part>
>                 </mime:multipartRelated>
>             </wsdl:input>
>             <wsdl:output
name="testAttachmentResponse">
>                 <wsdlsoap:body
> encodingStyle="http:
//schemas.xmlsoap.org/soap/encoding/"
>                               
> namespace="http://xxxx/Ser
vices/WSProvider" use="encoded"/>
>             </wsdl:output>
>         </wsdl:operation>
>     </wsdl:binding>
>  
>  
> Could anybody help me what i am missing as using this
defintion and
> code above still i am not able to recieve attachments.I
tried sending
> attachments using SOAP UI and it works perfectly.So it
must be
> something that i missing over here
in general WSIF sits on top of WSIF provider such as axis or
apache soap
and can do only as much as provider can do. did  were you
able to send
attachments using the underlying provider (was it AXIS1?)
directly?
maybe you could try different version of soap toolkit? and
what exactly
version of WSIF did you try  - was it the latest?

best,

alek

-- 
The best way to predict the future is to invent it - Alan
Kay


------------------------------------------------------------
---------
To unsubscribe, e-mail: wsif-user-unsubscribews.apache.org
For additional commands, e-mail: wsif-user-helpws.apache.org


------------------------------------------------------------
---------
To unsubscribe, e-mail: wsif-user-unsubscribews.apache.org
For additional commands, e-mail: wsif-user-helpws.apache.org

Sending Attachments using WSIF
user name
2006-12-01 15:33:41
Amey Rokde wrote:
> Hi Alex 
> Thanks for replying 
>
> I am not sure of your entire questions my comments
included 
>
> in general WSIF sits on top of WSIF provider such as
axis or apache soap
> and can do only as much as provider can do. did  were
you able to send
> attachments using the underlying provider (was it
AXIS1?) directly?
>
> ----we are using axis 1.2 and were able to send
attachment to it using SOAP UI toolkit.
>   
is it the same version as it is used by WSIF (see lib
directory)?
> maybe you could try different version of soap toolkit? 
>
> -- i dont understand what you mean by this ?
>
> and what exactly version of WSIF did you try  - was it
the latest?
>
> -- no we are not using the latest version.We are using
wsif 1.0. Do you think shifting to latest version would make
any difference.
>   
there was only 2.x version of WSIF - the latest version had
several
fixes to work with recent AXIS1 and WSDL4J
check it out from SVN or http://people.
apache.org/dist/ws/wsif/
> Also i would like to ask you whether the following
scenario will work or not
> We need to send attachments to webservice method which
does not define int its parameters any thing related to
attachment to be precise datahandler
> Only wsdl binding sections includes attachment
information.Will this work without service method specifying
the parameter for attachment.
> If so how one can achieve this using wsif 
>   
the service that receives message sent by you will need to
understand
attachments.

HTH,

alek
>
> -----Original Message-----
> From: Aleksander Slominski [mailto:aslomcs.indiana.edu]
> Sent: Thursday, November 30, 2006 11:09 PM
> To: wsif-userws.apache.org
> Subject: Re: Sending Attachments using WSIF
>
>
> Amey Rokde wrote:
>   
>> Hi All
>> This is my second email concerning sending of
attachments using WSIF
>> and axis as service provider.I have used the same
sample code
>> specified on wsif website 
>> for sending attachments
>>  
>> the sample code looks like
>>  
>>              final DataHandler dh = new
DataHandler( "sample content
>> ","text/plain" );
>>             final WSIFServiceFactory factory =
>> WSIFServiceFactory.newInstance();
>>             final WSIFService service =
factory.getService(
>> "http://my.wsdl
<http://my.wsdl/>",null, null, null, null );
>>             final WSIFOperation op =
>> service.getPort().createOperation(
"testAttachment" );
>>             final WSIFMessage in =
op.createInputMessage();
>>             in.setObjectPart(
"param1","myparam");
>>             in.setObjectPart( "attch", dh
);
>>             op.executeInputOnlyOperation( in );
>>  
>> snippet of my wsdl file.
>>  
>>      <wsdl:binding>
>>             <wsdl:operation
name="testAttachment">
>>             <wsdlsoap:operation
soapAction=""/>
>>             <wsdl:input
name="testAttachmentRequest">
>>                 <mime:multipartRelated>
>>                     <mime:part>
>>                             <wsdlsoap:body
>> encodingStyle="http:
//schemas.xmlsoap.org/soap/encoding/"
>>                                           
>> namespace="http://xxx/Servi
ces/WSProvider" use="encoded"/>
>>                     </mime:part>
>>                     <mime:part>
>>                             <wsdlsoap:content
part="attch"
>> type="text/plain"/>
>>                     </mime:part>
>>                 </mime:multipartRelated>
>>             </wsdl:input>
>>             <wsdl:output
name="testAttachmentResponse">
>>                 <wsdlsoap:body
>> encodingStyle="http:
//schemas.xmlsoap.org/soap/encoding/"
>>                               
>> namespace="http://xxxx/Ser
vices/WSProvider" use="encoded"/>
>>             </wsdl:output>
>>         </wsdl:operation>
>>     </wsdl:binding>
>>  
>>  
>> Could anybody help me what i am missing as using
this defintion and
>> code above still i am not able to recieve
attachments.I tried sending
>> attachments using SOAP UI and it works perfectly.So
it must be
>> something that i missing over here
>>     
> in general WSIF sits on top of WSIF provider such as
axis or apache soap
> and can do only as much as provider can do. did  were
you able to send
> attachments using the underlying provider (was it
AXIS1?) directly?
> maybe you could try different version of soap toolkit?
and what exactly
> version of WSIF did you try  - was it the latest?
>
> best,
>
> alek
>
>   


-- 
The best way to predict the future is to invent it - Alan
Kay


------------------------------------------------------------
---------
To unsubscribe, e-mail: wsif-user-unsubscribews.apache.org
For additional commands, e-mail: wsif-user-helpws.apache.org

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )