RE: Axis, HTTPS with Web Start
Title: Message Is your client trying to access the web service on the domainit was downloaded from via WebStart? I rememberhaving problems with cross-domain access. I ended up signing all the jars in order to get it to work. -Original Message-From: Christian faucher [mailto:[EMAIL PROTECTED] Sent: Friday, May 27, 2005 9:02 AMTo: axis-user@ws.apache.orgSubject: Axis, HTTPS with Web StartGreetings,I have a situation where I am not sure if it belongs to this mailing or Web Start's.I have a Axis client, being deployed thru Web Start on client machines.It can also be run standalone (java 'main'). I run JDK 1.4.2 with Axis 1.2 RC2 (yeah, I know I have to upgrade to 1.2...).AppServer is SunOne 7.The client connects to an Axis server thru HTTPS (which is not the server from where it was downloaded).I have the JNLP security set to 'all-permissions' which means (in theory) that I have the same rights than a standalone application. When I run the client as STANDALONE, works perfectly:I connect to the Axis Server with HTTPS, get my response back, etc.When I start the very same client thru WebStart, the HTTPS connections fail, but the unsecure HTTP do work.For HTTPS, it fails during the SSL handshake for the server (see stack trace below). Any clue on this?Here is the exception I get on the client side.No sign on my request whatsoever on the server side, which makes me belief I dont even get out of my client app...ansport.http.HTTPSender.getSocket(HTTPSender.java:131)at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:370)at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:88) at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)at org.apache.axis.SimpleChain.invoke(SimpleChain.java :83)at org.apache.axis.client.AxisClient.invoke(AxisClient.java:147)at org.apache.axis.client.Call.invokeEngine(Call.java:2719)at org.apache.axis.client.Call.invoke(Call.java:2702)at org.apache.axis.client.Call.invoke (Call.java:2378)at org.apache.axis.client.Call.invoke(Call.java:2301)at org.apache.axis.client.Call.invoke(Call.java:1758)at com.axacanada.b2b.common.util.AxisInvocationHandler.invoke(AxisInvocationHandler.java :98)at $Proxy0.makeNewBusiness(Unknown Source)at com.axacanada.b2b.cq.client.AbstractRequestSenderThread.run(AbstractRequestSenderThread.java:74)at com.axacanada.b2b.cq.client.RequestSenderThread.run (RequestSenderThread.java:70){http://xml.apache.org/axis/}hostname:WS-1235javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:97)at org.apache.axis.strategies.InvocationStrategy.visit (InvocationStrategy.java:32)at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)at org.apache.axis.client.AxisClient.invoke(AxisClient.java :147)at org.apache.axis.client.Call.invokeEngine(Call.java:2719)at org.apache.axis.client.Call.invoke(Call.java:2702)at org.apache.axis.client.Call.invoke(Call.java:2378)at org.apache.axis.client.Call.invoke (Call.java:2301)at org.apache.axis.client.Call.invoke(Call.java:1758)at com.axacanada.b2b.common.util.AxisInvocationHandler.invoke(AxisInvocationHandler.java:98)at $Proxy0.makeNewBusiness(Unknown Source) at com.axacanada.b2b.cq.client.AbstractRequestSenderThread.run(AbstractRequestSenderThread.java:74)at com.axacanada.b2b.cq.client.RequestSenderThread.run(RequestSenderThread.java:70)Caused by: javax.net.ssl.SSLException : Unrecognized SSL message, plaintext connection?at com.sun.net.ssl.internal.ssl.InputRecord.b(Unknown Source)at com.sun.net.ssl.internal.ssl.InputRecord.read(Unknown Source)at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a (Unknown Source)at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(Unknown Source)at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(Unknown Source)at org.apache.axis.components.net.JSSESocketFactory.create (JSSESocketFactory.java:186)at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:131)at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:370)at org.apache.axis.transport.http.HTTPSender.invoke (HTTPSender.java:88)... 13 more2005-05-27 10:06:03,165 [SOAP Request Sender] ERROR AbstractRequestSenderThread - AxisFault: ; nested exception is: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection? Fault Actor : nullFault Code: {http://schemas.xmlsoap.org/soap/envelope/}Server.userExceptionFault Role: nullFault String: javax.net.ssl.SSLException : Unrecognized SSL message, plaintext connection?-- This message has been scanned
RE: Bug in Deserializer code?! onStartChild(..)
Once I switched from wrapped style to rpc/encoded my service started working. I guess I was registering my typeMappings on the client side with the wrong encoding style http://schemas.xmlsoap.org/soap/encoding/ Do I need to use a different URL when registering type mappings with the wrapped style? From: Oleg Lebedev [mailto:[EMAIL PROTECTED] Sent: Sat 4/16/2005 1:01 PM To: axis-user@ws.apache.org Subject: Bug in Deserializer code?! onStartChild(..) I've been getting a lot of deserializer errors on the client side from Axis 1.2 RC3. The client make a findSchoolByName(String) call and the server finds the school and sends it back to the client. The error occurs on the client side when trying to deserialize the message. The message from the server and the error stack trace are shown at the end of this message. I started debugging the code and found out that in RPCHandler.onStartChild(..) method the following piece of code: // If that didn't work, try position // FIXME : Do we need to be in EITHER named OR positional // mode? I.e. will it screw us up to find something // by position if we've already looked something up // by name? I think so... if (paramDesc == null) { if (isResponse) { paramDesc = operation.getReturnParamDesc(); } else { paramDesc = operation.getParameter(rpcElem.getParams().size() - 1); } } finds paramDesc, with the following field values: javaType = null name.localPart = findSchoolByNameResponsefindSchoolByNameReturn This doesn't look right to me because of the first sign. Since javaType is null the following sets destClass to null. destClass = paramDesc.getJavaType(); Later in the code, dser is set to null by the following: dser = context.getDeserializer(destClass, type); This causes the error message below to be thrown. Is this a bug? Has it been fixed? Is there a work around? Any help would be greatly appreciated! Here is how I registered the School type in WSDD which is returned by findSchoolByNameResponse: beanMapping qname=ns:School xmlns:ns=urn:dss.sww.com languageSpecificType=java:com.sww.dss.domain.model.hibernate.School/ Here is the XML response from the server: ?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 findSchoolByNameResponse xmlns=urn:dss.sww.com findSchoolByNameReturn nameShkola/name /findSchoolByNameReturn /findSchoolByNameResponse /soapenv:Body /soapenv:Envelope Here is the error stack trace: org.xml.sax.SAXException: Deserializing parameter 'findSchoolByNameReturn': could not find deserializer for type {urn:dss.sww.com}School AxisFault faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException faultSubcode: faultString: org.xml.sax.SAXException: Deserializing parameter 'findSchoolByNameReturn': could not find deserializer for type {urn:dss.sww.com}School faultActor: faultNode: faultDetail: {http://xml.apache.org/axis/}stackTrace:org.xml.sax.SAXException: Deserializing parameter 'findSchoolByNameReturn': could not find deserializer for type {urn:dss.sww.com}School at org.apache.axis.message.RPCHandler.onStartChild(RPCHandler.java:270) at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035) at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165) at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1140) at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:238) at org.apache.axis.message.RPCElement.getParams(RPCElement.java:386) at org.apache.axis.client.Call.invoke(Call.java:2437) at org.apache.axis.client.Call.invoke(Call.java:2336) at org.apache.axis.client.Call.invoke(Call.java:1793) -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. If you have questions about this email, please contact the IT Help Desk. Mail
RE: Java2wsdl and interfaces
Could anyone give me some feedback on the following? -Original Message- From: Oleg Lebedev [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:51 PM To: axis-user@ws.apache.org Subject: Java2wsdl and interfaces Greetings. I am trying to expose my Java interface as a web service. The interface itself defines a method, which returns IState interfaces. So, when I use axis-java2wsdl ant task I get the following warning: The class IState does not contain a default constructor, which is a requirement for a bean class. The class cannot be converted into an xml schema type. An xml schema anyType will be used to define this class in the wsdl file. This causes axis-java2wsdl to avoid generating xsd type mappings for the IState interface. So, when later I use axis-wsdl2java, I get the following error: IState is referenced but not defined. I remember other people having the same problem, but I can't find a solution on the mailing list. So, the question is how I tell axis-java2wsdl that a concrete implementation class State should be used when generating type mappings for interface IState? Regards. Oleg -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. If you have questions about this email, please contact the IT Help Desk. Mail
RE: Re: Java2wsdl and interfaces
If Axis allowed XSDTypeToJavaClass mappings or JavaInterfaceToJavaClass mappings in addition to PackageToNamespace mappings, that would be great. This way Axis could use the specified java class when it doesn't know how to generate an xsd type for the target java interface (IState in my case). -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Tim K. (Gmane) Sent: Wednesday, April 06, 2005 2:56 PM To: axis-user@ws.apache.org Subject: Re: Java2wsdl and interfaces I don't think it's possible to do what you want, you need your method to return a true JavaBean class, not an interface. Think about it this way: what if IState were an argument to one of your methods (I know this is not your case)? When a client called your service how would Axis know what instance(s) of IState to create? Tim Oleg Lebedev wrote: Could anyone give me some feedback on the following? -Original Message- From: Oleg Lebedev [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:51 PM To: axis-user@ws.apache.org Subject: Java2wsdl and interfaces Greetings. I am trying to expose my Java interface as a web service. The interface itself defines a method, which returns IState interfaces. So, when I use axis-java2wsdl ant task I get the following warning: The class IState does not contain a default constructor, which is a requirement for a bean class. The class cannot be converted into an xml schema type. An xml schema anyType will be used to define this class in the wsdl file. This causes axis-java2wsdl to avoid generating xsd type mappings for the IState interface. So, when later I use axis-wsdl2java, I get the following error: IState is referenced but not defined. I remember other people having the same problem, but I can't find a solution on the mailing list. So, the question is how I tell axis-java2wsdl that a concrete implementation class State should be used when generating type mappings for interface IState? Regards. Oleg -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. If you have questions about this email, please contact the IT Help Desk. Mail
RE: Axis, Spring and Hibernate
This looks like a Hibernate issue, so you may want to move this thread to the Hibernate forum. Some hints: - When you open a new Hibernate session you need to re-attach your cached objects to this session before using them. - Use Hibernate.initialize(Object), Session.refresh(Object), and Session.saveOrUpdateCopy(Object) methods Regards. Oleg -Original Message- From: Koney, Satish [mailto:[EMAIL PROTECTED] Sent: Monday, March 14, 2005 2:31 AM To: axis-user@ws.apache.org Subject: RE: Axis, Spring and Hibernate Ya...I could have used lazy=true but that requires the sesssion to be open when those elements are accessed. But I am using spring to maintain the sessions...It is opening at the start of the method and closing session when it is done with that. so by the time the elements are accessed in my client web applicatoin the sesssion is getting closed. that results in exceptions probably, I talked much about hibernate in Axis forum...but i believe that (De) serialzation is consuming time Thanks, . -Original Message- From: Arijit Mukherjee [SMTP:[EMAIL PROTECTED] Sent: Monday, March 14, 2005 2:24 PM To: axis-user@ws.apache.org Subject: RE: Axis, Spring and Hibernate If you are using hibernate-style beans (that is, collections are represented as sets/bags), you can set the option for lazy loading - in which case when you are retrieving one object, hibernate will not retrieve all the children unless asked to do so. This will reduce the time for mapping the relations and their children back into relevant objects. I have a similar problem because I am using Axis-generated stubs (which contains arrays for collections - and this rules out the possibility of lazy loading)... Arijit -Original Message- From: Koney, Satish [mailto:[EMAIL PROTECTED] Sent: 14 March 2005 07:57 To: axis-user@ws.apache.org Subject: RE: Axis, Spring and Hibernate it is not taking 20 minutes for executing the queries..the queries are executed fast.. the problem is with constructing those retrvied records into objects... Can someone plz help!! -Original Message- From: Sebastien Mayemba Mbokoso [SMTP:[EMAIL PROTECTED] Sent: Sunday, March 13, 2005 11:43 AM To:axis-user@ws.apache.org Subject: Re: Axis, Spring and Hibernate I am using Hibernaete in my current project with Axis too. It's not an Axis issue but just a Hibernate trouble. You have to investigate in the Hibernate Forum. 20 minutes for executing a queries it's not possible. My databases contains 32 tables with so many relationships and so many tables are full. My queries don't spend a lot of time as yours. Sebastien On Sat, 12 Mar 2005 10:52:28 -0500, Koney, Satish [EMAIL PROTECTED] wrote: Hi, I have two modules in my application. The first one is a webservice. (Axis 1.1, spring 1.1.3 and Hibernate 2.1.6 ) This web service is responsible for fetching, updating, deleting the records in database. The second one is web application which is consuming this web service. It is purely for presentation. It does not do anything other than presentation. The problem I am facing now is, when I request Hibernate for records in one table, it is executing so many queries. It is fetching records from the tables which have foreign-key relation with that table. So when the web application is using this web service, it is taking lot of time to load the page. ( 20 minutes just to display 5-6 records) On the Axis side, how can I control the (De)serialization of objects that I am getting from the web service? Please help!!! Thanks, . Confidential: This electronic message and all contents contain information from Syntel, Inc. which may be privileged, confidential or otherwise protected from disclosure. The information is intended to be for the addressee only. If you are not the addressee, any disclosure, copy, distribution or use of the contents of this message is prohibited. If you have received this electronic message in error, please notify the sender immediately and destroy the original message and all copies. Confidential: This electronic message and all contents contain information from Syntel, Inc. which may be privileged, confidential or otherwise protected from disclosure. The information is intended to be for the addressee only. If you are not the addressee, any disclosure, copy, distribution or use of the contents of this message is prohibited. If you have received this electronic message in error, please notify the sender immediately and destroy the original message and all copies.