Problema com Deploy do Axis

23 respostas
V

Pessoal,

Alguém já teve este problema ao tentar fazer o deploy do Axis:

D:\teste\projects\aplicacao\bat>java org.apache.axis.client.AdminClient …\src\br\co

m\teste\www\dmd\integration\wsdl\deploy.wsdd

09/01/2007 11:16:22 org.apache.axis.utils.JavaUtils isAttachmentSupported

WARNING: Unable to find required classes (javax.activation.DataHandler and javax

.mail.internet.MimeMultipart). Attachment support is disabled.

Processing file …\src\br\com\teste\www\dmd\integration\wsdl\deploy.wsdd

Exception: AxisFault

faultCode: {<a href="http://schemas.xmlsoap.org/soap/envelope/">http://schemas.xmlsoap.org/soap/envelope/</a>}Server.userException

faultSubcode:

faultString: java.net.ConnectException: Connection refused: connect

faultActor:

faultNode:

faultDetail:

{<a href="http://xml.apache.org/axis/">http://xml.apache.org/axis/</a>}stackTrace:java.net.ConnectException: Conne

ction refused: connect

at java.net.PlainSocketImpl.socketConnect(Native Method)

at java.net.PlainSocketImpl.doConnect(Unknown Source)

at java.net.PlainSocketImpl.connectToAddress(Unknown Source)

at java.net.PlainSocketImpl.connect(Unknown Source)

at java.net.SocksSocketImpl.connect(Unknown Source)

at java.net.Socket.connect(Unknown Source)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.lang.reflect.Method.invoke(Unknown Source)

at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSoc

ketFactory.java:153)

at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSoc

ketFactory.java:120)

at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:1

91)

at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.ja

va:404)

at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:138)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
y.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:165)

at org.apache.axis.client.Call.invokeEngine(Call.java:2784)

at org.apache.axis.client.Call.invoke(Call.java:2767)

at org.apache.axis.client.Call.invoke(Call.java:1792)

at org.apache.axis.client.AdminClient.process(AdminClient.java:439)

at org.apache.axis.client.AdminClient.process(AdminClient.java:404)

at org.apache.axis.client.AdminClient.process(AdminClient.java:410)

at org.apache.axis.client.AdminClient.process(AdminClient.java:320)

at org.apache.axis.client.AdminClient.main(AdminClient.java:463)
{http://xml.apache.org/axis/}hostname:teste050930

Obrigado,
Vinicius.

23 Respostas

D

Parece que ele não conseguiu conectar na aplicação para fazer deploy.

V

Tem idéia do porque?

Esse foi o resultado do WSDL2Java.bat:

D:\teste\projects\aplicacao\bat>WSDL2Java.bat

D:\teste\projects\aplicacao\bat>cd D:\teste\projects\aplicacao\bat

D:\teste\projects\aplicacao\bat>call classpath

D:\teste\projects\aplicacao\bat>set libc=D:\teste\eclipse\plugins\org.apache.axis_1.3
.0.v200606181221

D:\teste\projects\aplicacao\bat>set classpath=D:\teste\eclipse\plugins\org.apache.axi
s_1.3.0.v200606181221\lib\axis.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0
.v200606181221\lib\commons-logging-1.0.4.jar;D:\teste\eclipse\plugins\org.apache.
axis_1.3.0.v200606181221\lib\jaxrpc.jar;D:\teste\eclipse\plugins\org.apache.axis_
1.3.0.v200606181221\lib\saaj.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v
200606181221\lib\commons-discovery-0.2.jar;D:\teste\eclipse\plugins\org.apache.ax
is_1.3.0.v200606181221\lib\wsdl4j-1.5.1.jar;D:\teste\eclipse\plugins\org.apache.a
xis_1.3.0.v200606181221\lib\xmlParserAPIs.jar;D:\teste\eclipse\plugins\org.apache
.axis_1.3.0.v200606181221\lib\bin;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.
v200606181221\lib\activation.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v
200606181221\lib\xercesImpl.jar;

D:\teste\projects\aplicacao\bat>echo D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v

200606181221\lib\axis.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v2006061

81221\lib\commons-logging-1.0.4.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.

0.v200606181221\lib\jaxrpc.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v20

[telefone removido]\lib\saaj.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181

221\lib\commons-discovery-0.2.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.

v200606181221\lib\wsdl4j-1.5.1.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0

.v200606181221\lib\xmlParserAPIs.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3

.0.v200606181221\lib\bin;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v20060618

1221\lib\activation.jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181

221\lib\xercesImpl.jar;

D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\axis.jar;D:\teste

\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\commons-logging-1.0.4.j

ar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\jaxrpc.jar;D:

\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\saaj.jar;D:\teste\e

clipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\commons-discovery-0.2.jar

;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\wsdl4j-1.5.1.ja

r;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\xmlParserAPIs.

jar;D:\teste\eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\bin;D:\teste

eclipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\activation.jar;D:\teste\e

clipse\plugins\org.apache.axis_1.3.0.v200606181221\lib\xercesImpl.jar;

D:\teste\projects\aplicacao\bat>java org.apache.axis.wsdl.WSDL2Java -o …/src -s -S
true -c br.com.teste.www.dmd.integration.impl.Agent …/xml/integration.wsdl
09/01/2007 11:37:29 org.apache.axis.utils.JavaUtils isAttachmentSupported
WARNING: Unable to find required classes (javax.activation.DataHandler and javax
.mail.internet.MimeMultipart). Attachment support is disabled.

Gerou os .java diretinho.

Estou com alguns erros no arquivo wsdl no eclipse.

C

Prq nao usa JAX-WS ?
Java EE 5

@WebService
public class MeuWebService {

@WebMethod

public String ping() {

return pong !”;

}

}

Pra que complicar a vida ? :slight_smile:

Baixe o NetBeans e o GlassFish e saia fazendo a festa :wink:

D

chun, talvez o cara ainda nem usa um AS que suporte EJB3/JEE5.

Enfim…

Cara, para você fazer o deploy do WSDD, é preciso ter uma aplicação web rodando na mesma máquina. Está ciente disto?

C

por isso que eu disse… isso esta me parecendo mais um teste que uma app real… entao… teste com algo mais facil… use JAX-WS… Axis é coisa do passado.

V

Estava tentanto usar o NetBeans.

Fiz assim:

Criei um novo -> Serviço Web do WSDL e ele gerou tudo automaticamente.

Mas não estou usando o tomcat embutido. Depois eu gerei o war e mandei para este outro tomcat que estou usando, fiz o teste:

Port Name Status Information
IntegrationService ACTIVE
Address: http://localhost:6666/business/IntegrationService
WSDL: http://localhost:6666/business/IntegrationService?wsdl
Port QName: {http://www.teste.com.br/dmd/integration/}IntegrationService
Implementation class: br.com.teste.www.dmd.integration.Integration

Creio que está tudo ok.

Mas quando tentei comunicar com o esse servidor, deu o sequinte erro:

08/01/2007 13:54:37

com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher toMessageInfo

SEVERE: Error in decoding SOAP Message

Error in decoding SOAP Message

at

com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.toInternalMessage(SOAPXMLDecoder.java:89)

at

com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher.toMessageInfo(SOAPMessageDispatcher.java:187)

at

com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher$SoapInvoker.invoke(SOAPMessageDispatcher.java:571)

at

com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher.receive(SOAPMessageDispatcher.java:141)

at com.sun.xml.ws.server.Tie.handle(Tie.java:88)

at

com.sun.xml.ws.transport.http.servlet.WSServletDelegate.handle(WSServletDelegate.java:333)

at

com.sun.xml.ws.transport.http.servlet.WSServletDelegate.doPost(WSServletDelegate.java:288)

at

com.sun.xml.ws.transport.http.servlet.WSServlet.doPost(WSServlet.java:77)

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.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)

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:664)

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: javax.xml.ws.soap.SOAPFaultException: Cannot find the dispatch

method

at

com.sun.xml.ws.encoding.soap.SOAPDecoder.raiseFault(SOAPDecoder.java:674)

at

com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.decodeDispatchMethod(SOAPXMLDecoder.java:152)

at

com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeBodyContent(SOAPDecoder.java:337)

at

com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeBody(SOAPDecoder.java:327)

at

com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeEnvelope(SOAPDecoder.java:250)

at

com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.toInternalMessage(SOAPXMLDecoder.java:81)

 24 more
C

Qual AS vc tah usando ?
Qual versao do Axis ?

V

Baixei o NetBeans 5.5 pt_BR, instalei e estou usando do jeito que veio.

O Axis é o 1.4.

C

vc esta criando um CLIENTE webservice ou um Servico em WebService ?

V

Apenas o serviço, o cliente eu acesso por uma aplicação desenvolvida em php utilizando o nusoap.

V

Coloquei as classes no webapps/axis/…

Fiz o deploy e não não deu, mas quando tentei listar os serviços deu esse erro:

And now… Some Services
AXIS error

Sorry, something seems to have gone wrong… here are the details:

Fault - Could not find class for the service named: br.com.teste.www.dmd.integration.wsdl.IntegrationBindingSkeleton
Hint: you may need to copy your class files/tree into the right location (which depends on the servlet system you are using).; nested exception is:
java.lang.ClassNotFoundException: br.com.teste.www.dmd.integration.wsdl.IntegrationBindingSkeleton

AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.generalException
faultSubcode:
faultString: Could not find class for the service named: br.com.teste.www.dmd.integration.wsdl.IntegrationBindingSkeleton
Hint: you may need to copy your class files/tree into the right location (which depends on the servlet system you are using).; nested exception is:
java.lang.ClassNotFoundException: br.com.teste.www.dmd.integration.wsdl.IntegrationBindingSkeleton
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}hostname:teste050930

D

colocou no WEB-INF/classes ?

V

Com relação ao Eclipse e Axis, foi resolvido apenas o WSDL está dando alguns erros, mas funcionou direitinho.

Agora sobre o NetBeans, eu estou utilizando de forma certa?

Qual versão desse glassfish é recomendando utilizar?
Ele funciona com o Eclipse ou NetBeans?

V

O problema era as classes mesmo, a pasta estava desatualizada.

C

vinucho:
Com relação ao Eclipse e Axis, foi resolvido apenas o WSDL está dando alguns erros, mas funcionou direitinho.

Agora sobre o NetBeans, eu estou utilizando de forma certa?

Qual versão desse glassfish é recomendando utilizar?
Ele funciona com o Eclipse ou NetBeans?

WebService com NetBeans é super simples… crie um Web Application… e click em “New…” no menu file… selecione dae WebService… pronto… tah criado… ae eh soh apertar PLAY e ele inicia o tomcat e faz deploy do webservice inicializando seu browser…

Fiz alguns testes aqui… nao precisa do glassfish pro JAX-WS funcionar… pode usar o tomcat q vem com ele mesmo… o GlassFish versao v2 b30 esta bem legal… tem plugin nativo pro netbeans e um plugin pro eclipse tmb…

V

Vocês poderiam me dar uma dica para desenvolver web services sem utilizar o axis?

Ou ajudar a resolver o problema que estou tendo com o netbeans?

C

Jax-WS é o caminho… OU use Java Se 6 ou parta para Java EE 5

http://www.go-java.com/blog/2006/09/17/1158507724169.html

Axis é coisa do passado. nao importa qual versao… se a 1 ou a 2 , é coisa do passado. Ficar sofrendo a toa é besteira.

V

Por acaso tem alguma coisa em português?

V

Tem algum pacotão completo que vem até a IDE?

C

O netbeans já vem completo… no tutorial explica como criar usando ele… quer mais simples q isso ?

V

Baixei esse arquivo do netbeans: jdk-6-nb-5_5-win.exe

Tem alguma melhor recomendado?

V

Peguei os nome completos:

Qual desses eu baixou e qual a diferença entre eles?

Windows Platform - Java Application Platform SDK Update 2 No JDK

Windows Platform - Java EE SDK 5 Update 2 No JDK

Obrigado.

V

Criei o web services, adicionei uma operação, fiz o teste e rodou numa boa.

Mas quando tento comunicar dá esse erro no browser:

Array ( [faultcode] => soapenv:Client [faultstring] => Cannot find the dispatch method )

e no tomcat:

10/01/2007 11:39:21 com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher to

MessageInfo

SEVERE: Error in decoding SOAP Message

Error in decoding SOAP Message

at com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.toInternalMessage(

SOAPXMLDecoder.java:89)

at com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher.toMessageIn

fo(SOAPMessageDispatcher.java:187)

at com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher$SoapInvoker

.invoke(SOAPMessageDispatcher.java:571)

at com.sun.xml.ws.protocol.soap.server.SOAPMessageDispatcher.receive(SOA

PMessageDispatcher.java:141)

at com.sun.xml.ws.server.Tie.handle(Tie.java:88)

at com.sun.xml.ws.transport.http.servlet.WSServletDelegate.handle(WSServ

letDelegate.java:333)

at com.sun.xml.ws.transport.http.servlet.WSServletDelegate.doPost(WSServ

letDelegate.java:288)

at com.sun.xml.ws.transport.http.servlet.WSServlet.doPost(WSServlet.java

:77)

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(Appl

icationFilterChain.java:252)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF

ilterChain.java:173)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV

alve.java:213)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV

alve.java:178)

at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica

torBase.java:432)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j

ava:126)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j

ava:105)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal

ve.java:107)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav

a:148)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java

:869)

at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.p

rocessConnection(Http11BaseProtocol.java:664)

at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpo

int.java:527)

at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFol

lowerWorkerThread.java:80)

at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP

ool.java:684)

at java.lang.Thread.run(Thread.java:595)

Caused by: javax.xml.ws.soap.SOAPFaultException: Cannot find the dispatch method
at com.sun.xml.ws.encoding.soap.SOAPDecoder.raiseFault(SOAPDecoder.java:
  1. at com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.decodeDispatchMeth
    od(SOAPXMLDecoder.java:152)
    at com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeBodyContent(SOAPDecode
    r.java:337)
    at com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeBody(SOAPDecoder.java:
  2. at com.sun.xml.ws.encoding.soap.SOAPDecoder.decodeEnvelope(SOAPDecoder.j
    ava:250)
    at com.sun.xml.ws.encoding.soap.server.SOAPXMLDecoder.toInternalMessage(
    SOAPXMLDecoder.java:81)
    … 24 more

Obrigado.

Criado 9 de janeiro de 2007
Ultima resposta 10 de jan. de 2007
Respostas 23
Participantes 3