Re: Easy way to determine URL?
Hi Michael- Many Thanks to AT for the valuable insight I found a REST (resource centric) implementation using HTTP transport located at https://wadl.dev.java.net/ where each resource has GET and POST methods e.g. resources ... method name=GET .. request param name=appid type=xsd:string/ https://wadl.dev.java.net/wadl20061109.pdf using 'simple types' xsd:string as suggested by at as far as url-encoding http://www.blooberry.com/indexdot/html/topics/urlencoding.htm you can either write your own converter or use some manner of XSLT transformer as described http://www.mnot.net/webdesc/ HTH Martin - Original Message - Wrom: XIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPK To: axis-user@ws.apache.org Sent: Friday, March 14, 2008 9:45 AM Subject: Re: Easy way to determine URL? Thanks, That is the answer I was looking for. My next question is how can I generate some sample code to give to the people who want to use my services? For my simple messages I will include a URL in the samples. For the more complex examples I will include javascript and visual basic samples. Are there any other samples I should generate? I anticipate that some people's responses to my request is that the .wsdl is good enough. But I want to take it one step further. I am trying to make the use of my services easy for a programmer who has never used web services. -- Michael Potter On Fri, Mar 14, 2008 at 7:19 AM, Anne Thomas Manes [EMAIL PROTECTED] wrote: Are you asking how to use the REST interface and submit your parameters using url encoding? That's only possible when using simple types. Anne On Thu, Mar 13, 2008 at 7:50 PM, Michael Potter [EMAIL PROTECTED] wrote: Martin, I don't think I have any problem with the transport. I am trying to figure out what I should use for a url to test the service: Would you expect this to work?: http://localhost:8080/axis2/services/ClientStuff/updateClientAddress?CltNum= ASitCod=BAddTyp=CAddrL1=DCityCd=EZipCod=FStatCd=GFonNum=HStatAr=ICn tryC=J If so, I will try harder to make that work. If not, please propose something for me to try. -- Michael Potter On Thu, Mar 13, 2008 at 3:14 PM, Martin Gainty [EMAIL PROTECTED] wrote: Mike- whatever algorithm you're using if the transport is not http then you'll need to reconfigure the transport to accept a valid URL for that transport (HTTP/TCP/SMTP) http://ws.apache.org/axis2/1_3/transport_howto.html does this conform to your understanding? M- - Original Message - Wrom: YLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXU To: axis-user@ws.apache.org Sent: Thursday, March 13, 2008 12:56 PM Subject: Easy way to determine URL? Axis2 Crew, I find it tedious to figure out what to use for a URL to use to test an axis2 webservice. Is there some tool that we can use that will split out a sample URL? Of particular problem are webservices such as the one below that has nested variables and webservices with arrays of variables. Can anyone tell me how to handle the nested variables and arrays of variables? Maybe it is not possible to use a URL for these more complex cases? wsdl:operation name=updateClientAddress wsdl:input message=axis2:updateClientAddressInputs /wsdl:input wsdl:output message=axis2:ClientAddress /wsdl:output /wsdl:operation wsdl:message name=updateClientAddressInputs wsdl:part name=part0 element=tns:updateClientAddressInputsGroup /wsdl:part /wsdl:message wsdl:message name=ClientAddress wsdl:part name=part0 element=tns:ClientAddressArray /wsdl:part /wsdl:message xs:element name=updateClientAddressInputsGroup type=updateClientAddressInputsGroupType/ xs:complexType name=updateClientAddressInputsGroupType xs:sequence xs:element name=ClientNumber type=ClientNumberType/ xs:element name=ClientAddress type=ClientAddressType/ /xs:sequence /xs:complexType xs:complexType name=ClientNumberType xs:sequence xs:element name=CltNum type=xs:string/ /xs:sequence /xs:complexType xs:complexType name=ClientAddressType xs:sequence xs:element name=SitCod type=xs:string/ xs:element name=AddTyp type=xs:string/ xs:element name=AddrL1 type=xs:string/ xs:element name=CityCd
Re: configuration troubles
Matthew- your /WEB-INF/conf/axis2.xml should contain this configuration axisconfig name=AxisJava2.0 module ref=rampart / //for InFlow phaseOrder type=InFlow phase name=Security/ //and for OutFlow phaseOrder type=OutFlow phase name=Security/ Martin-- - Original Message - Wrom: IMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLE To: axis-user@ws.apache.org Sent: Sunday, March 02, 2008 8:25 PM Subject: configuration troubles Hi there, I have an axis2 service that is actually just a middle man. It exposes some services, but really it just does some small amount of work and passes the service request on to another service. As a result, I have some of the classes (the client connection classes) from the back end service in my middle man service. This has not been a problem so far, but now I am trying to secure the communication with rampart and I am having some trouble working out how I can set the inflow and outflow of the communications with the back end service. For the back end service itself, there is not problem, but where to I put configuration setting for the back end client that is embedded in the middle man? Matt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [AXIS2] Class ConfigurationContext...
Arlindo- Did you engage the module e.g. ServiceClient serviceClient = new ServiceClient(); serviceClient.engageModule(rampart); ? Martin- - Original Message - Wrom: SZLKBRNVWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMH To: destinatarios-nao-revelados: Sent: Sunday, March 02, 2008 8:02 PM Subject: [AXIS2] Class ConfigurationContext... Hi All... Someone, please, can give-me some explanation about some methods of the class ConfigurationContext... ( the javadoc of Axis2 1.3 is empty )... The methods are: |*cleanupContexts mailbox:///D%7C/Meus%20Documentos/Thunderbird/GMail/Drafts?number=11598354 part=1.2filename=ConfigurationContext.html*()|? |*finalize mailbox:///D%7C/Meus%20Documentos/Thunderbird/GMail/Drafts?number=11598354 part=1.3filename=ConfigurationContext.html*()|? |*terminate mailbox:///D%7C/Meus%20Documentos/Thunderbird/GMail/Drafts?number=11598354 part=1.4filename=ConfigurationContext.html*()|? I have a simple client with rampart inside another service,,, evething works fine without rampart,,, but if I try use the client more than once ( like the service need invoke my client more than once ) I receive many exceptions I think that I need clean the client configuration each time,,, I think... but,,, with what method? or,,, what I need to do? PS: My methods and variables are NOT static... and, inside the services.xml ( service name=MyService ) I don't use the parameter scope=application or something like this... Thanks in advance ( and sorry my poor english,,, I hope be clear in my doubts ) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Async requests killing network
I'll ask the dumb question..How do you configure AXIS2 to use the NIOConnector instead of default HTTP Connector? Thanks Martin-- - Original Message - Wrom: MBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCDDJBL To: axis-user@ws.apache.org Sent: Monday, February 11, 2008 12:16 PM Subject: Re: Async requests killing network Matthias, have you tried to create less Callback objects and handle your bunch or requests (at least) with a single one? Furthermore, Paul pointed out the NIO connector. If you're instead using the default one, I'd suggest you to customize the configuration context your service client uses in order to inject a custom HttpConnectionManager (see the httpclient library) and periodically call closeIdleConnections(). Michele On 11 Feb 2008, at 11:11, Matthias Wermund wrote: Hi, I'm having problems starting a big amount of async webservice requests via Axis2 client in short time. The requests are all started from the same Thread and should run parallel in only small amount. As you can see below, I start about 1000 * 5 = 5000 requests, but only a max of 2-5 are called parallel. For each dataset, a few information-requests are started parallel, but I ensure that each CallbackHandler has been finished, before requesting the informations for the next dataset. For the first several hundred requests this works fine, but after some time, my network (OS is Windows 2000) goes down, which means that the complete OS looses the connection to the local network. I guess this could be based in opening too much TCP connections or something like this, because if it affects the whole OS and not just my application, it has to be something with the network device or driver. So basically my question is: Is it ensured that the TCP connection is already closed when CallbackHandler.onError or CallbackHandler.onComplete is called? Or must I do this myself in any way? Do you have any other clue what might be the problem here? Thank you! __ A quick mock-overview of how I start the threads: ListDataset datasets;// approx. 500 - 1000 objects ... for (Object data: datasets) { ListCallback callbacks; for (Information info: myRequestsForThisData) {// approx. 2-5 objects // Generating the Request Document Request request = generateRequest(info); // Generating a service Callback instance; the Callback class has an attribute finished Callback myCallback = new Callback(); // remembering the callback callbacks.add(myCallback); // starting the async request stub.startRequest(request,myCallback); } // now wait until all Callbacks are finished (finished is true if onError or onComplete has been called) while (true) { boolean allCompleted = true; for(Callback callback: callbacks) if (callback.isFinished()) { allCompleted = false; break; } if (allCompleted) break; Thread.sleep(25); } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Extending axis2 client stub without modifying it
The short answer is yes as you want to concentrate on deploying only the minimal set of classes and configurations possible Presuming you have axis-2.1.3..take a look at jax-ws-calculator-1.3.aar which contains: the basic serviceStub Response wsdl build environments of pom build.xml Bon Chance, Martin-- - Original Message - Wrom: JJPHSCRTNHGSWZIDREXCAXZOWCON To: axis-user@ws.apache.org Sent: Wednesday, February 06, 2008 4:13 AM Subject: Extending axis2 client stub without modifying it I have an existing client stub generated with Axis2 WSDL2Java. Is it possible to extends it only by adding in class path a jar file that contains: - axis2.xml - classes that extend the stub In axis1.x it is possible, but in axis2 it seams to be not , can some one confirm ? -- View this message in context: http://www.nabble.com/Extending-axis2-client-stub-without-modifying-it-tp153 06325p15306325.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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Stubs response
the Java2WSDL utility handles this by generating an inner public static class for the Response as described here for LookupDataServiceStub package ae.ead.egovernment.core.webservice.impl; /* LookupDataServiceStub java implementation */ public class LookupDataServiceStub extends org.apache.axis2.client.Stub { /** Auto generated method signature returning GetCountriesResponse * @see ae.ead.egovernment.core.webservice.impl.LookupDataService#getCountries*/ public ae.ead.egovernment.core.webservice.impl.LookupDataServiceStub.GetCountriesResponse getCountries( ) throws java.rmi.RemoteException { .. } public static class GetCountriesResponse implements org.apache.axis2.databinding.ADBBean { public static final javax.xml.namespace.QName MY_QNAME = new javax.xml.namespace.QName( http://impl.webservice.core.egovernment.ead.ae;, getCountriesResponse, ns3); . } //end static declaration GetCountriesResponse.. M- - Original Message - Wrom: PWIGYOKSTTZRCLBDXR To: axis-user@ws.apache.org Sent: Saturday, January 26, 2008 2:35 PM Subject: Stubs response Hi, I'm not sure if this is the right place for this Problem. My webservice have following method: public String GetAccessibleServiceList() { DBRetrieve one = new DBRetrieve(); ArrayList hspid3 = one.RegisteredServices(userID); Iterator it2 = hspid3.iterator(); while (it2.hasNext()) { registeredservices = hspid3.toString(); System.out.println( RETURN REGISTERED HSP LIST + registeredservices); return registeredservices; } return registeredservices; } This method return the list of services from database. After creating the stub I have got GetAccessibleServiceListResponse but not GetAccessibleServiceList. Therefore at client side I made object AuthenticationServerStub.GetAccessibleServiceListResponse registrationService = new AuthenticationServerStub.GetAccessibleServiceListResponse(); But this returns an object [EMAIL PROTECTED] How can I get response or convert this into string. Regards Nasreen -- Connect and share in new ways with Windows Live. Get it now!
Re: Stax Parsing in AXIOM
with WL (8.1) you can set the min_heapsize, max_heapsize and MaxPermSize with MEM_ARGS env variable.. set MEM_ARGS=-Xms32m -Xmx200m -XX:MaxPermSize=128m M-- - Original Message - Wrom: IJJPHSCRTNHGSWZIDREXCAXZOWCONEUQZAAFXISHJEX To: axis-user@ws.apache.org Sent: Thursday, December 20, 2007 4:14 PM Subject: RE: Stax Parsing in AXIOM Hi Martin 1. I'm using BEA JDK on Windows system. This has nothing to do with JRE implementation 2. My concern is parsing multiple huge files by keeping a linked list of constructed OM elements may result in out-of-memory errors. Since my knowledge of AXIOM is limited, wonder if there is a way to get around this limitation? Thanks Chandru Ganesan -Original Message- Wrom: XIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJ Sent: Thursday, December 20, 2007 2:49 PM To: axis-user@ws.apache.org Subject: Re: Stax Parsing in AXIOM Chandru does that answer the question of using in-memory of list vs using a persistence mechanism such as serialization? is this a requirement for your client? or maybe a future performance consideration? HP addresses this with a test harness which shl_load() the JRE under HP/UX as in javalib = shl_load( /opt/java1.3/jre/lib/PA_RISC/classic/libjvm.sl, BIND_IMMEDIATE | BIND_VERBOSE,NULL); http://www.hp.com/products1/unix/java/infolibrary/prog_guide/classicJVM.html #loading as this is specific to HPUX with java1.3 JRE I encourage you to contact HP(UX) support for specifics for the JRE and version of HPUX you will be implementing.. M-- - Original Message - Wrom: GDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRN To: axis-user@ws.apache.org Sent: Thursday, December 20, 2007 3:11 PM Subject: Stax Parsing in AXIOM Hi Dennis Thank You for the response. Much appreciated. Thanks Chandru Ganesan -Original Message- Wrom: VWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVW Sent: Thursday, December 20, 2007 2:05 PM To: axis-user@ws.apache.org Subject: Re: Looking for AXIOM experts Hi Chandru, I haven't stayed completely current on the latest changes, but AFAIK you're not going to get what you want by using AXIOM. By design, AXIOM will hold on to the constructed elements as you move through the list, so that you'll end up building the entire list in memory. To process this type of structure without building it in memory you need to either work directly with the parser or use a data binding implementation that allows you to process documents one piece at a time. You can do this with JiBX, for instance, by writing a custom unmarshaller for the batch-request element which just unmarshals and processes each addRequest separately, without holding on to the ones that have already been processed. I think you can use similar approaches with JAXB. - Dennis -- Dennis M. Sosnoski SOA and Web Services in Java Axis2 Training and Consulting http://www.sosnoski.com - http://www.sosnoski.co.nz Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117 Ganesan, Chandru wrote: Hi Is there any AXIOM expert in this group who can answer this question? I sent this question to the appropriate group [EMAIL PROTECTED], unfortunately this group is not quite active as I've not been getting any emails from this group for past few days. Thanks Chandru Ganesan -Original Message- Wrom: RKJVZCMHVIBGDADR Sent: Tuesday, December 18, 2007 5:13 PM To: axis-user@ws.apache.org Subject: StAX parsing of XML file using AXIOM API Hi I'm a newbie to Apache Axis2. I have few questions on AXIOM (StAX)API. Since I didn't get any answers to my original post to '[EMAIL PROTECTED]' mailing list, I'm posting to this group hoping for answers/guidance. I'd like to parse a huge file without building complete object model (linked list of OM elements) in memory i.e., I don't want the effect of going back in the inputstream and reading elements. I have following file structure: Soap-Envelope Soap-Header /Soap-Header Soap-Body batch-request addRequest .. /addRequest addRequest !-- thousands of addRequests here. I'd like to parse each addRequest one at a time without preserving OM elements of previous and subsequent elements addRequest /batch-request /Soap-Body /Soap-Envelope I have following questions: 1. During my analysis, I found out that whenever I use an Iterator, as in the code snippet below, to get a childElement using iterator.next(), AXIOM builds a link list of all child elements (OM Element) similar to DOM tree i.e., whole document is parsed and OM elements are created in memory. . QName qName = new QName(http://schemas.xmlsoap.org/soap/envelope;, Body, soap); Iterator itr = soapEnvelope.getChildrenWithName(qName); while(itr.hasNext()) { OMElement element = (OMElement) itr.next(); } However, when I used StAXSOAPModelBuilder to extract SOAPEnvelope, SOAPElement, SOAPBody it is able to build without parsing the whole file.
Re: java.lang.IncompatibleClassChangeError by Axis 1.2 Example6
Thomas- which version wsdl4j is on your CLASSPATH? M- - Original Message - Wrom: ZOWCONEUQZAAFXI To: axis-user@ws.apache.org Sent: Saturday, December 15, 2007 5:14 PM Subject: RE: java.lang.IncompatibleClassChangeError by Axis 1.2 Example6 Exactly to say, as I run the Main.java I got the exception. I debug the programm and the exception comes from the code from WidgetPriceSoapBindingStub.java: ... try { java.lang.Object _resp = _call.invoke(new java.lang.Object[] {in0, in1}); ... ... } ... --- Hi all, I tryed the example6 in Axis 1.2 and got exception as follow. Someone knows what is wrong? org.apache.axis.transport.http.AxisServlet logException INFO: Exception: java.lang.IncompatibleClassChangeError at org.apache.axis.message.MessageElement.addTextNode(MessageElement.java:1387) at org.apache.axis.message.SOAPHandler.addTextNode(SOAPHandler.java:148) at org.apache.axis.message.SOAPHandler.endElement(SOAPHandler.java:112) at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1712) at org.apache.crimson.parser.Parser2.content(Parser2.java:1963) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1691) at org.apache.crimson.parser.Parser2.content(Parser2.java:1963) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1691) at org.apache.crimson.parser.Parser2.content(Parser2.java:1963) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1691) at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:667) at org.apache.crimson.parser.Parser2.parse(Parser2.java:337) at org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:448) at javax.xml.parsers.SAXParser.parse(SAXParser.java:345) at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227) at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696) at org.apache.axis.Message.getSOAPEnvelope(Message.java:424) at org.apache.axis.server.AxisServer.initSOAPConstants(AxisServer.java:345) at org.apache.axis.server.AxisServer.invoke(AxisServer.java:279) at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401) at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266) at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:387) at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:365) at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:944) at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:266) at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95) at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175) at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33) at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunnerjava:41) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(Native Method) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170) -- Jetzt Mails schnell in einem Vorschaufenster überfliegen. Dies und viel mehr bietet das neue Yahoo! Mail.
Re: java.lang.NoClassDefFoundError exception. Service impl class not picking up external jars in /lib.
which class produces the CNFE? M- - Original Message - Wrom: LHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKE To: axis-user@ws.apache.org Sent: Friday, December 07, 2007 7:33 AM Subject: java.lang.NoClassDefFoundError exception. Service impl class not picking up external jars in /lib. Hi everyone, I'm attempting to deploy a Web Service from a simple Java class by creating a service archive and deploying it to WSAS (Web Services Application Server). However, I'm having trouble invoking this service. The structure of my service is given below (which I then deployed as an .aar file): - Grouper.aar - META-INF - services.xml - lib - *.jar - conf - sources.xml - test - GrouperWS.class However, GrouperWS.class is not seeing the lib/*.jar in its classpath. I get java.lang.NoClassDefFoundError exceptions when I invoke GrouperWS. I've followed the advice given previously in this mailing list but to no avail. I would really appreciate any insight or help in this matters. My services.xml and GrouperWS.java is provided below for added clarity. Cheers. Regards Sanjay package test; import java.io.InputStream; import org.apache.axis2.AxisFault; import org.apache.axis2.context.MessageContext; import org.apache.axis2.description.AxisService; import edu.internet2.middleware.grouper.SubjectFinder; import edu.internet2.middleware.subject.Subject; import edu.internet2.middleware.subject.SubjectNotFoundException; import edu.internet2.middleware.subject.SubjectNotUniqueException; public class GrouperWS { private final static String GROUPER_PROPERTIES = conf/sources.xml; public String loadResource() throws AxisFault, SubjectNotFoundException, SubjectNotUniqueException{ MessageContext context = MessageContext.getCurrentMessageContext(); AxisService service = context.getAxisService(); ClassLoader loader = service.getClassLoader(); InputStream in = loader.getResourceAsStream(GROUPER_PROPERTIES); if (in != null) { String subjectId = [EMAIL PROTECTED]; Subject subject = SubjectFinder.findById(subjectId); String user = subject.getId(); return user; } else { return An error as occured; } } } //end of GrouperWS service name=Grouper scope=application description This is the Grouper Service /description parameter name=ServiceTCCLcomposite/parameter messageReceivers messageReceiver mep=http://www.w3.org/2004/08/wsdl/in-only; class=org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver/ messageReceiver mep=http://www.w3.org/2004/08/wsdl/in-out; class=org.apache.axis2.rpc.receivers.RPCMessageReceiver/ /messageReceivers parameter name=ServiceClass test.GrouperWS /parameter /service - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice
http://ws.apache.org/axis2/1_1_1/mtom-guide.html to quote MTOM can be set on per service and per operation I didnt get the attachment for your wsdl M- - Original Message - Wrom: EXXIMQZUIVOTQNQEMSFDULHP To: axis-user@ws.apache.org Sent: Wednesday, December 05, 2007 9:36 PM Subject: RE: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice A quick question - if I have only a few service operations that need to be mtom-enabled - can I set mtom to false in axis2.xml and/or services.xml at service level, and set it to true only for those few operations at the services.xml operation level? -- Wrom: QQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWL Sent: Wednesday, December 05, 2007 4:40 PM To: 'axis-user@ws.apache.org' Subject: RE: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice Did some monitoring using TCPMon and saw that axis2 was sending the request as multipart. This particular .Net websvc call did not have any attachments and hence did not need to be send as multipart - I think the Net side service was assuming it would not be multipart. I set MTOM to off in axis2.xml and that particular call worked. I will now try to turn MTOM back on in axis2.xml and try to see if I can set it on and off at the call level. - Vish. -- Wrom: SZLKBRNVWWCUFPEGAUTFJMVR Sent: Tuesday, December 04, 2007 1:25 PM To: axis-user@ws.apache.org Subject: RE: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice Attaching the wsdl and aar and axis2.xml file for my axis2 service (ECMServiceSoap) and the wsdl for the .NET service (CPMPDFToWord.wsdl). I am running tomcat and have deployed the axis2 1.3 webapp in an exploded format. So my lib folder has axis2 1.3 xerces 2.8.1, xalan 2.7.0, wstx-asl-3.2.1.jar, xml-apis-1.3.03.jar among others. I am using jdk1.5.0. - Vish. -- Wrom: ESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQH Sent: Tuesday, December 04, 2007 7:23 AM To: axis-user@ws.apache.org Subject: Re: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice Please post WSDL also please post location and version-number of your xml parsers such as xerces/jax M-- - Original Message - Wrom: YUCDDJBLVLMHAALPTCXLYRWT To: axis-user@ws.apache.org Sent: Monday, December 03, 2007 11:04 PM Subject: RE: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice I tried calling the .NET service with a coded Axis2 client that does not use the stub code I generated from the .NET wsdl earlier (code is enclosed at end of this posting) - but I get same exception. However when I try calling the .NET service from some UI based client like SoapUI (that is independent of axis) the call to the .NET service works. So I presume there is something wrong in the way in the way my client code is invoking the .NET service. Tomorrow I will try seeing the messages with soapmonitor. String pingURL = http://192.168.254.151/SCPMPDFToWord/Services/CPMPDFToWord.asmx;; Options options = new Options(); options.setTo(new EndpointReference(pingURL)); String methodName = SetWorkingFolder; String methodNameSpaceURI = http://ws.selectica.com/ecm1/;; OMFactory fac = OMAbstractFactory.getOMFactory(); OMNamespace ns = fac.createOMNamespace(methodNameSpaceURI, ns1); OMElement payload = fac.createOMElement(methodName, ns); OMElement value = fac.createOMElement(ClientWorkingFolderOnServer, ns); value.addChild(fac.createOMText(value, clientWorkingFolderOnServer)); payload.addChild(value); ServiceClient client = new ServiceClient(); client.setOptions(options); OMElement result = client.sendReceive(payload); Wrom: QTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFMYXOEAIJJPHSCRTNHGSW Sent: Monday, December 03, 2007 6:09 PM To: axis-user@ws.apache.org Subject: [Axis2] WstxEOFException: Unexpected EOF in prolog error while calling .NET2.0 webservice from Axis2 webservice I am using Axis1.3 and have deployed an Axis2 webservice which calls a .NET2.0 webservice. I got the wsdl for the .NET service and used wsdl2java to generate the client code (stub) for calling it. I am calling that stub from my deployed axis2 service. This stub
Re: 400 No Host matches server name when using OPTIONS header
seems this is related to your Axis host platform Any chance you can redeploy to a known working platform such as Linux, Solaris or windows? M- - Original Message - Wrom: LBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRN To: axis-user@ws.apache.org Sent: Thursday, December 06, 2007 4:47 PM Subject: 400 No Host matches server name when using OPTIONS header Axis2 Crew, Axis2 disconnects with with http error 400 when we send a OPTIONS header. Is there a way to get Axis2 to honor the OPTIONS header? Here is additional information: === This is the output of ethereal of HTTP request that works (this comes from a browser): GET /axis2/services/InquirePolicy2/getPolicyValues?PolNum=BLP1435284 HTTP/1.1 Host: 10.90.10.126:1 User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031007 Firebird/0.7 Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q= 0.8,video/x-mng,image/png,image/jpeg,image/gif;q=0.2,*/*;q=0.1 Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip,deflate Accept-Charset: ISO-8859-1,utf-8;q=0.7,* Server: Apache-Coyote/1.1 Content-Type: application/xml;action=http://InquirePolicy2/InquirePolicy2PortType/getPoli cyValuesResponse;;charset=UTF-8 Transfer-Encoding: chunked Date: Thu, 06 Dec 2007 18:51:30 GMT ee ns1:PolicyValues xmlns:ns1=http://InquirePolicy2/xsd;ns1:CashVl2,741.09/ns1:CashVlns1: FullSr1,230.02/ns1:FullSrns1:MxLoan1,154.59/ns1:MxLoanns1:LoanPy204 27/ns1:LoanPyns1:MxPart1,200.95/ns1:MxPart/ns1:PolicyValues 0 = This is the output of ethereal of HTTP request that does not works (this comes from EXEC CICS INVOKE WEBSERVICE on ibm mainfame): OPTIONS * HTTP/1.1 HOST:10.90.10.126 User-Agent: IBM_CICS_Transaction_Server/3.1.0(zOS) Date: Thu, 06 Dec 2007 18:10:36 GMT TE: trailers Connection: Keep-Alive C10.90.10.126 Server: Apache-Coyote/1.1 Transfer-Encoding: chunked Date: Thu, 06 Dec 2007 19:09:31 GMT Connection: close - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Command line for AXIS2
yes sietse rather intrusive (but it will work!) To be more specific about handling just your webapp if your axis2 webapp is called axis2 and is located on localhost put this address in your browser to start axis2 webapp http://localhost:8080/manager/html/stop?path=/axis2 if your axis2 webapp is called axis2 and is located on localhost put this address in your browser to stop axis2 webapp http://localhost:8080/manager/html/start?path=/axis2 if your axis2 webapp is called axis2 and is located on localhost put this address in your browser to list your webapps http://localhost:8080/manager/html/list HTH/ Martin - Original Message - Wrom: MHVIBGDADRZFSQHYUCDDJBLVLMHAALPT To: axis-user@ws.apache.org Sent: Wednesday, December 05, 2007 4:09 AM Subject: RE: Command line for AXIS2 Hi, I think more information can be found in the architecture guide I think. In case of Apache Tomcat this is: Starting the servlet container: - Windows: net start Apache Tomcat - Debian: /etc/init.d/tomcat start Stopping: - Windows: net stop Apache Tomcat - Debian: /etc/init.d/tomcat stop If the container runs, you can deploy the services into it. Just deploy a war into the webapps directory and wait to see some magic and it is ready for usage. By default you can put the axis2.war in here as mentioned on the getting-started guide. Your own service can then be deployed in different ways. Checking it from the command line is just a http request imho. So you send it using a tool which can generate that. Regards, Sietse Wrom: CXLYRWTQTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFM Sent: 05 December 2007 01:41 To: axis-user@ws.apache.org Subject: RE: Command line for AXIS2 Apache Axis2 1.2 build (April 27 2007) Wrom: YXOEAIJJPHSCRTNHGSWZIDREXCAXZOWCONEUQZAAFX Sent: Tuesday, December 04, 2007 6:16 PM To: axis-user@ws.apache.org Subject: Re: Command line for AXIS2 which version axis are you implementing? M- - Original Message - Wrom: ISHJEXXIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPK To: axis-user@ws.apache.org Sent: Tuesday, December 04, 2007 7:45 PM Subject: Command line for AXIS2 Is there any way to: Start service Stop service Check if service is active from the command line. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Configuration error? java.lang.NoSuchMethodError: org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder: method init(Ljavax/xml/stream/XMLStreamReader;)V not found
are you implementing with version 1.2.5 axiom? http://ws.apache.org/commons/axiom/download.cgi M-- - Original Message - Wrom: KEDOTWFAOBUZXUWLSZLKBRNVWWCUFPEGA To: axis-user@ws.apache.org Sent: Sunday, December 02, 2007 9:35 PM Subject: Configuration error? java.lang.NoSuchMethodError: org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder: method init(Ljavax/xml/stream/XMLStreamReader;)V not found I have activation-1.1.jar in jre/lib/endorsed, however I still get the following error when using an axis2 client in both Tomcat and Jetty. When run as a unit test there are no problems. I am running this inside a spring (2.5) session, is there a potential conflict? INFO | jvm 1| 2007/12/02 20:09:26 | java.lang.reflect.InvocationTargetException INFO | jvm 1| 2007/12/02 20:09:26 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) INFO | jvm 1| 2007/12/02 20:09:26 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) INFO | jvm 1| 2007/12/02 20:09:26 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) INFO | jvm 1| 2007/12/02 20:09:26 | at java.lang.reflect.Method.invoke(Unknown Source) INFO | jvm 1| 2007/12/02 20:09:26 | at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:283) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.job.impl.JobDetailDelegateImpl.executeInternal(JobDetailDelegateImpl java:35) INFO | jvm 1| 2007/12/02 20:09:26 | at org.springframework.scheduling.quartz.QuartzJobBean.execute(QuartzJobBean.ja va:86) INFO | jvm 1| 2007/12/02 20:09:26 | at org.quartz.core.JobRunShell.run(JobRunShell.java:203) INFO | jvm 1| 2007/12/02 20:09:26 | at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520 ) INFO | jvm 1| 2007/12/02 20:09:26 | Caused by: java.lang.NoSuchMethodError: org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder: method init(Ljavax/xml/stream/XMLStreamReader;)V not found INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.builder.SOAPBuilder.processDocument(SOAPBuilder.java:53) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.transport.TransportUtils.createDocumentElement(TransportUti ls.java:160) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.j ava:111) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.j ava:87) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAx isOperation.java:326) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperatio n.java:389) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisO peration.java:211) INFO | jvm 1| 2007/12/02 20:09:26 | at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.webservice.landau.WsLandauB2BStub.InitializeOrder(WsLandauB2BSt ub.java:847) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.webservice.landau.LandauWSWrapper.initializeOrder(LandauWSWrapp er.java:61) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.sender.LandauWSSender.sendOrder(LandauWSSender.java:46) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.handler.LandauOrderHandler.handleOrder(LandauOrderHandler.java: 150) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.handler.LandauOrderHandler.handleOrders(LandauOrderHandler.java :47) INFO | jvm 1| 2007/12/02 20:09:26 | at com.mnu.core.processor.LandauOrderProcessor.processOrder(LandauOrderProcesso r.java:58) -- View this message in context: http://www.nabble.com/Configuration-error--java.lang.NoSuchMethodError%3A-or g.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder%3A-method-%3Cinit%3E%2 8Ljavax-xml-stream-XMLStreamReader-%29V-not-found-tf4934056.html#a14123002 Sent from the Axis - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: HTML Status Code 302 And Exception When Contacting IIS Service
Hi Rick- take a look at explanation of HTTP 302 return code http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html The method used for transmitting the request makes the difference on whether or not you are able to redirect to location field returned with the 302..in other words POST cannot redirect..but GET and HEAD can redirect Also since the redirect might be altered the client must continue to use the original URI as a quick test I would try to determine if you have any proxies, firewalls or NAT servers changing the url, port or webapp between you and the webservice The admin of the webservice is obligated to provide you with the following information a)The web service site (address or CNAME) must exist and be reachable b)The web service admin must provide a wsdl from the published service c)Use the provided wsdl to establish your own client stubs to transmit request to the waiting Service If any of these items fails recode it in a working webservice environment such as Axis and use that... Anyone else? Martin-- - Original Message - Wrom: RZFSQHYUCDDJBLVLMHAALPTCXLYRWTQTI To: axis-user@ws.apache.org Sent: Friday, November 30, 2007 1:20 PM Subject: Re: HTML Status Code 302 And Exception When Contacting IIS Service I don't think there are any spaces in any of the names involved. (I put a few underscores in the changed names below.) I can see exactly where the exception is ocurring - it's in HTTPSender.readFromSocket(), where it detects the 302 status, closes the socket, clears the status code, and sends it off to invoke() where it tries to construct a new URL based on the 'location' field. Unfortunately, I seem to be getting an incomplete spec for a URL in 'location' - it's missing the protocol and the hostname. (Emphasis here on the fact that I can talk with my own services just fine.) Would there be anything else I have to do if they are trying to send me back a url rather than plain text or xml? Martin Gainty wrote: Hi Rick- most DNS servers wont do lookups on DNS CNAMEs for ServerName With Spaces but rather CNAMEs without spaces such as private static String URL = http://127.0.0.1:8080/axis2/services/AddressBookService;; Call.java throws MalformedURLException when the EPR (URL) is malformed M-- - Original Message - Wrom: PWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYF To: axis-user@ws.apache.org Sent: Friday, November 30, 2007 6:14 AM Subject: Re: HTML Status Code 302 And Exception When Contacting IIS Service Hi Martin, Thanks. I added the following to my own code while configuring the call: call.setProperty(MessageContext.HTTP_TRANSPORT_VERSION, HTTPConstants.HEADER_PROTOCOL_V11); Hashtable chunkedTable = new Hashtable(); chunkedTable.put(HTTPConstants.HEADER_TRANSFER_ENCODING, HTTPConstants.HEADER_TRANSFER_ENCODING_CHUNKED); call.setProperty(HTTPConstants.REQUEST_HEADERS, chunkedTable); Now I get similar results, but with one additional go-round. In HTTPSender.readFromSocket, the first iteration gives me a 100 (continue), then when I do so, I get the 302 again, then the MalformedURLException. I should probably mention that this is Axis 1.4, Java 1.5 (OS X) Rick Martin Gainty wrote: Hi Rick- 1st make sure you are enabling HTTP 1.1 protocol and chunkedEncoding transfer-encoding as in this example from /conf/axis2.xml transportSender name=http class=org.apache.axis2.transport.http.CommonsHTTPTransportSender parameter name=PROTOCOLHTTP/1.1/parameter parameter name=Transfer-Encodingchunked/parameter !-- If following is set to 'true', optional action part of the Content-Type will not be added to the SOAP 1.2 messages -- !-- parameter name=OmitSOAP12Actiontrue/parameter -- /transportSender Martin- - Original Message - Wrom: MYXOEAIJJPHSCRTNHGSWZIDREXCAXZOWC To: AXIS User Mail List axis-user@ws.apache.org Sent: Thursday, November 29, 2007 8:35 PM Subject: HTML Status Code 302 And Exception When Contacting IIS Service Greetings, I'm new to this area of programming, so please bear with me if this is something so simple a 5-year-old should be able to deal with. (In the following code I've changed some names for the sake of confidentiality, so the URLs will not actually work.) I've written a very simple Axis client in Java, to contact a service on a remote IIS machine. I'm passing a String and expecting an acknowledgment back. I have written my own test service, running in Tomcat on my own server, and it works fine. When trying to connect to the IIS machine, my client chokes with various errors depending on the spellings/misspellings of the endpoint URL. Most common is MalformedURLException: no protocol. My code: public void contact() { try { Service service = new Service(); Call call = (Call)
Re: Axis2 1.3 caused java.lang.NoSuchMethodError: javax.wsdl.Operation: method getExtensibilityElements()Ljava/util/List; not found
Hi Sean do you have wsdl4j.jar on /WEB-INF/lib ? http://www.ibiblio.org/maven/wsdl4j/jars/ Martin-- - Original Message - Wrom: IMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLB To: axis-user@ws.apache.org Sent: Wednesday, November 28, 2007 7:47 PM Subject: Axis2 1.3 caused java.lang.NoSuchMethodError: javax.wsdl.Operation: method getExtensibilityElements()Ljava/util/List; not found I am seeing this message in my log file. What is the getExtensibilityElements() method? Where is this coming from? [11/28/07 16:26:24:591 PST] 017d ServiceDeploy I org.apache.axis2.deployment.ServiceDeployer deploy The XyzServices service, which is not valid, caused java.lang.NoSuchMethodError: javax.wsdl.Operation: method getExtensibilityElements()Ljava/util/List; not found at org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateOperatio ns(WSDL11ToAxisServiceBuilder.java:1241) at org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populatePortType (WSDL11ToAxisServiceBuilder.java:447) at org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateEndpoint s(WSDL11ToAxisServiceBuilder.java:360) at org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateService( WSDL11ToAxisServiceBuilder.java:281) at org.apache.axis2.description.WSDL11ToAllAxisServicesBuilder.populateAllS ervices(WSDL11ToAllAxisServicesBuilder.java:109) at org.apache.axis2.deployment.repository.util.ArchiveReader.processWSDLFil e(ArchiveReader.java:230) at org.apache.axis2.deployment.repository.util.ArchiveReader.processFilesIn Folder(ArchiveReader.java:431) at org.apache.axis2.deployment.repository.util.ArchiveReader.processWSDLs(A rchiveReader.java:269) at org.apache.axis2.deployment.ServiceDeployer.deploy(ServiceDeployer.java: 64) at org.apache.axis2.deployment.repository.util.DeploymentFileData.deploy(De ploymentFileData.java:137) at org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.j ava:571) at org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList java:141) at org.apache.axis2.deployment.RepositoryListener.update(RepositoryListener java:318) at org.apache.axis2.deployment.RepositoryListener.checkServices(RepositoryL istener.java:220) at org.apache.axis2.deployment.DeploymentEngine.loadServices(DeploymentEngi ne.java:118) at org.apache.axis2.deployment.WarBasedAxisConfigurator.loadServices(WarBas edAxisConfigurator.java:272) at org.apache.axis2.context.ConfigurationContextFactory.createConfiguration Context(ConfigurationContextFactory.java:78) at org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServle t.java:500) at org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:420) at com.menlo.axis2.AxisServlet.init(AxisServlet.java:24) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Where to put Java Classes
other than web-inf/classes ? M-- - Original Message - Wrom: FPEGAUTFJMVRESKPNK To: axis-user@ws.apache.org Sent: Monday, November 26, 2007 9:53 AM Subject: Where to put Java Classes Hi, I need to ask where should I suppose to keep the class files which Client access? e.g. My Client is JSP which I have put in webapps/Axis2/axis2-web. It is accessing a java class . Where should I put that class? or suppose I'm using Stubs; where should I put stubs so that JSP client will call them?? Regards Nasreen -- Share life as it happens with the new Windows Live. Share now!
Re: WS-Security Policy - Password in Clear Text
your EPR is incorrect! in your axis2.xml you should have InflowSecurity defined ..here is an example module ref=rampart/ parameter name=InflowSecurity action itemsSignature/items signaturePropFileservice.properties/signaturePropFile /action /parameter where service.properties should contain these entries org.apache.ws.security.crypto.provider=SecurityProviderClass org.apache.ws.security.crypto.merlin.keystore.type=jks org.apache.ws.security.crypto.merlin.keystore.password=PutPassworkHere org.apache.ws.security.crypto.merlin.file=NameOfJKSFileCreatedByKeyTool I would start with the provider I would suggest BouncyCastle http://www.bouncycastle.org/ and work out from there M-- - Original Message - Wrom: OEAIJJPHSCRTNHGSW To: axis-user@ws.apache.org Sent: Monday, November 12, 2007 11:07 AM Subject: Re: WS-Security Policy - Password in Clear Text Hi, I was able to resolve the digest password issue by adding the transportbinding tag to the policy.xml file. My current policy.xml file is wsp:Policy wsu:Id=UTOverTransport xmlns:wsu=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd; xmlns:wsp=http://schemas.xmlsoap.org/ws/2004/09/policy; wsp:ExactlyOne wsp:All sp:TransportBinding xmlns:sp=http://schemas.xmlsoap.org/ws/2005/07/securitypolicy; wsp:Policy /wsp:Policy /sp:TransportBinding sp:SignedSupportingTokens xmlns:sp=http://schemas.xmlsoap.org/ws/2005/07/securitypolicy; wsp:Policy sp:UsernameToken / /wsp:Policy /sp:SignedSupportingTokens /wsp:All /wsp:ExactlyOne /wsp:Policy Using the above policy.xml file I am able to send the password in clear text and the server returns successfully but the client throws the below exception: Exception in thread main java.lang.NullPointerException at org.apache.rampart.RampartEngine.process(RampartEngine.java:90) at org.apache.rampart.handler.RampartReceiver.invoke(RampartReceiver.java:85) at org.apache.axis2.engine.Phase.invoke(Phase.java:292) at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:212) at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:132) at org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAxisOperation.java:336) at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:389) at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211) at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163) at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:528) at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:508) at com.nwa.fcsservicesweb.service.FcsServiceClient.main(FcsServiceClient.java:81) The client code and the handler code is below. Can anyone tell me what am I doing wrong. public static void main(String[] args) throws Exception { ConfigurationContext ctx = ConfigurationContextFactory .createConfigurationContextFromFileSystem( C:\\Java\\axis2-1.3\\repository, null); ServiceClient client = new ServiceClient(ctx, null); Options options = new Options(); options.setAction(\\); options.setTo(new EndpointReference(Endpoint)); RampartConfig rc = new RampartConfig(); rc.setUser(user); rc.setPwCbClass(PWCBHandler); Policy policy = loadPolicy(policy.xml); policy.addAssertion(rc); options.setProperty(RampartMessageData.KEY_RAMPART_POLICY, policy); client.setOptions(options); client.engageModule(addressing); client.engageModule(rampart); OMElement response = client.sendReceive(getPayload(101782)); System.out.println(response); } private static Policy loadPolicy(String xmlPath) throws Exception { StAXOMBuilder builder = new StAXOMBuilder(xmlPath); return PolicyEngine.getPolicy(builder.getDocumentElement()); } private static OMElement getPayload(String value) { OMFactory factory = OMAbstractFactory.getOMFactory(); OMNamespace ns = factory.createOMNamespace( namespace, ns1); OMElement elem = factory.createOMElement(getPassword, null); OMElement childElem = factory.createOMElement(user, null); childElem.setText(value); elem.addChild(childElem); System.out.println(elem); return elem; } public class PWCBHandler implements CallbackHandler { public void handle(Callback[] callbacks)
Re: Axis Encoding problems?
Hi Scott- Any possibility we can get you to upgrade to either Axis 1.3 http://www.apache.org/dyn/closer.cgi/ws/axis/1_3/ or Axis 1.4 http://apache.mirror99.com/ws/axis/1_4/? Thanks/ M- - Original Message - Wrom: MEPYOQKEDOTWFAO To: axis-user@ws.apache.org Sent: Monday, November 12, 2007 12:11 PM Subject: Axis Encoding problems? Hi All, We are experiencing a encoding issue that we believe may be a bug in the axis library. We are using axis 1.1 Tomcat 4.1 There seems to be a problem with Utf-8 where Latin 1 (ISO-8859-1) seems to work fine. TIA, Scott -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.
Re: Axis2 sample - pojoguide Unexpected EOF in prolog
Hi Rick- if you display the wsdl I'll try WSDL2Java to produce the service which I will then upload the aar/activate the service then write a client to extract at least 1 parameter.. Thanks/ Martin- - Original Message - Wrom: OWCONEUQZAAFXI To: axis-user@ws.apache.org Sent: Tuesday, November 06, 2007 8:18 AM Subject: Re: Axis2 sample - pojoguide Unexpected EOF in prolog Hi Martin, Thank you for your suggestions. I still the get the same prolog error for the pojoguide sample I checked and tried various ideas along with your suggestions without a sample client working. I dont believe CHUNKED_ENCODING is enabled as a default?.. to verify please display contents of %CATALINA_HOME%/webapps/axis2/WEB-INF/conf/axis2.xml Also prolog error codes are caused by the parser so verifying the version of xerces is critical My xerces is located at %CATALINA_HOME%/webapps/axis2/WEB-INF/lib/xercesImpl-2.8.1.jar (i.e. Xerces version 2.8.1) Martin 1.) I un-installed the windows Tomcat installation and downloaded the tomcat5.5.25 zip and moved it on c/tomcat 2.) using notepad %CATALINA_HOME%/webapps/axis2/WEB-INF/conf/axis2.xml my axis2.xml shows that encoding check is enabled. part of the standard axis2.xml .. transportSender name=tcp class=org.apache.axis2.transport.tcp.TCPTransportSender/ transportSender name=local class=org.apache.axis2.transport.local.LocalTransportSender/ transportSender name=http class=org.apache.axis2.transport.http.CommonsHTTPTransportSender parameter name=PROTOCOLHTTP/1.1/parameter parameter name=Transfer-Encodingchunked/parameter .. 3.) I used filemon.exe and traced the startup of Tomcat 12:26:13java.exe:3000READ C:\apache-tomcat-5.5.25\webapps\axis2\WEB-INF\conf\axis2.xmlSUCCESS Offset: 0 Length: 24161 to check that the correct file was read. 4.) I used filemon to trace the run of sample pojoguide ant rpc.client.run 12:30:41java.exe:3760READ C:\apache-tomcat-5.5.25\webapps\axis2\WEB-INF\lib\xercesImpl-2.8.1.jar SUCCESSOffset: 1123181 Length: 89762 to check that the correct file was read. The xeces*.jar and the axis2.xml seem to be correct and in the right place Maybe there is something else incorrectly configured? Is there any way to get more tracing information after the call to serviceClient.invokeRobust(opSetWeather, opSetWeatherArgs); ? Is there a site where I could compare my installation against a working one? Rick
Re: Referring to Creating Web Services with Apache Axis -- 5/22/2002
Referring to Creating Web Services with Apache Axis -- 5/22/2002which version xerces are you running ? M-- - Original Message - Wrom: FDULHPQQWOYIYZUNN To: axis-user@ws.apache.org ; [EMAIL PROTECTED] Sent: Monday, November 05, 2007 4:18 PM Subject: Referring to Creating Web Services with Apache Axis -- 5/22/2002 I was going through your article written in 2002 on Apache Axis. Since then Axis2 has come out. I am new to Axis2 and Web Services. I was trying to follow the steps you wrote for Axis2. I was going through step 2 -- Java2WSDL: Generate WSDL File For the Given Fibonacci Interface. I ran the following for Axis2. C:\Documents and Settings\tcanales\workspace\Fibonacci\bin%AXIS2_HOME%\bin\Java 2WSDL -o fib.wsdl -l http://localhost:8080/axis/services/fibonacci; -tn urn: fibonacci -tp fibonacci -cn fibonacci.Fibonacci It created the attached wsdl. Then I tried to run the third step 3 -- WSDL2Java: Generate the Server-side Wrapper Code and Stubs For Easy client Access. I ran it with C:\Documents and Settings\tcanales\workspace\Fibonacci\bin%AXIS2_HOME%\bin\WSDL 2Java -o . -p fibonacci.ws -uri fib.wsdl I get the following error: Using AXIS2_HOME: C:\Teresa\Downloads\Axis\axis2-1.3 Using JAVA_HOME:C:\Program Files\Java\jdk1.5.0_13 Exception in thread main org.apache.axis2.wsdl.codegen.CodeGenerationException : Error parsing WSDL at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.init(CodeGenerat ionEngine.java:150) at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35) at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24) Caused by: javax.wsdl.WSDLException: WSDLException: faultCode=PARSER_ERROR: Pars er SAX Error: org.xml.sax.SAXException: Fatal Error: URI=file:///C:/Documents%20 and%20Settings/tcanales/workspace/Fibonacci/bin/fib.wsdl Line=1: Content is not allowed in prolog. at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.readInTheWSDLFile( CodeGenerationEngine.java:292) at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.init(CodeGenerat ionEngine.java:105) ... 2 more Caused by: org.xml.sax.SAXException: Fatal Error: URI=file:///C:/Documents%20and %20Settings/tcanales/workspace/Fibonacci/bin/fib.wsdl Line=1: Content is not all owed in prolog. at org.apache.axis2.util.XMLUtils$ParserErrorHandler.fatalError(XMLUtils .java:390) at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source) at org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispat ch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un known Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) at org.apache.xerces.parsers.DOMParser.parse(Unknown Source) at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source) at org.apache.axis2.util.XMLUtils.newDocument(XMLUtils.java:205) at org.apache.axis2.util.XMLUtils.newDocument(XMLUtils.java:250) at org.apache.axis2.util.XMLUtils.newDocument(XMLUtils.java:233) at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.readInTheWSDLFile( CodeGenerationEngine.java:285) ... 3 more I think I have to run Java2WSDL with different options and that may be the reason for the problem in WSDL2Java. Can you tell me what I am doing wrong?? If I need to email someone else please let me know. Thanks, Teresa Canales Fibonacci.wsdl -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: IllegalAccessError
Jason- where is hibernate.properties? did you grant access for catalina to read hibernate.properties in this location? Martin - Original Message - Wrom: BLVLMHAALPTCXLYRWTQTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFMY To: axis-user@ws.apache.org Sent: Wednesday, October 17, 2007 9:07 AM Subject: RE: IllegalAccessError I tried your suggestion but I still get the same error. Note that class in the stacktrace HibernateUtil is my utility class to initialize a hibernate session. It lives in a jar under my aar/lib dir. The hibernate classes all live in jars under axis2/WEB-INF/lib. Is that a problem ? java.lang.IllegalAccessError: tried to access method org.hibernate.cfg.Mappings.init(Ljava/util/Map;Ljava/util/Map;Ljava/ut il/Map;Ljava/util/Map;Ljava/util/Map;Ljava/util/Map;Ljava/util/Map;Ljava /util/List;Ljava/util/List;Lorg/hibernate/cfg/NamingStrategy;Ljava/util/ Map;Ljava/util/Map;Ljava/util/Map;Ljava/util/List;Ljava/util/Map;Ljava/u til/Map;)V from class org.hibernate.cfg.ExtendedMappings at org.hibernate.cfg.ExtendedMappings.init(ExtendedMappings.java:65) at org.hibernate.cfg.AnnotationConfiguration.createExtendedMappings(Annotat ionConfiguration.java:175) at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationCo nfiguration.java:263) at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1 283) at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(Annotation Configuration.java:915) at com.bae.nedc.wfnp.util.HibernateUtil.clinit(HibernateUtil.java:26) at com.bae.nedc.wfnp.configuration.WFNPConfiguration.catalogConfigExists(WF NPConfiguration.java:79) at com.bae.nedc.wfnp.configuration.WFNPConfiguration.getConfig(WFNPConfigur ation.java:56) at com.bae.nedc.wfnp.configuration.WFNPConfiguration.getStagingPath(WFNPCon figuration.java:172) at com.bae.nedc.wfnp.create.HoldingManager.init(HoldingManager.java:46) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorA ccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingCons tructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:494) at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:84) at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:60) at org.springframework.beans.factory.support.SimpleInstantiationStrategy.in stantiate(SimpleInstantiationStrategy.java:52) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.instantiateBean(AbstractAutowireCapableBeanFactory.java:640) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:626) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.createBean(AbstractAutowireCapableBeanFactory.java:381) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObjec t(AbstractBeanFactory.java:245) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.g etSingleton(DefaultSingletonBeanRegistry.java:140) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab stractBeanFactory.java:242) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab stractBeanFactory.java:156) at org.springframework.beans.factory.support.BeanDefinitionValueResolver.re solveReference(BeanDefinitionValueResolver.java:248) at org.springframework.beans.factory.support.BeanDefinitionValueResolver.re solveValueIfNecessary(BeanDefinitionValueResolver.java:128) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:950) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.populateBean(AbstractAutowireCapableBeanFactory.java:740) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac tory.createBean(AbstractAutowireCapableBeanFactory.java:417) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObjec t(AbstractBeanFactory.java:245) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.g etSingleton(DefaultSingletonBeanRegistry.java:140) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab stractBeanFactory.java:242) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab stractBeanFactory.java:156) at org.springframework.beans.factory.support.DefaultListableBeanFactory.pre InstantiateSingletons(DefaultListableBeanFactory.java:273) at org.springframework.context.support.AbstractApplicationContext.refresh(A