2010-01-12 4 views
0

Nous avons un Java ws déployé sur Glassfish parlant à un autre Java déployé sur glassfish (les deux sont Java EE 5 et les deux sont en cours de développement sur netbeans 6.7.1). Il faut donc utiliser aucune de ces ws SSL, mais quand les principaux ws appelle l'autre nous obtenons cette erreur:Communication entre 2 services web sur 2 systèmes

WSTX-COORDINATOR-3005: registerResponse sent to EPR '<?xml version="1.0" encoding="UTF-8" standalone="yes"?><EndpointReference xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing"><Address>https://trinity2.its.local:8181/__wstx-services/wscoor/coordinator/registerResponse</Address><ReferenceParameters><jaxws:objectId xmlns:jaxws="http://jax-ws.dev.java.net/xml/ns/" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing">4e470037-57c9-4903-9b32-fafc6da84ec7</jaxws:objectId></ReferenceParameters></EndpointReference>' failed. activityId 'uuid:WSCOOR-SUN-2ade62a8-d476-474b-9b9d-a0c1fdeb069f' and msg 'uuid:41c6e179-af20-47da-bbfd-e73519000765'. Nested exception: 'HTTP transport error: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target' 
HTTP transport error: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target 
com.sun.xml.ws.client.ClientTransportException: HTTP transport error: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target 
    at com.sun.xml.ws.transport.http.client.HttpClientTransport.getOutput(HttpClientTransport.java:134) 

Comment pouvons-nous garder GlassFish d'essayer de communiquer entre eux via SSL? Lorsque nous faisons une application java régulière qui fonctionne comme un client pour le 2ème WS cela fonctionne bien, donc il semble que c'est quelque chose que glassfish fait.

Répondre

0

Ok, j'ai une réponse partielle à ma question. Donc, dans netbeans j'ai ouvert wsdl du serveur dans le projet client et supprimé toutes les informations de politique.

donc ceci:

<operation name="jobNote"> 
<ns216:PolicyReference xmlns:ns216="http://www.w3.org/ns/ws-policy" URI="#MetaPortBinding_jobNote_WSAT_Policy"></ns216:PolicyReference> 
<soap:operation soapAction=""></soap:operation> 

est devenu ceci:

Et il a bien fonctionné ... Est-ce que je peux faire pour dépouiller ces informations de politique automatiquement, je devine à travers la construction?