This is my code - 
Setup -

ConfigurationContext config 
=ConfigurationContextFactory.createConfigurationContextFromFileSystem(null,
                        AXIS2_CONFIG_FILE_LOCATION);
// serviceUrl of the form http://host:8080/app/services/session         
serviceStub = new SessionServiceStub( config, serviceUrl);


And later calling the service - 

GetAvailableConnectionsDocument request = 
GetAvailableConnectionsDocument.Factory.newInstance();
GetAvailableConnectionsResponse response = serviceStub.getAvailableConnections( 
request );

The call to getAvailableConnections results in the NullPointer. As far as I can 
see this is the same as in the documentation. It is loading the axis2.config 
file as I've had to comment out the addressing module from that - could this be 
the problem? I am using the supplied axis2.xml with only that change, I've also 
tried without supplying the config (ie. new SessionServiceStub(serviceUrl) ) 
and got the same error.

-----Original Message-----
From: Marc F. [mailto:[EMAIL PROTECTED] 
Sent: 28 November 2008 02:02
To: [email protected]
Subject: Re: Client stubs NullPointer Exception




Chris Tinning wrote:
> 
> I am in the process of trying to migrate a webservice client to axis2
> (1.4.1). I've generated some xmlbean stub classes and have started
> testing but get a NullPointer in the finally block of the call in the
> generated stub - transportOut is null.
> 
>  
> 
> finally{
> 
> _messageContext.getTransportOut().getSender().cleanup(_messageContext);
> 
> }
> 
>  
> 
> I've have all the required jar files in the classpath and am just using
> the default axis2.xml config file.  Missing jar files seems be the
> common thing that results in this problem from the numerous searches
> I've made.
> 
>  
> 
> Can anybody help or point me to some more detailed information on
> setting up an xmlbean client?
> 
>  
> 
> Thanks in advance
> 
>  
> 
> Chris Tinning
> 
> 
> ________________________________________________________________________
> This e-mail has been scanned for viruses, however, No liability is
> accepted for any viruses contained in this message or any of its
> attachments and it is the recipient?s liability to scan this message and
> its attachment for the same.
> ________________________________________________________________________
> 

I have been using Axis2 1.4.1 with XML Beans, and I´ve never had the problem
you are having. Are you sure you are using the client stub correctly? Let me
see your code, post your code.
-- 
View this message in context: 
http://www.nabble.com/Client-stubs-NullPointer-Exception-tp20721127p20727979.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


________________________________________________________________________
This e-mail has been scanned for viruses, however, No liability is accepted for 
any viruses contained in this message or any of its attachments and it is the 
recipient?s liability to scan this message and its attachment for the same.
________________________________________________________________________

Reply via email to