Unless I'm missing something you aren't using the right epr. As the error message is telling you :
<wsa:ReferenceParameters > xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <muse-wsa:ResourceId > xmlns:muse-wsa="http://ws.apache.org/muse/addressing">MuseResource-2</mu > se-wsa:ResourceId> > </wsa:ReferenceParameters> seems to be missing. epr.addParameter(WsaConstants.DEFAULT_RESOURCE_ID_QNAME, "MuseResource-" + x); should help. On Mon, Oct 5, 2009 at 11:27 AM, <[email protected]> wrote: > Hi all, > > I have built a client for my muse app with wsd2java and I have added the > flag -headers to be able to add headers to the call that I need to > extract with another component. > > The proxy has been generated w/out any problem and it has the new > parameter Element[] in all the methods. To test it I am putting null > just to make a normal call to the webapp and I am having this issue. > > This is the call I am doing: > > public void testCreate() throws SoapFault { > proxy = new WsSongStoreProxy(new > EndpointReference(URI.create(providerUrl)), null); > proxy = new WsSongStoreProxy (elemToEpr > (proxy.createOperation(null)), null); > proxy.setTrace(true); > } > > And this is the trace with the error I am getting. > > org.apache.muse.ws.addressing.soap.SoapFault: [ID = > 'DestinationUnreachable'] There is no resource available at the given > EPR: > > <wsa:EndpointReference xmlns:wsa="http://www.w3.org/2005/08/addressing"> > > <wsa:Address>http://127.0.0.1:8080/WsSongStore/services/WsSongStore</wsa > :Address> > </wsa:EndpointReference> > > The existing EPRs hosted by this endpoint are: > > <wsa:EndpointReference xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <wsa:ReferenceParameters > xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <muse-wsa:ResourceId > xmlns:muse-wsa="http://ws.apache.org/muse/addressing">MuseResource-2</mu > se-wsa:ResourceId> > </wsa:ReferenceParameters> > > <wsa:Address>http://127.0.0.1:8080/WsSongStore/services/WsSongStore</wsa > :Address> > </wsa:EndpointReference> > > <wsa:EndpointReference xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <wsa:ReferenceParameters > xmlns:wsa="http://www.w3.org/2005/08/addressing"> > <muse-wsa:ResourceId > xmlns:muse-wsa="http://ws.apache.org/muse/addressing">MuseResource-3</mu > se-wsa:ResourceId> > </wsa:ReferenceParameters> > > <wsa:Address>http://127.0.0.1:8080/WsSongStore/services/WsSongStore</wsa > :Address> > </wsa:EndpointReference> > at > org.apache.muse.core.AbstractResourceClient.invoke(AbstractResourceClien > t.java:298) > at > org.apache.muse.core.AbstractResourceClient.invoke(AbstractResourceClien > t.java:232) > at > test.proxy.WsSongStoreProxy.createOperation(WsSongStoreProxy.java:131) > at core.testHeaders.testCreate(testHeaders.java:26) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav > a:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor > Impl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at junit.framework.TestCase.runTest(TestCase.java:164) > at junit.framework.TestCase.runBare(TestCase.java:130) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:120) > at junit.framework.TestSuite.runTest(TestSuite.java:230) > at junit.framework.TestSuite.run(TestSuite.java:225) > at > org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUn > it3TestReference.java:130) > at > org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.ja > va:38) > at > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTe > stRunner.java:467) > at > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTe > stRunner.java:683) > at > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRun > ner.java:390) > at > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRu > nner.java:197) > > Thanks > > JuanLu >
