HI,
I'm wondering actually, since the stack below shows the message which is send, and this looks like a soap message. But there is this error which says me, that this looks more like html instead of Soap.
So, while executing this:
I get the following error:Code:LogServiceRequestDocument doc = LogServiceRequestDocument.Factory.newInstance(); LogServiceRequest addNewLogServiceRequest = doc.addNewLogServiceRequest(); LogMessage logMessage = addNewLogServiceRequest.addNewLogMessage(); logMessage.addMessageParameter(property); logMessage.setMessagekey(msgkey); logMessage.setApplication("asdf"); getWebServiceTemplate().marshalSendAndReceive(doc);
Code:686 [main] DEBUG org.springframework.ws.client.MessageTracing - Sent request [<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Header/><SOAP-ENV:Body><sch:LogServiceRequest xmlns:sch="http://ch.glencore.com/logservice/schemas"><sch:LogMessage><sch:application>asdf</sch:application><sch:messagekey>key</sch:messagekey><sch:messageParameter>messageproperty</sch:messageParameter></sch:LogMessage></sch:LogServiceRequest></SOAP-ENV:Body></SOAP-ENV:Envelope>] 04.03.2008 11:01:29 com.sun.xml.internal.messaging.saaj.soap.MessageImpl identifyContentType SCHWERWIEGEND: SAAJ0537: Invalid Content-Type. Could be an error message instead of a SOAP message Could not create message from InputStream: Invalid Content-Type:text/html. Is this an error message instead of a SOAP response?; nested exception is com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Invalid Content-Type:text/html. Is this an error message instead of a SOAP response? org.springframework.ws.soap.SoapMessageCreationException: Could not create message from InputStream: Invalid Content-Type:text/html. Is this an error message instead of a SOAP response?; nested exception is com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Invalid Content-Type:text/html. Is this an error message instead of a SOAP response? Caused by: com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Invalid Content-Type:text/html. I s this an error message instead of a SOAP response? at com.sun.xml.internal.messaging.saaj.soap.MessageImpl.identifyContentType(Unknown Source) at com.sun.xml.internal.messaging.saaj.soap.MessageImpl.<init>(Unknown Source) at com.sun.xml.internal.messaging.saaj.soap.ver1_1.Message1_1Impl.<init>(Unknown Source) at com.sun.xml.internal.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl.createMessage(Unknown Source) at org.springframework.ws.soap.saaj.SaajSoapMessageFactory.createWebServiceMessage(SaajSoapMessageFactory.java:163) at org.springframework.ws.transport.AbstractWebServiceConnection.receive(AbstractWebServiceConnection.java:53) at org.springframework.ws.client.core.WebServiceTemplate.sendAndReceive(WebServiceTemplate.java:410) at org.springframework.ws.client.core.WebServiceTemplate.marshalSendAndReceive(WebServiceTemplate.java:265) at org.springframework.ws.client.core.WebServiceTemplate.marshalSendAndReceive(WebServiceTemplate.java:253) at org.springframework.ws.client.core.WebServiceTemplate.marshalSendAndReceive(WebServiceTemplate.java:245) at com.glencore.ch.logservice.client.LogServiceClient.log(LogServiceClient.java:24) at com.glencore.ch.logservice.client.LogServiceClient.main(LogServiceClient.java:41)Does anyone have an idea ? isn't this strange , since the message sent is shown and this is SOAP ??Code:part of my spring-ws-servlet.xml <bean id="LogService" class="org.springframework.ws.wsdl.wsdl11.DynamicWsdl11Definition"> <property name="builder"> <bean class="org.springframework.ws.wsdl.wsdl11.builder.XsdBasedSoap11Wsdl4jDefinitionBuilder"> <property name="schema" value="classpath:schema\src\logservice-webservice\src\main\xsd\LogServiceSchema.xsd" /> <property name="portTypeName" value="LogService" /> <property name="targetNamespace" value="http://ch.glencore.com/logservice/definitions" /> <property name="followIncludeImport" value="true" /> <property name="locationUri" value="http://localhost:8080/logservice-webservice" /> <property name="locationUri" value="${uri}" /> </bean> </property> </bean>
thankx in advance
regards
marco persi


Reply With Quote