Я создал wsdl в Eclipse и сгенерировал классы, используя Apache CXF. И после этого я интегрировал этот сервис в Jetty Server. Я реализую код на стороне сервера. Я использую инструмент SOAP UI для тестирования реализации сервера. В то время как я выполняю код, я получаю ошибку как
ОШИБКА:
WARN 23:47:30,240 | org.apache.cxf.aegis.type.TypeUtil | xsi:type absent, and no type available for sessionId
WARN 23:47:30,240 | org.apache.cxf.aegis.type.TypeUtil | xsi:type absent, and no type available for serverUrlenter code here
WARN 23:47:30,240 | org.apache.cxf.aegis.type.TypeUtil | xsi:type absent, and no type available for cipherTextValue
INFO 23:47:44,188 | org.apache.cxf.interceptor.LoggingOutInterceptor | Outbound Message
Здесь sessionId, serverUrl и cipherTextValue являются входными данными. Я не знаю, как решить эту ошибку. Кто-нибудь может сказать мне ответ. Я заблокировал здесь.
Пример запроса XML:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dpa="http://ws.ciphercloud.com/dpaas/">
<soapenv:Header/>
<soapenv:Body>
<dpa:detokenizeRequest>
<sessionId>?</sessionId>
<serverUrl>?</serverUrl>
<!--1 or more repetitions:-->
<cipherTextValue>**ajgkjfagla009!</cipherTextValue>
</dpa:detokenizeRequest>
</soapenv:Body>
</soapenv:Envelope>
И еще есть какие-то учебные пособия по настройке веб-сервисов с использованием Jetty.
Пожалуйста, ответьте мне. Это блокатор для меня ...
Спасибо заранее.
Спасибо за ваш ответ bmargulies.
Я использую Aegis, он отлично работает, когда я генерирую wsdl из java-кода, тогда мои веб-сервисы работают нормально. Но я сгенерировал Java-код из WSDL в то время, когда я получаю этот тип ошибки. Я отправляю свой файл appcontext.xml.
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"
xmlns:cxf="http://cxf.apache.org/core" xmlns:sec="http://cxf.apache.org/configuration/security"
xmlns:http="http://cxf.apache.org/transports/http/configuration"
xmlns:httpj="http://cxf.apache.org/transports/http-jetty/configuration"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-2.5.xsd
http://cxf.apache.org/core
http://cxf.apache.org/schemas/core.xsd
http://cxf.apache.org/jaxws
http://cxf.apache.org/schemas/jaxws.xsd
http://cxf.apache.org/configuration/security
http://cxf.apache.org/schemas/configuration/security.xsd
http://cxf.apache.org/transports/http/configuration
http://cxf.apache.org/schemas/configuration/http-conf.xsd
http://cxf.apache.org/transports/http-jetty/configuration
http://cxf.apache.org/schemas/configuration/http-jetty.xsd"
default-autowire="byName">
<!-- Load CXF modules from cxf.jar -->
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
<!-- Enable message logging using the CXF logging feature -->
<cxf:bus>
<cxf:features>
<cxf:logging />
</cxf:features>
</cxf:bus>
<!-- The service bean -->
<bean id="dataProtectionWebServiceImpl" class="com.ciphercloud.ws.dpaas.DataProtectionWebServiceImpl" />
<!-- Aegis data binding -->
<bean id="aegisBean" class="org.apache.cxf.aegis.databinding.AegisDatabinding"
scope="prototype" />
<bean id="jaxws-and-aegis-service-factory" class="org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean"
scope="prototype">
<property name="dataBinding" ref="aegisBean" />
<property name="serviceConfigurations">
<list>
<bean class="org.apache.cxf.jaxws.support.JaxWsServiceConfiguration" />
<bean class="org.apache.cxf.aegis.databinding.AegisServiceConfiguration" />
<bean class="org.apache.cxf.service.factory.DefaultServiceConfiguration" />
</list>
</property>
</bean>
<!-- Service endpoint -->
<!--
See http://incubator.apache.org/cxf/faq.html regarding CXF + Spring
AOP
-->
<jaxws:endpoint id="DataProtectionWebService"
implementorClass="com.ciphercloud.ws.dpaas.DataProtectionWebServiceImpl"
implementor="#dataProtectionWebServiceImpl" address="/ws">
<jaxws:serviceFactory>
<ref bean="jaxws-and-aegis-service-factory" />
</jaxws:serviceFactory>
</jaxws:endpoint>
</beans>
Это мой appcontext.xml. Это нормально, когда Java-код для WSDL. Но знайте проблему с Aegis, когда я генерировал код из wsdl в java.
Как вы сказали, я буду использовать jaxb вместо Aegis. Между тем, есть ли урок, связанный с вашей проблемой, пожалуйста, пришлите мне ссылки. А пока я тоже увижу этот jaxb.