Re: Client Exception: N7axiscpp19AxisEngineExceptionE

2006-02-20 Thread John Hawkins

Are you getting anything sent across
the wire?

AND: If you are not then please can
check that you have the correct version of xerces in your lib path.







Rob Redmon [EMAIL PROTECTED]

17/02/2006 22:03



Please respond to
Apache AXIS C User List axis-c-user@ws.apache.org





To
axis-c-user@ws.apache.org


cc



Subject
Client Exception: N7axiscpp19AxisEngineExceptionE









I've tried creating stubs for 3 different simple WebService providers
and I'm always getting this exception:
N7axiscpp19AxisEngineExceptionE

I also tried the Calculator client example (w/NO deployed matching
webservice on localhost) to see what error I'd arrive at and I got the
same Exception.
My relevant environment variables are:
AXISCPP_DEPLOY=/home/robr/packages/axis-c-1.5.0-linux-bin/

Here's a copy of my $AXISCPP_DEPLOY/etc/axiscpp.conf
LogPath:/home/robr/log/AxisLog
#WSDDFilePath:/home/obj/etc/server.wsdd
ClientLogPath:/home/robr/log/AxisClientLog
#ClientWSDDFilePath:/home/obj/etc/client.wsdd
XMLParser:/home/robr/lib/libaxis_xerces.so
Transport_http:/home/robr/lib/libhttp_transport.so
Channel_HTTP:/home/robr/lib/libhttp_channel.so
#Channel_HTTP_SSL:/home/samisa/autoCVS/cvsAutoBuild/deploy/lib/libaxis3_transport_ssl_channel.so

-- 
Rob Redmon
NOAA/NGDC
325 Broadway E/GC2
Boulder, Colorado 80305
Tel: (303) 497-4331
Fax: (303) 497-6513
[EMAIL PROTECTED]

Engineering is the art of making what you want from things you can
get. 




linux distribution don't have ssl support?

2006-02-20 Thread Tao Yang

Hi,

I am trying to get Axis C++ 1.5 on linux as client to interact
with Axis 1.3 server (java, deployed on tomcat 5) this morning. I
notice a few things:
1) The installation document mentioned following configuration:

Transport_http:/usr/local/axiscpp_deploy/lib/libaxis3_transport.so
Channel_HTTP:/usr/local/axiscpp_deploy/lib/libaxis3_transport_channel.so
XMLParser:/usr/local/axiscpp_deploy/lib/libaxis_xercesc.so
ClientWSDDFilePath:/usr/local/axiscpp_deploy/etc/client.wsdd
ClientLogPath:/usr/local/axiscpp_deploy/log/AxisClientLog

which is a bit confusing since I cannot find neither 
libaxis3_transport.so nor libaxis3_transport_channel.so in 
the tar gz'ed file - axis-c-linux-current-bin.tar.gz

I can only find following libs:


[EMAIL PROTECTED] axis4Lin]$ ls axis-c-1.5.0-linux-bin/lib/
axis  libaxiscpp_mod.solibdoclitfault.so
axisjava  libaxiscpp_mod.so.1  libelement.so
libarray.so   libaxiscpp_mod.so.1.5.0  libenumeration.so
libaxis_clientC.solibaxis_server.solibhttp_channel.so
libaxis_clientC.so.1  libaxis_server.so.1  libhttp_channel.so.1
libaxis_clientC.so.1.5.0  libaxis_server.so.1.5.0  libhttp_channel.so.1.5.0
libaxis_client.so libaxis_xerces.solibhttp_transport.so
libaxis_client.so.1   libaxis_xerces.so.1  libhttp_transport.so.1
libaxis_client.so.1.5.0   libaxis_xerces.so.1.5.0  
libhttp_transport.so.1.5.0

libaxiscpp_mod2.solibbase.so   libref.so
libaxiscpp_mod2.so.1  libbench.so  librpcfault.so
libaxiscpp_mod2.so.1.5.0  libcalculator.so libtransportProperties.so
[EMAIL PROTECTED] axis4Lin]$
Plus, the SSL channel also seems missing - no 
libaxis3_transport_ssl_channel.so

found neither.

Do I have to re-built it by myself?

Another thing is there is no deploy dir found in the linux bin distro as 
in window's.
And the content of deploy dir in window's distro seems to me are for 
linux. Am I

missing something here?

At last, one important question is: does Axis C++ work with Axis (java) 
as I would

expect?

Thanks,
Tao


SIGABRT on Axis C++ client

2006-02-20 Thread Tao Yang

HI,

I was experimenting with Axis C++ 1.5 this afternoon to writing a client 
to talk to a Axis Java web service deployed in tomcat.
the code is pretty simple - though I call it Index - which only send a 
string to the web service which later could be pull back through another 
web service.


However, while I running it, I got:
Program received signal SIGABRT, Aborted.
[Switching to Thread -1208109376 (LWP 27284)]
0x0065a402 in __kernel_vsyscall ()
(gdb) backtrace
#0  0x0065a402 in __kernel_vsyscall ()
#1  0x04699118 in raise () from /lib/libc.so.6
#2  0x0469a888 in abort () from /lib/libc.so.6
#3  0x06ca6577 in __cxa_call_unexpected () from /usr/lib/libstdc++.so.5
#4  0x06ca65c4 in std::terminate () from /usr/lib/libstdc++.so.5
#5  0x06ca679c in __cxa_rethrow () from /usr/lib/libstdc++.so.5
#6  0x004769bf in initialize_module () from 
/opt/axiscpp/lib/libaxis_client.so

#7  0x00477f67 in axiscpp::Call::Call ()
  from /opt/axiscpp/lib/libaxis_client.so
#8  0x004629d2 in axiscpp::Stub::Stub$base ()
  from /opt/axiscpp/lib/libaxis_client.so
#9  0x080505f3 in Index (this=0xbfafd3b0)
   at ../../simmanager/searchClient/src/ws/Index.cpp:19
#10 0x0804ea99 in SearchDialog (this=0xbfafd374, parent=0x0)
   at ../../simmanager/searchClient/src/gui/SearchDialog.cpp:39
#11 0x0804cd28 in main (argc=1, argv=0xbfafd4b4)
   at ../../simmanager/searchClient/src/main.cpp:44

the exception come out  from following code at the line with a  prefix:
Index::Index(const char* pchEndpointUri, AXIS_PROTOCOL_TYPE eProtocol)
:Stub(pchEndpointUri, eProtocol)
{
}

Index::Index()
:Stub( , APTHTTP1_1)
{
   
m_pCall-setEndpointURI(http://172.16.53.33:8080/simdesk/services/Index;);

}

Index::~Index()
{
}

I wonder what's I am missing? I do setup following the instruction (the 
AXISCPP_DEPLOY, axiscpp.conf).

my axiscpp.conf looks like this:
ClientLogPath:/opt/axiscpp/log/AxisClientLog
XMLParser:/usr/lib/libxerces-c.so
Transport_http:/opt/axiscpp/lib/libhttp_transport.so
Channel_HTTP:/opt/axiscpp/lib/libhttp_channel.so

Thanks a lot for your help!
Tao



RE: SSL Client

2006-02-20 Thread Iwan Tomlow
One thing I forgot to mention: to prevent the crash, I also had to change
the following in xml\XMLParserXerces.cpp:

Ln 79:
const AnyElement* XMLParserXerces::next(bool isCharData)
{
bool bCanParseMore = false;
if(!m_bFirstParsed)
{
-   m_pParser-parseFirst(*m_pInputSource, m_ScanToken);
-   m_bFirstParsed = TRUE;
+   m_bFirstParsed = m_pParser-parseFirst(*m_pInputSource,
m_ScanToken);
+   if (!m_bFirstParsed)
+   return NULL;
}

Kind regards,
Iwan Tomlow

-Original Message-
From: Iwan Tomlow [mailto:[EMAIL PROTECTED] 
Sent: dinsdag 21 februari 2006 8:53
To: 'Apache AXIS C User List'
Cc: 'axis-c-dev@ws.apache.org'
Subject: RE: SSL Client


Hello,

Just to let you know I managed to get the SSL configured using
vc\transport\Axis3\HTTPSSLChannel.
However, I think I stumbled over a bug in the transport layer, because the
Axis-client was always crashing when using SSL. Can't seem to access the
CVS-sources at the moment, so I don't know if it has been noticed and fixed
already, so I'll post it here.

Debugging showed the Xerces-parser was using bogus data to throw a
UTF8FormatException, so the following code in ClientAxisEngine.cpp failed:

Ln 223:
int nSoapVersion = m_pDZ-getVersion ();
if (nSoapVersion == VERSION_LAST) /* version not supported */
{
Status = AXIS_FAIL;
//  return AXIS_FAIL;

The status was indeed AXIS_FAIL, but because the return-statement is
commented out, the subsequent call to m_pDZ-getHeader (); caused a crash
in the Xerces parser.

I finally tracked it down to what I think is a bug in the getBytes() in
axis3/HTTPTransport.cpp (Ln 588). Probably because of using SSL, what I was
receiving after the HTTP-header was always a first chunk containing *only*
the chunk size + CRLF, nothing more. This caused the following code to never
execute extra reads to really get any of the chunk data:

//There might be chunk extensions in there too but we may
not need them
unsigned int endOfChunkData =
m_strReceived.find( \r\n);

// make sure we have read at least some part of the message
if ( endOfChunkData == std::string::npos)
{

endOfChunkData was 3 in this case (data was 4db\r\n), and data was never
read. I tried to fix it like this, which worked for me (not at all sure that
this is a complete and trustworhty fix); this should make sure at least some
of the actual chunk data is read before continuing:

// make sure we have read at least some part of the message
-   if( endOfChunkData == std::string::npos)
+   std::string::size_type nLen =
m_strReceived.length ();
+   if ( endOfChunkData == std::string::npos ||
+   endOfChunkData + 2 = nLen )
{
iIterationCountdown = 100;

do
{
m_pszRxBuffer [0] = '\0';
*m_pActiveChannel 
m_pszRxBuffer;

if( strlen( m_pszRxBuffer)
== 0)
{

iIterationCountdown--;
}
else
{
iIterationCountdown
= 100;
}

-   m_strReceived =
m_pszRxBuffer;
-   endOfChunkData =
m_strReceived.find( \r\n);
-   } while( endOfChunkData ==
std::string::npos  iIterationCountdown  0);
+   m_strReceived +=
m_pszRxBuffer;
+   nLen = m_strReceived.length
();
+   endOfChunkData =
m_strReceived.find(\r\n);
+   } while( ( endOfChunkData ==
std::string::npos || endOfChunkData + 2 = nLen ) 
+   
iIterationCountdown  0);
}

Kind regards,
Iwan Tomlow


-Original Message-
From: Iwan Tomlow [mailto:[EMAIL PROTECTED] 
Sent: vrijdag 17 februari 2006 16:31
To: 'axis-c-user@ws.apache.org'
Subject: SSL Client


Hi, I've been happily using Axis C++ 1.5 for client development, but now
urgently (and unwarned) need to be able to access the webserver over https.
I know it should be possible to link OpenSSL with Axis, but seem to be
unable 

Re: Consuming Axis2 webservice with c# client?

2006-02-20 Thread Justin Schoeman
Thanks to everybody for your help.  Converting 'type=' to 'xsi:type=' 
does allow the c# client to handle the response.


I have filed a bug report on Jira:
https://issues.apache.org/jira/browse/AXIS2-455

Hopefully this gets attended to soon.

Does anybody perhaps know where in the source code this type attribute 
gets generated.  I would like to do a quick fix to get our system 
operational ASAP...


Thanks!

Justin

Simon Fell wrote:
xml schema type attribute is serialized with wrong namespace (should be 
http://www.w3.org/2001/XMLSchema-instance, is currently not namespace 
qualified).


to test it, you could write a quick jsp that returns the modifed 
response and point your C# client to that.


Cheers
Simon


-Original Message-
From: Justin Schoeman [mailto:[EMAIL PROTECTED]
Sent: Sat 2/18/2006 11:33 AM
To: axis-user@ws.apache.org
Cc: Simon Fell
Subject: Re: Consuming Axis2 webservice with c# client?

All server code is autogenerated by Axis2 0.94 WSDL2java.  Could you
perhaps give me a detailed description that I can use to log the bug.
Unfortunately, I do not really understand the differences, and what they
mean.

Do you think there amy be some other workaround, or maybe a simple way
to test that this really does solve the problem?

Thanks,

Justin


Simon Fell wrote:
  Do you have code that adds the type attribute, or are you letting 
axis do it ? (if the later, then you'll need to log a bug in JIRA)

 
  Cheers
  Simon
 
 
  -Original Message-
  From: Justin Schoeman [mailto:[EMAIL PROTECTED]
  Sent: Sat 2/18/2006 11:12 AM
  To: axis-user@ws.apache.org
  Cc: Simon Fell
  Subject: Re: Consuming Axis2 webservice with c# client?
  
  If that is the case, how do I convince the Axis server to append the

  'xsi:' to the type?  Is there a simple way, or do I need to hack the
  generated Axis code?
 
  Thanks,
 
  Justin
 
  Simon Fell wrote:
 
 type=GenericDeviceID should be xsi:type=GenericDeviceID
 
 Cheers
 Simon
 
 
 -Original Message-
 From: Justin Schoeman [mailto:[EMAIL PROTECTED]
 Sent: Fri 2/17/2006 8:08 AM
 To: axis-user@ws.apache.org
 Subject: Re: Consuming Axis2 webservice with c# client?
 
 The WSDL and XSD files are attached.  I had to edit the WSDL from the
 published version by filling in the soapAction name for the operations
 that we use.  I am not sure of the significance of this field, and why
 it was left out in the original service, but without it, the generated
 clients get EPR not found errors.  Modifying this wouldn't cause this
 problem though, would it?
 
 The WSDL files come from a standards body, and I am not sure if they
 were generated from any specific application.
 
 Thanks!
 
 Justin
 
 
 Anne Thomas Manes wrote:
   WSDL?
  
   On 2/17/06, *Justin Schoeman* [EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED] wrote:
  
   Further information, we just managed to get the debug messages
 out, and
   got the extended error:
  
   Unhandled Exception: System.InvalidOperationException: There is
 an error
   in XML document (1, 877). --- 
System.InvalidOperationException : The

   specified type is abstract: name='DeviceID',
   namespace='http://www.nrs.eskom.co.za/xmlvend/base/2.0/schema', at
   clientID xmlns='
 http://www.nrs.eskom.co.za/xmlvend/base/2.0/schema'.
  
   However, if you look at the generated xml, the full field is:
   clientID xmlns=http://www.nrs.eskom.co.za/xmlvend/base/2.0/schema
   http://www.nrs.eskom.co.za/xmlvend/base/2.0/schema
   type=GenericDeviceID id=12345 /
  
   so the very next attribute sets the explicit type.  Surely 
this is an

   acceptable response?
  
   Thanks,
  
   Justin
  
  
   Justin Schoeman wrote:
 Hi all,

 I seem to remember a discussion on this a while ago, but cannot
   seem to
 find it now.

 I am trying to use an Axis2 web service (generated from WSDL)
 from a
 Visual C# client (also generated from the WSDL.  Everything 
works

   fine
 until the client starts parsing the response XML, when it gives
   an error
 'There is an error in XML document(1,877)'. Position 877 in the
   response
 xml is the first character name of the first element 
withing the

   complex
 return type.   The start of the xml is included below.  If
   anybody has
 any ideas, please let me know!

 Thanks!

 Justin

 XML Response:
 ?xml version=' 1.0' encoding='utf-8'?
 soapenv:Envelope
 xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
 xmlns:wsa= http://schemas.xmlsoap.org/ws/2004/08/addressing;
 soapenv:Header
 wsa:Action
 mlns:wsa=http://schemas.xmlsoap.org/ws/2004/08/addressing
  
 http://schemas.xmlsoap.org/ws/2004/08/addressingConfirmCustomerRequest/wsa:Action


 wsa:ReplyTo
 

JNI

2006-02-20 Thread Paul Michael Reilly
I have now painfully learned to use the Tomcat shared area to supply
JNI code for my web application.  However there are still a few
questions that linger:

1) Using the Axis 1.3 (binary distribution) webapp, I modified
   EchoHeaders (as shown below) to load a shared library which
   predictably works only once as I now understand because of the
   class loading issue.  Subsequent attempts to rerun the EchoHeaders
   service fails with the response indicated below.  What I don't
   understand is why the exception is not caught by EchoHeaders.jws
   instead of Axis such that I'd see took exc.

2) (More of a Tomcat issue) Using the
   .../tomcat/shared/... directories to contain classes and jarballs
   containing JNI seriously breaks the loose coupling between Tomcat
   and a webapp.  Where deploying a war file is simple, reliable and
   satisfying on each release of the app, dealing with getting the
   webapp that consumes JNI code deployed or updated is a multi stage,
   tightly coupled process and requires restarting the container
   (unless I have overlooked some Tomcat provided feature to
   auto-reload shared jar files or classes).  So I wonder why Tomcat
   does not treat this as an issue/bug and fix it in the future.
   Perhaps it is in the plan.

-pmr


EchoHeaders.jws:

...
public String jni() {
String result = failed;
try {
System.loadLibrary(nativelib);
result = worked;
} catch ( Exception exc ) {
savedExc = (Throwable) exc;
result = took exc
}

return result;
}

...


Axis response:

soapenv:Envelope
  soapenv:Body
soapenv:Fault
  faultcodesoapenv:Server.userException/faultcode
  faultstringjava.lang.reflect.InvocationTargetException/faultstring
  detail
ns1:hostnamecopa.pajato.com/ns1:hostname
  /detail
/soapenv:Fault
  /soapenv:Body
/soapenv:Envelope



Re: How to not send nillable=true for null elements in a SOAP message

2006-02-20 Thread Tim R J Langford

Hello All,

Is it a bug in Axis1.3 that WSDL with nillable=false and 
minOccurs=0, still genrates a nilable=true string on serialisation? 
Is there somewhere I can log this bug or enhancement?


I may be able to do this in work time. Where would I start with Axis1.3 
to add/alter the code to deal with this? WSDL2Java mainly generates 
beans and a few other files. How would the code to analyse the presence 
of nillable=true in the schema and the unmarshalling of message 
objects fit together in the axis framework? some sort of variable set in 
the beans to indicate nillable should not be sent that is inspected on 
serilaisation; or some extracted supporting object that contains such 
information? Would this be a fairly simple task?


Thanks for you time,

Tim


Axis 1.3 and PHP Web Service Attachments

2006-02-20 Thread axis
hi,

I have just completed writing an Axis application, in fact several, to transfer 
documents as attachments using Axis 1.3. Once I understood I didn’t have any 
problems.

Now I’m trying to write a PHP SOAP client to talk to the same Axis (Java) 
server and once again to transfer documents as Attachments. I'm having a duce 
of a time. Does anyone have any experience with the PHP SOAP client side for 
sending document Attachments to an Axis Server? 

development environment:
XP (sp2) development environment
Pear SOAP 0.9.3
PHP 5.1.1

I have tried both the PEAR (0.9.3) SOAP_Attachment and nusoap libraries.

Best regards,
Lawrence


HTTP Error 401 when deploying wsdd

2006-02-20 Thread georg
Hallo!

 The things was working already, and once when I tried to deploy my wsdd,
I got the authorization error below. I have no security-constraint in
my web.xml, and didn't change anything in axis configuration.
How can I turn off this authorization function? OR What could be the reason?

Thnx
 George


axis.client.AdminClient -p 8085 deploy.wsdd
log4j:WARN No appenders could be found for logger
(org.apache.axis.i18n.ProjectR
esourceBundle).
log4j:WARN Please initialize the log4j system properly.
Processing file deploy.wsdd
Exception: AxisFault
 faultCode: {http://xml.apache.org/axis/}HTTP
 faultSubcode:
 faultString: (401)Unauthorized
 faultActor:
 faultNode:
 faultDetail:
{}:return code:  401
lt;?xml version=quot;1.0quot;
encoding=quot;utf-8quot;?gt;lt;soapenv:Enve
lope xmlns:soapenv=quot;http://schemas.xmlsoap.org/soap/envelope/quot;
xmlns:x
sd=quot;http://www.w3.org/2001/XMLSchemaquot;
xmlns:xsi=quot;http://www.w3.or
g/2001/XMLSchema-instancequot;gt;lt;soapenv:Bodygt;lt;soapenv:Faultgt;lt;
faultcode
xmlns:ns1=quot;http://xml.apache.org/axis/quot;gt;ns1:Server.Unauth
enticatedlt;/faultcodegt;lt;faultstringgt;User 'admin' not
authenticatedlt;
/faultstringgt;lt;detailgt;lt;ns2:hostname
xmlns:ns2=quot;http://xml.apache
.org/axis/quot;gt;suvilt;/ns2:hostnamegt;lt;/detailgt;lt;/soapenv:Faultg
t;lt;/soapenv:Bodygt;lt;/soapenv:Envelopegt;
{http://xml.apache.org/axis/}HttpErrorCode:401





Parsing multiple wsdls sequentially

2006-02-20 Thread Kamaljeet
Hi,I am a rookie in axis wsdl parsing.I have extened axis (basically emitter) for parsing of wsdls to my custom format.The problem I am facing with parsing, is tht If I have two wsdls 
foo.wsdl and doo.wsdl.Where foo.wsdl imports doo.wsdl.Now if I try parsing sequentially foo.wsdl, and doo.wsdl(in one session, ie passing parameters to axis emitter one after the other).
Then, foo.wsdl is parsed correctly, but then axis refuses to parse doo.wsdl (Saying tht its already parsed).Can any of you axis experts please provide information on a work around for this.
Looking forward to your suggestions.TIA,rgdsKamaljeet


Re: Change endoint programmatically

2006-02-20 Thread DFrahm

Here's what I've got that's working.
Not sure if this is good/bad or whatever... Any thoughts?


   PoliceOfficerRegistryServiceLocator
locator = new PoliceOfficerRegistryServiceLocator();

   Remote
remote = locator.getPort(PoliceOfficerRegistryServiceSoap.class);

   Stub axisPort
= (Stub) remote;

   PoliceOfficerRegistryServiceSoapStub
serviceStub = (PoliceOfficerRegistryServiceSoapStub)axisPort;

   portName
= serviceStub.getPortName();

   operationName
= PoliceOfficerRegistryServiceSoapStub._operations[0].getName();

   logger.info(Instantiate
call to port  + portName.getLocalPart() + , operationName 
+ operationName + ...);

   call =
(Call) locator.createCall(portName, operationName);

   if (serviceRequestor.getEndpoint()
!= null) {

   
   logger.info(Using endpoing from serviceRequestor...);

   
   call.setTargetEndpointAddress(new URL(serviceRequestor.getEndpoint()));

   } else
{

   
   logger.info(Using endpoing from generated
stubs...);

   
   call.setTargetEndpointAddress(new URL(locator.getPoliceOfficerRegistryServiceSoapAddress()));

   }

   logger.info(call.getTargetEndpointAddress()
=  + call.getTargetEndpointAddress());
   

   

   CPSINDocument
request = new CPSINDocument();

   String
xmlInput = soapBodyElement.getAsString();

   request.setCPSIN200Document(xmlInput);

   response
= (MajorCaseResponse) call.invoke(new Object[] {request});

- David







David Frahm/Teamhuber

02/17/2006 11:28 AM




To
Apache Axis User


cc



Subject
Change endoint programmatically







What's the best way for me to change
my endpoint dynamically?

I've got a working Axis client that
uses the WSDL2Java generated stubs. I can't figure out a real clean
way to utilize the stubs and just change the endpoint. How are people
doing this?

If it helps, here's what I've got so
far...

I created a ServiceRequestor class that
handles getting my document for the SOAP body, and that class also has
a property for the endpoint. I'd like to change that endpoint for
development vs. test vs. production environments.

The problem is my call in the first
line of overrideEndpoint() is always null. Otherwise this would work
great!

[...snip...]

   CriminalInvestigationsService
service = new CriminalInvestigationsServiceLocator();

   CriminalInvestigationsServiceSoap
serviceSoap;

   MajorCaseResponse
response;

   serviceSoap
= service.getCriminalInvestigationsServiceSoap();


   if (serviceRequestor.getEndpoint()
!= null) {

   
   Stub stub = (Stub) serviceSoap;

   
   overrideEndpoint(stub);

   }


   CPSINDocument
request = new CPSINDocument();

   String
xmlInput = soapBodyElement.getAsString();

   request.setCPSIN200Document(xmlInput);

   logger.info(Invoke
the web service, passing request object...);

   response
= serviceSoap.submitMajorCaseInvestigation(request);

[...snip...]

protected
void overrideEndpoint(Stub stub) {

   Call call = stub._getCall();

   if (call == null) {

   logger.error(Call
is null.);

   } else {

   if (serviceRequestor.getEndpoint()
!= null) {

   
   logger.info(Overriding call endpoint...);

   
   call.setTargetEndpointAddress(serviceRequestor.getEndpoint());

   
   logger.info(Endpoint overridden as 
+ call.getTargetEndpointAddress());

   } else
{

   
   logger.info(ServiceRequestor endpoint
not set, using default.);

   }

   }
}





Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread Wade Chandler
--- Carmine Gargiulo [EMAIL PROTECTED] wrote:

 Hi,
 
 this subject is of my interest also
 
 Please.can somebody help us (me and Leodiadis)
 
 :)
 
 Leodiadis Iraklis ha scritto:
  I want to write a webservice that a client will
 send a zip file to the 
  server.I have read that i could do that with
 attachments of SOAP and i 
  have to implement a handler.Could anyone help me.I
 am using java
  Thanx
  CSD Insert a catchy tag line here
 
  
  *Leodiadis Iraklis*
  /Student/   *Computer Science Department*
  [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
   
 
  
 
  
 
  /Add me to your address book.../ 
 

https://www.plaxo.com/add_me?u=47244953359v0=626259k0=1912344133
 
  /Want a signature like this?/
 http://www.plaxo.com/signature
 
 
 
  
  
  --
  Email.it, the professional e-mail, gratis per te:
 http://www.email.it/f
  
  Sponsor:
  Telefonare all'estero risparmiando fino all'80%?
 Con Email.it Phone Card puoi, clicca e scopri tutti
 i vantaggi
  Clicca qui:
http://adv.email.it/cgi-bin/foclick.cgi?mid=2683d=19-2

Search the axis user archive for wadechandler and
attachment and you should find some information that
will help you.  Zip file or any file...it doesn't
really matter as it's just bytes, so figure out
attachments and there you go.  Search the archives and
you'll find some stuff to help you.

Hope it helps,

Wade


Storing objects?

2006-02-20 Thread Justin Schoeman

Hi again.

I am probably showing my ignorance of Java here, but is there a simple 
way to store Java objects in an Axis webservice?  I have a JDBC object 
for connecting to the DB, but the overhead is high.  I would like to be 
able to store it between calls to speed up operation.


Thanks,

Justin


Re: Storing objects?

2006-02-20 Thread Thomas Burdairon
do you mean a session object ?On Feb 20, 2006, at 6:13 PM, Justin Schoeman wrote:Hi again.I am probably showing my ignorance of Java here, but is there a simple way to store Java objects in an Axis webservice?  I have a JDBC object for connecting to the DB, but the overhead is high.  I would like to be able to store it between calls to speed up operation.Thanks,Justin   Thomas  

[Axis2] JAXB unmarshalling does not work with 0.95-snapshot

2006-02-20 Thread donnerdrummel2000-mailing
Hello,

trying to use JAXB for databinding under
axis2-0.95-snapshot I got an exeption (see below)
while performing a
Unmarshaller.unmarshall(XMLStreamReader) call.

Where there any changes in OM that confilict with the
bridge provided with JAXB to get SAX events from
XMLStreamReader?

Thanks Ted.



The exception is:

Exception in thread main
java.lang.UnsupportedOperationException
at
org.apache.ws.commons.om.impl.llom.OMStAXWrapper.getNamespaceContext(OMStAXWrapper.java:983)
at
com.sun.xml.bind.v2.runtime.unmarshaller.StAXStreamConnector.bridge(StAXStreamConnector.java:114)
at
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:332)
at 
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:304)








___ 
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de


Re: Storing objects?

2006-02-20 Thread Thomas Burdairon
then use a connection pool if you want to have a common db object (http://jakarta.apache.org/commons/dbcp/)On Feb 20, 2006, at 6:23 PM, Justin Schoeman wrote:Not session - global to the web service - every query should be able to retrieve a common db object (under a lock).-justinThomas Burdairon wrote: do you mean a session object ?On Feb 20, 2006, at 6:13 PM, Justin Schoeman wrote: Hi again.I am probably showing my ignorance of Java here, but is there a simple way to store Java objects in an Axis webservice?  I have a JDBC object for connecting to the DB, but the overhead is high.  I would like to be able to store it between calls to speed up operation.Thanks,Justin Thomas   Thomas  

Re: Storing objects?

2006-02-20 Thread Justin Schoeman
Excellent thanks! I should have guessed someone would have already 
thought of it ;-) .


-justin

Thomas Burdairon wrote:
then use a connection pool if you want to have a common db object 
(http://jakarta.apache.org/commons/dbcp/)


On Feb 20, 2006, at 6:23 PM, Justin Schoeman wrote:

Not session - global to the web service - every query should be able 
to retrieve a common db object (under a lock).


-justin

Thomas Burdairon wrote:


do you mean a session object ?
On Feb 20, 2006, at 6:13 PM, Justin Schoeman wrote:


Hi again.

I am probably showing my ignorance of Java here, but is there a 
simple way to store Java objects in an Axis webservice?  I have a 
JDBC object for connecting to the DB, but the overhead is high.  I 
would like to be able to store it between calls to speed up operation.


Thanks,

Justin


Thomas




Thomas




Re: Storing objects?

2006-02-20 Thread robert
We're getting pretty far of topic here, but...

1) Use LDAP to perist java objects that are read more then written. LDAP 
natively has 'java.schema' that can store any object that implements 
'serializable' - such as a hashmap filled with strings. 

However, you did say 'simple'  ;-) . 

2) Use a singleton. Just place a map or whatever as class variable. This can 
be done in 5 minutes by any mid-level java developer. It has the 
disadvantage, however, of losing your cached values on JVM restart. It also 
has classloader side affects which can complicate things. 

3) Use ehcache or whatever and let it handle the caching. It also has simple 
file peristance that survives JVM restarts.  Requires a day or two to get the 
handle of it. 

HTH,
Robert 
http://www.braziloutsource.com/

Em Segunda 20 Fevereiro 2006 14:24, o Thomas Burdairon escreveu:
 then use a connection pool if you want to have a common db object
 (http://jakarta.apache.org/commons/dbcp/)

 On Feb 20, 2006, at 6:23 PM, Justin Schoeman wrote:
  Not session - global to the web service - every query should be
  able to retrieve a common db object (under a lock).
 
  -justin
 
  Thomas Burdairon wrote:
  do you mean a session object ?
 
  On Feb 20, 2006, at 6:13 PM, Justin Schoeman wrote:
  Hi again.
 
  I am probably showing my ignorance of Java here, but is there a
  simple way to store Java objects in an Axis webservice?  I have a
  JDBC object for connecting to the DB, but the overhead is high.
  I would like to be able to store it between calls to speed up
  operation.
 
  Thanks,
 
  Justin
 
  Thomas

 Thomas

-- 


Error with module.xml

2006-02-20 Thread Yariel Ramos Moreno
Hi:



I'm working with Axis2 since a few months ago. I'm 
making an application that consistsof 2 Web Services (both WS have the same 
implementations, but with some diferent configuration parameters and names). The 
first of them receive a request from a client, it processes the information and 
then invoke the second WS sending to it the results of that process. Thesecond 
WS most process the information sent by the first one. All the methods invoked 
are oneway methods (FireAndForgot kind).



The first call work fine, but when from the 1st WS 
I create an instance of a client to invoke the 2nd WS,I receive the following 
exception:



Module validation failed module.xml not found 
for the module : addressing; nested exception is: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for 
the module : addressingorg.apache.axis2.deployment.DeploymentException: 
module.xml not found for the module : addressing; nested exception is: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for 
the module : addressing; nested exception is: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for 
the module : addressing; nested exception is: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for 
the module : addressingat 
org.apache.axis2.deployment.DeploymentEngine.load(DeploymentEngine.java:542)at 
org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:56)at 
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:39)at
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(ConfigurationContextFactory.java:53)at 
org.apache.axis2.client.ServiceClient.init(ServiceClient.java:86)at 
org.apache.axis2.client.ServiceClient.init(ServiceClient.java:148)at 
newsProviderService.client.Client.invokeService(Client.java:25)at 
newsProviderService.service.ServiceProcessor.processRequest(ServiceProcessor.java:63)at 
newsProviderService.service.NewsService.request(NewsService.java:37)at 
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)at 
java.lang.reflect.Method.invoke(Method.java:585)at 
org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver.invokeBusinessLogic(RawXMLINOnlyMessageReceiver.java:106)at 
org.apache.axis2.receivers.AbstractInMessageReceiver.receive(AbstractInMessageReceiver.java:34)at 
org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:331)at 
org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:274)at 
org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:150)at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:709)at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)at 
java.lang.Thread.run(Thread.java:595)Caused by: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for the 
module : addressing; nested exception is: 
org.apache.axis2.deployment.DeploymentException: module.xml not found for 
the module : addressingat 
org.apache.axis2.deployment.repository.util.ArchiveReader.creatModuleArchivefromResource(ArchiveReader.java:193)at 
org.apache.axis2.engine.AxisConfiguration.loadModulefromResources(AxisConfiguration.java:385)at 
org.apache.axis2.engine.AxisConfiguration.engageModule(AxisConfiguration.java:328)at 
org.apache.axis2.deployment.DeploymentEngine.engageModules(DeploymentEngine.java:502)at 
org.apache.axis2.deployment.DeploymentEngine.load(DeploymentEngine.java:537)... 
33 moreCaused by: org.apache.axis2.deployment.DeploymentException: 
module.xml not found for the 

Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread Mukesh Kumar Maniraj
You can take a look at this Axis attachments FAQ,
http://www.mail-archive.com/axis-user@xml.apache.org/msg08732.html, its pretty easy,

-MukeshOn 2/19/06, Leodiadis Iraklis [EMAIL PROTECTED] wrote:







I want to write a webservice that a client will 
send a zip file to the server.I have read that i could do that with attachments 
of SOAP and i have to implement a handler.Could anyone help me.I am using 
java
Thanx




  
  

  


  

  
  

  


  CSD
  Insert a catchy tag line 
  here


  

  


  Leodiadis IraklisStudent 

  Computer Science Department 

  [EMAIL PROTECTED]
 
  

  
  




  

  

  


  Add me to your address book...

  Want a signature like 
  this?




Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread Simone Bonazzoli
the informations in that guide are very poor... is it possible that there isn't any official guide to SWA, attachments and a complete sample??? in the swa sample in axis there isn't source file... only .class  and the attachments sample was not generated with wsdl2java .
On 2/20/06, Mukesh Kumar Maniraj [EMAIL PROTECTED] wrote:
You can take a look at this Axis attachments FAQ,
http://www.mail-archive.com/axis-user@xml.apache.org/msg08732.html
, its pretty easy,

-MukeshOn 2/19/06, Leodiadis Iraklis 
[EMAIL PROTECTED] wrote:







I want to write a webservice that a client will 
send a zip file to the server.I have read that i could do that with attachments 
of SOAP and i have to implement a handler.Could anyone help me.I am using 
java
Thanx




  
  

  


  

  
  

  


  CSD
  Insert a catchy tag line 
  here


  

  


  Leodiadis IraklisStudent 

  Computer Science Department 

  [EMAIL PROTECTED]

 
  

  
  




  

  

  


  Add me to your address book...


  Want a signature like 
  this?






Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread fabricio
The attachment sample in axis samples folder can help you. I would like to do
the same thing some times ago and by the example I could make my own web
service with attachement. It's very helpful.

Take a look there and you will be able to do too.

Citando Simone Bonazzoli [EMAIL PROTECTED]:

 the informations in that guide are very poor... is it possible that there
 isn't any official guide to SWA, attachments and a complete sample??? in the
 swa sample in axis there isn't source file... only .class  and the
 attachments sample was not generated with wsdl2java .
 
 On 2/20/06, Mukesh Kumar Maniraj [EMAIL PROTECTED] wrote:
 
  You can take a look at this Axis attachments FAQ,
  http://www.mail-archive.com/axis-user@xml.apache.org/msg08732.html, its
  pretty easy,
  -Mukesh
 
  On 2/19/06, Leodiadis Iraklis [EMAIL PROTECTED] wrote:
  
   I want to write a webservice that a client will send a zip file to the
   server.I have read that i could do that with attachments of SOAP and i
   have to implement a handler.Could anyone help me.I am using java
   Thanx
   CSD Insert a catchy tag line here
  *Leodiadis Iraklis*
   *Student* *Computer Science Department*  [EMAIL PROTECTED]
  
  
  *Add me to your address book...*
   https://www.plaxo.com/add_me?u=47244953359v0=626259k0=1912344133
 *Want
   a signature like this?* http://www.plaxo.com/signature
  
 
 
 





This message was sent using IMP, the Internet Messaging Program.


Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread Simone Bonazzoli
i see the example but there isn't a cmplete wsdl and if i take the wsdl generated by axis wsdl2java doesn't work!On 2/20/06, 
[EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
The attachment sample in axis samples folder can help you. I would like to dothe same thing some times ago and by the example I could make my own webservice with attachement. It's very helpful.Take a look there and you will be able to do too.
Citando Simone Bonazzoli [EMAIL PROTECTED]: the informations in that guide are very poor... is it possible that there isn't any official guide to SWA, attachments and a complete sample??? in the
 swa sample in axis there isn't source file... only .class  and the attachments sample was not generated with wsdl2java . On 2/20/06, Mukesh Kumar Maniraj 
[EMAIL PROTECTED] wrote:   You can take a look at this Axis attachments FAQ,  http://www.mail-archive.com/axis-user@xml.apache.org/msg08732.html
, its  pretty easy,  -Mukesh   On 2/19/06, Leodiadis Iraklis [EMAIL PROTECTED] wrote: I want to write a webservice that a client will send a zip file to the
   server.I have read that i could do that with attachments of SOAP and i   have to implement a handler.Could anyone help me.I am using java   Thanx   CSD Insert a catchy tag line here
  *Leodiadis Iraklis*   *Student* *Computer Science Department*[EMAIL PROTECTED]  *Add me to your address book...*
   https://www.plaxo.com/add_me?u=47244953359v0=626259k0=1912344133 *Want   a signature like this?* 
http://www.plaxo.com/signatureThis message was sent using IMP, the Internet Messaging Program.



Re: [Axis2] JAXB unmarshalling does not work with 0.95-snapshot

2006-02-20 Thread Davanum Srinivas
Please open a bug report with a test case.

thanks,
dims

On 2/20/06, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
 Hello,

 trying to use JAXB for databinding under
 axis2-0.95-snapshot I got an exeption (see below)
 while performing a
 Unmarshaller.unmarshall(XMLStreamReader) call.

 Where there any changes in OM that confilict with the
 bridge provided with JAXB to get SAX events from
 XMLStreamReader?

 Thanks Ted.



 The exception is:

 Exception in thread main
 java.lang.UnsupportedOperationException
 at
 org.apache.ws.commons.om.impl.llom.OMStAXWrapper.getNamespaceContext(OMStAXWrapper.java:983)
 at
 com.sun.xml.bind.v2.runtime.unmarshaller.StAXStreamConnector.bridge(StAXStreamConnector.java:114)
 at
 com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:332)
 at
 com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:304)








 ___
 Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de



--
Davanum Srinivas : http://wso2.com/blogs/


again return Long value

2006-02-20 Thread Tomáš Procházka
Hi.

I have again the same problem with AXIS 1.3 and I can't find reason for it.

I make server class Synchronisation with method

public boolean authorize(String name,String password,double client_version) 
{
return true;
}

with ANT task I create from it WSDL file and consecutively client side class 
with method authorize.

In client side class Synchronisation.java is this   

  public boolean authorize(java.lang.String name, java.lang.String password, 
double client_version) throws java.rmi.RemoteException;

  This is OK, when I call it:


?xml version=1.0 encoding=UTF-8?
soapenv:Envelope xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/; 
xmlns:xsd=http://www.w3.org/2001/XMLSchema; 
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  soapenv:Body
ns1:authorizeResponse 
soapenv:encodingStyle=http://schemas.xmlsoap.org/soap/encoding/; 
xmlns:ns1=urn:ws.bazartip.atomsoft.cz
  authorizeReturn href=#id0/
/ns1:authorizeResponse
multiRef id=id0 soapenc:root=0 
soapenv:encodingStyle=http://schemas.xmlsoap.org/soap/encoding/; 
xsi:type=xsd:boolean 
xmlns:soapenc=http://schemas.xmlsoap.org/soap/encoding/;true/multiRef
  /soapenv:Body
/soapenv:Envelope

  Why this is too complicated?

  And when I use it, call this SOAP method fail with this error:

java.lang.ClassCastException: java.lang.Long cannot be cast to java.lang.Boolean
 at 
cz.atomsoft.bazartip.ws.SynchronizationSoapBindingStub.authorize(SynchronizationSoapBindingStub.java:231)
 at cz.atomsoft.bazartip.wservices.SynchroThread.synchro(SynchroThread.java:120)
 at cz.atomsoft.bazartip.wservices.SynchroThread.run(SynchroThread.java:87)

   
  This line of code:
java.lang.Object _resp = _call.invoke(new java.lang.Object[] {name, password, 
new java.lang.Double(client_version)}); 

   return to _resp Long value. Why? 

   I had the same problem with HashMap, when I try return them. 

   Nobody has the same problem?


-- 
Tomas Prochazka



Parameter question

2006-02-20 Thread Alan Aguia
Maybe Its really simple but I dont know how to do it.I include parameters in my axis2.xml (server side) but I dont kwow how to retrieve them when the petition arrive from the client. How can I get access to that file to retrieve that parameters?Thank you.
		 Yahoo! Mail 
Use Photomail to share photos without annoying attachments.

Re: Error with module.xml

2006-02-20 Thread Deepal Jayasinghe
Hi Yariel;

In the current implementation its fixed .
To solve your porblem you have to download addressing.mar and drop that
into .axis2/modules directory.

Yariel Ramos Moreno wrote:

 Hi:
  
 I'm working with Axis2 since a few months ago. I'm making an
 application that consists of 2 Web Services (both WS have the same
 implementations, but with some diferent configuration parameters and
 names). The first of them receive a request from a client, it
 processes the information and then invoke the second WS sending to it
 the results of that process. The second WS most process the
 information sent by the first one. All the methods invoked are oneway
 methods (FireAndForgot kind).
  
 The first call work fine, but when from the 1st WS I create an
 instance of a client to invoke the 2nd WS, I receive the following
 exception:
  
 /Module validation failed  module.xml not found  for the module :  
 addressing; nested exception is:
  org.apache.axis2.deployment.DeploymentException: module.xml not
 found  for the module :   addressing
 org.apache.axis2.deployment.DeploymentException: module.xml not found 
 for the module :   addressing; nested exception is:
  org.apache.axis2.deployment.DeploymentException: module.xml not
 found  for the module :   addressing; nested exception is:
  org.apache.axis2.deployment.DeploymentException: module.xml not
 found  for the module :   addressing; nested exception is:
  org.apache.axis2.deployment.DeploymentException: module.xml not
 found  for the module :   addressing
  at
 org.apache.axis2.deployment.DeploymentEngine.load(DeploymentEngine.java:542)
  at
 org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:56)
  at
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:39)
  at
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(ConfigurationContextFactory.java:53)
  at org.apache.axis2.client.ServiceClient.init(ServiceClient.java:86)
  at org.apache.axis2.client.ServiceClient.init(ServiceClient.java:148)
  at newsProviderService.client.Client.invokeService(Client.java:25)
  at
 newsProviderService.service.ServiceProcessor.processRequest(ServiceProcessor.java:63)
  at newsProviderService.service.NewsService.request(NewsService.java:37)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at
 sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  at java.lang.reflect.Method.invoke(Method.java:585)
  at
 org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver.invokeBusinessLogic(RawXMLINOnlyMessageReceiver.java:106)
  at
 org.apache.axis2.receivers.AbstractInMessageReceiver.receive(AbstractInMessageReceiver.java:34)
  at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:331)
  at
 org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:274)
  at
 org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:150)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
  at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
  at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
  at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
  at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
  at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
  at
 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
  at
 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
  at
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
  at
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
  at
 org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:667)
  at
 org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
  at
 org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
  at
 org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
  at java.lang.Thread.run(Thread.java:595)
 Caused by: org.apache.axis2.deployment.DeploymentException: module.xml
 not found  for the module :   addressing; nested exception is:
  org.apache.axis2.deployment.DeploymentException: module.xml not
 found  for the module :   addressing
  at
 org.apache.axis2.deployment.repository.util.ArchiveReader.creatModuleArchivefromResource(ArchiveReader.java:193)
  at
 org.apache.axis2.engine.AxisConfiguration.loadModulefromResources(AxisConfiguration.java:385)
  at
 

Deploying services through webapps

2006-02-20 Thread Pedro Silva
Hi,


I've started working with Axis for the past weeks, and I've been trying
to implement a webapp that allows me to list and do deployments and
undeployments without having to use the command line. (interesting for
remote servers).

I've been trying to do it with AdminClient class that I've found in the
API, but I'm having some problems...

I've followed the instructions on placing axis inside a webapp. I placed
the necessary jars inside WEB-INF/lib and altered web.xml to have the
necessary servlet and servlet-mappings entries. I've also copied the
server-config.wsdd in axis to WEB-INF.

I built a servlet with two buttons deploy and undeploy, the first time I
access it, I can do deploy but if I try to do undeploy nothing happens.
One curious thing is that the deploy service remains there even after
several restarts and after some time the service disappears.

So at this point I'm thinking if this is the right approach? Should this
be done? And if yes is this the right class to use?

This is part of the code I'm using for deploy/undeploy

AdminClient admClient;
admClient = new AdminClient();
URL url = new URL (http://localhost:8080/Teste/services/Teste;);
admClient.setTargetEndpointAddress(url);
//admClient.setTransport(http);

String command = request.getParameter(command);

if (command != null) {
File wsdd = null;
if (deploy.equals(command)) {
wsdd = new File(home+WEB-INF/deploy.wsdd);
admClient.process(new FileInputStream(wsdd));
} else if (undeploy.equals(command)) {
wsdd = new File(home+WEB-INF/undeploy.wsdd);
admClient.process(new FileInputStream(wsdd));
}

Below are the web.xml and server-config.wsdd deploy.wsdd and undeploy.wsdd.

I'm using eclipse 3.1.2 to write the code, Tomcat 5.5 axis1.3 and java
1.5.0_06

Thanks in advance,
Pedro Silva

My *deploy.wsdd* :

deployment xmlns=http://xml.apache.org/axis/wsdd/;
xmlns:java=http://xml.apache.org/axis/wsdd/providers/java;
 service name=Teste provider=java:MSG
  parameter name=className value=teste.Teste/
  parameter name=allowedMethods value=*/
 /service
/deployment

My *undeploy.wsdd* :

undeployment xmlns=http://xml.apache.org/axis/wsdd/;
 service name=Teste/
/undeployment


*My web.xml* :

?xml version=1.0 encoding=UTF-8?
web-app id=WebApp_ID version=2.4
xmlns=http://java.sun.com/xml/ns/j2ee;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd;
display-nameTeste/display-name
servlet
display-nameApache-Axis Servlet/display-name
servlet-nameAxisServlet/servlet-name
servlet-class
org.apache.axis.transport.http.AxisServlet
/servlet-class
/servlet
servlet
display-nameAxis Admin Servlet/display-name
servlet-nameAdminServlet/servlet-name
servlet-class
org.apache.axis.transport.http.AdminServlet
/servlet-class
load-on-startup100/load-on-startup
/servlet
servlet
description
/description
display-name
AdminTeste/display-name
servlet-nameAdminTeste/servlet-name
servlet-class
teste.AdminTeste/servlet-class
/servlet
servlet-mapping
servlet-nameAxisServlet/servlet-name
url-pattern/servlet/AxisServlet/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameAxisServlet/servlet-name
url-pattern/services/*/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameAdminServlet/servlet-name
url-pattern/servlet/AdminServlet/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameAdminTeste/servlet-name
url-pattern/AdminTeste/url-pattern
/servlet-mapping
welcome-file-list
welcome-fileindex.html/welcome-file
welcome-fileindex.htm/welcome-file
welcome-fileindex.jsp/welcome-file
welcome-filedefault.html/welcome-file
welcome-filedefault.htm/welcome-file
welcome-filedefault.jsp/welcome-file
/welcome-file-list
/web-app


My *server-config.wsdd* :


?xml version=1.0 encoding=UTF-8?
deployment xmlns=http://xml.apache.org/axis/wsdd/;
xmlns:java=http://xml.apache.org/axis/wsdd/providers/java;
 globalConfiguration
  parameter name=sendMultiRefs value=true/
  parameter name=disablePrettyXML value=true/
  parameter name=adminPassword value=admin/
  parameter name=attachments.Directory
value=/home/psilva/tomcat/webapps/axis/WEB-INF/attachments/
  parameter name=dotNetSoapEncFix value=true/
  parameter name=enableNamespacePrefixOptimization value=false/
  parameter name=sendXMLDeclaration value=true/
  parameter name=sendXsiTypes value=true/
  parameter name=attachments.implementation
value=org.apache.axis.attachments.AttachmentsImpl/
  requestFlow
   handler type=java:org.apache.axis.handlers.JWSHandler
parameter name=scope value=session/
   /handler
   handler type=java:org.apache.axis.handlers.JWSHandler

Sending XML in web services

2006-02-20 Thread Pedro Silva
Hi,

I've started to work with axis couple a weeks ago and I'm tryng to build
a web service that accepts XML content and does something with it
returning it modified or a completely new XML.

From what I've read in user guide it seems to me that Message services
are the most appropriate to do this.

Am I correct?

Having said that What is the best way to place some XML inside a SOAPBody ?

What I've been trying so far is use the styles below but I'n not very
confident with this:

public Element [] method(Element [] bodies);
public SOAPBodyElement [] method (SOAPBodyElement [] bodies);


Pedro





Re: Error with module.xml

2006-02-20 Thread Yariel Ramos Moreno
Hi Deepal... thanks for your help.

I have download addressing.mar... it seems to be the last 'cause it's
date is 01/29/06. After copy it into .axis2/modules directory I
executed a test client and got another exception:

Exception in thread main
java.lang.NoSuchMethodError:
org.apache.axis2.context.ServiceContext.getMyEPRAddress()Ljava/lang/String;
 at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:126)
 at org.apache.axis2.engine.Phase.invoke(Phase.java:376)
 at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:351)
 at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:441)
 at org.apache.axis2.description.OutOnlyAxisOperationClient.execute(OutOnlyAxisOperation.java:298)
 at org.apache.axis2.client.ServiceClient.fireAndForget(ServiceClient.java:322)
 at org.apache.axis2.client.ServiceClient.fireAndForget(ServiceClient.java:297)
 at testclient.TestClient.main(HelloClient.java:83)
Line 83 is: service.fireAndForget(payload);

So, what's the problem now? Do I have to download another thing that has been updated or fixed?


On 2/20/06, Deepal Jayasinghe [EMAIL PROTECTED] wrote:
Hi Yariel;In the current implementation its fixed .To solve your porblem you have to download addressing.mar and drop thatinto .axis2/modules directory.Yariel Ramos Moreno wrote: Hi:
 I'm working with Axis2 since a few months ago. I'm making an application that consists of 2 Web Services (both WS have the same implementations, but with some diferent configuration parameters and
 names). The first of them receive a request from a client, it processes the information and then invoke the second WS sending to it the results of that process. The second WS most process the information sent by the first one. All the methods invoked are oneway
 methods (FireAndForgot kind). The first call work fine, but when from the 1st WS I create an instance of a client to invoke the 2nd WS, I receive the following exception:
 /Module validation failedmodule.xml not foundfor the module : addressing; nested exception is:org.apache.axis2.deployment.DeploymentException: module.xml not foundfor the module : addressing
 org.apache.axis2.deployment.DeploymentException: module.xml not found for the module : addressing; nested exception is:org.apache.axis2.deployment.DeploymentException: module.xml not foundfor the module : addressing; nested exception is:
org.apache.axis2.deployment.DeploymentException: module.xml not foundfor the module : addressing; nested exception is:org.apache.axis2.deployment.DeploymentException: module.xml not foundfor the module : addressing
at org.apache.axis2.deployment.DeploymentEngine.load(DeploymentEngine.java:542)at org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:56)
at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:39)at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem
(ConfigurationContextFactory.java:53)at org.apache.axis2.client.ServiceClient.init(ServiceClient.java:86)at org.apache.axis2.client.ServiceClient.init(ServiceClient.java:148)at 
newsProviderService.client.Client.invokeService(Client.java:25)at newsProviderService.service.ServiceProcessor.processRequest(ServiceProcessor.java:63)at newsProviderService.service.NewsService.request
(NewsService.java:37)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)at sun.reflect.DelegatingMethodAccessorImpl.invoke
(DelegatingMethodAccessorImpl.java:25)at java.lang.reflect.Method.invoke(Method.java:585)at org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver.invokeBusinessLogic(RawXMLINOnlyMessageReceiver.java
:106)at org.apache.axis2.receivers.AbstractInMessageReceiver.receive(AbstractInMessageReceiver.java:34)at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:331)at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest
(HTTPTransportUtils.java:274)at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:150)at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)at javax.servlet.http.HttpServlet.service
(HttpServlet.java:802)at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java
:173)at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)at org.apache.catalina.core.StandardEngineValve.invoke
(StandardEngineValve.java:107)at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)at 

Re: Send a zip file with SOAP attachments in axis

2006-02-20 Thread Wade Chandler
This will get you doing attachments by using your WSDL
and your Object model instead of using the attachments
set directly.  I prefer this method.  This is the full
conversation:
http://marc.theaimsgroup.com/?l=axis-userm=113405973719486w=2

If you have trouble with the link search the archive
(axis-user) with a Subject search using:
web service attachment

Hope it helps,

Wade