You are viewing a plain text version of this content. The canonical link for it is here.
Posted to muse-dev@ws.apache.org by SARA1232007 <cy...@foxmail.com> on 2009/04/22 05:04:43 UTC

about SimpleWsResource and SimpleResource

Hi,

I modify the simple example to add a new property.
For SimpleResource definition in muse.xml, I alter the java-resource-class
definition as following:

       
<java-id-factory-class>org.apache.muse.core.routing.CounterResourceIdFactory</java-id-factory-class>
       
<java-resource-class>org.apache.muse.ws.resource.impl.SimpleWsResource</java-resource-class>

I run the client which extends WsResourceClient class to invoke
firstOperation, and I get "There is no resource available at the given EPR"
exception from client.The trace information from client as following:

[CLIENT TRACE] SOAP envelope contents (outgoing):

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">
    <soap:Header>
        <wsa:To
xmlns:wsa="http://www.w3.org/2005/08/addressing">http://127.0.0.1:8086/simple/services/SimpleResource</wsa:To>
        <wsa:Action
xmlns:wsa="http://www.w3.org/2005/08/addressing">http://ws.apache.org/muse/test/simple/first/FirstOperation</wsa:Action>
        <wsa:MessageID
xmlns:wsa="http://www.w3.org/2005/08/addressing">uuid:2ba3f950-9ab8-8759-1749-57cbe781cd1b</wsa:MessageID>
        <wsa:From xmlns:wsa="http://www.w3.org/2005/08/addressing">
           
<wsa:Address>http://www.w3.org/2005/08/addressing/role/anonymous</wsa:Address>
        </wsa:From>
        <muse-wsa:ResourceId
            xmlns:muse-wsa="http://ws.apache.org/muse/addressing"
            xmlns:wsa="http://www.w3.org/2005/08/addressing"
wsa:IsReferenceParameter="true">MuseResource-1</muse-wsa:ResourceId>
    </soap:Header>
    <soap:Body>
        <FirstOperation
xmlns="http://ws.apache.org/muse/test/simple/first">Hello,
World!</FirstOperation>
    </soap:Body>
</soap:Envelope>

[CLIENT TRACE] SOAP envelope contents (incoming):

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">
    <soap:Header>
        <wsa:To
xmlns:wsa="http://www.w3.org/2005/08/addressing">http://www.w3.org/2005/08/addressing/role/anonymous</wsa:To>
        <wsa:Action
xmlns:wsa="http://www.w3.org/2005/08/addressing">http://www.w3.org/2005/08/addressing/fault</wsa:Action>
        <wsa:MessageID
xmlns:wsa="http://www.w3.org/2005/08/addressing">uuid:160b9c61-df5e-be27-e3b0-c5f8ba9a2f88</wsa:MessageID>
        <wsa:RelatesTo RelationshipType="wsa:Reply"
xmlns:wsa="http://www.w3.org/2005/08/addressing">uuid:2ba3f950-9ab8-8759-1749-57cbe781cd1b</wsa:RelatesTo>
        <wsa:From xmlns:wsa="http://www.w3.org/2005/08/addressing">
           
<wsa:Address>http://127.0.0.1:8086/simple/services/SimpleResource</wsa:Address>
            <wsa:ReferenceParameters>
                <muse-wsa:ResourceId wsa:IsReferenceParameter="true"
                    xmlns:muse-wsa="http://ws.apache.org/muse/addressing"
xmlns:wsa="http://www.w3.org/2005/08/addressing">MuseResource-1</muse-wsa:ResourceId>
            </wsa:ReferenceParameters>
        </wsa:From>
    </soap:Header>
    <soap:Body>
        <soap:Fault>
            <soap:Code>
                <soap:Value>soap:Sender</soap:Value>
                <soap:Subcode
xmlns:wsa="http://www.w3.org/2005/08/addressing">
                    <soap:Value>wsa:DestinationUnreachable</soap:Value>
                </soap:Subcode>
            </soap:Code>
            <soap:Reason>
                <soap:Text>[ID = 'DestinationUnreachable'] There is no
resource available at the given EPR: 

&lt;wsa:EndpointReference
xmlns:wsa="http://www.w3.org/2005/08/addressing"&gt;
   
&lt;wsa:Address&gt;http://127.0.0.1:8086/simple/services/SimpleResource&lt;/wsa:Address&gt;
    &lt;wsa:ReferenceParameters&gt;
        &lt;muse-wsa:ResourceId
            xmlns:muse-wsa="http://ws.apache.org/muse/addressing"
            wsa:IsReferenceParameter="true"
xmlns:wsa="http://www.w3.org/2005/08/addressing"&gt;MuseResource-1&lt;/muse-wsa:ResourceId&gt;
    &lt;/wsa:ReferenceParameters&gt;
&lt;/wsa:EndpointReference&gt;

The existing EPRs hosted by this endpoint are: 

&lt;wsa:EndpointReference
xmlns:wsa="http://www.w3.org/2005/08/addressing"&gt;
    &lt;wsa:ReferenceParameters
xmlns:wsa="http://www.w3.org/2005/08/addressing"/&gt;
   
&lt;wsa:Address&gt;http://127.0.0.1:8086/simple/services/SimpleResource&lt;/wsa:Address&gt;
&lt;/wsa:EndpointReference&gt;
</soap:Text>
            </soap:Reason>
        </soap:Fault>
    </soap:Body>
</soap:Envelope>

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:8086/simple/services/SimpleResource</wsa:Address>
    <wsa:ReferenceParameters>
        <muse-wsa:ResourceId
            xmlns:muse-wsa="http://ws.apache.org/muse/addressing"
            wsa:IsReferenceParameter="true"
xmlns:wsa="http://www.w3.org/2005/08/addressing">MuseResource-1</muse-wsa:ResourceId>
    </wsa:ReferenceParameters>
</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"/>
   
<wsa:Address>http://127.0.0.1:8086/simple/services/SimpleResource</wsa:Address>
</wsa:EndpointReference>
	at
org.apache.muse.core.AbstractResourceClient.invoke(AbstractResourceClient.java:298)
	at
org.apache.muse.core.AbstractResourceClient.invoke(AbstractResourceClient.java:254)
	at
org.apache.muse.test.simple.SimpleResourceClient.firstOperation(SimpleResourceClient.java:67)
	at
org.apache.muse.test.simple.SimpleTestClient.main(SimpleTestClient.java:105)

Can anyone tell me what is wrong?

Thanks!

Sara

-- 
View this message in context: http://www.nabble.com/about-SimpleWsResource-and-SimpleResource-tp23168871p23168871.html
Sent from the Muse - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org


Re: about SimpleWsResource and SimpleResource

Posted by SARA1232007 <cy...@foxmail.com>.


Chris Twiner wrote:
> 
> 
> Hi, sorry I should have been much clearer, In the email you copied and
> pasted the xml content so we got &lt; instead of <, this makes it
> difficult to look at for each member of the list.  Instead if you
> could show the eprs themselves (so we see < not &lt;) that makes it
> easier for everyone on the list.
> itional commands, e-mail: muse-dev-help@ws.apache.org
> 
> 

Hi Chris,

Sorry I still don't know what you mean. English is not my native language.
Could you give an example of the msg with the required format?

Thank you very much for your patience!

Cheers,
Sara 

-- 
View this message in context: http://www.nabble.com/about-SimpleWsResource-and-SimpleResource-tp23168871p23255990.html
Sent from the Muse - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org


Re: about SimpleWsResource and SimpleResource

Posted by Chris Twiner <ch...@gmail.com>.
On Thu, Apr 23, 2009 at 3:23 AM, SARA1232007 <cy...@foxmail.com> wrote:
>
>
>
> In future posts to the mailing list can you please copy and paste the
> actual text of available EPRS (not just the escaped xml), its
> particularly difficult to read.
>
>
> Hi Chris,
>
> Thank you for your quick response. But I don't understand what you mean by
> "actual text of available EPRS , not just the escaped xml".  Those
> information I post is gotten from Muse.
> --

Hi, sorry I should have been much clearer, In the email you copied and
pasted the xml content so we got &lt; instead of <, this makes it
difficult to look at for each member of the list.  Instead if you
could show the eprs themselves (so we see < not &lt;) that makes it
easier for everyone on the list.

---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org


Re: about SimpleWsResource and SimpleResource

Posted by SARA1232007 <cy...@foxmail.com>.


In future posts to the mailing list can you please copy and paste the
actual text of available EPRS (not just the escaped xml), its
particularly difficult to read.


Hi Chris,

Thank you for your quick response. But I don't understand what you mean by
"actual text of available EPRS , not just the escaped xml".  Those
information I post is gotten from Muse.
-- 
View this message in context: http://www.nabble.com/about-SimpleWsResource-and-SimpleResource-tp23168871p23185432.html
Sent from the Muse - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org


Re: about SimpleWsResource and SimpleResource

Posted by Chris Twiner <ch...@gmail.com>.
On Wed, Apr 22, 2009 at 5:04 AM, SARA1232007 <cy...@foxmail.com> wrote:
>
> Hi,
>
> I modify the simple example to add a new property.
> For SimpleResource definition in muse.xml, I alter the java-resource-class
> definition as following:
>
>
> <java-id-factory-class>org.apache.muse.core.routing.CounterResourceIdFactory</java-id-factory-class>
>
> <java-resource-class>org.apache.muse.ws.resource.impl.SimpleWsResource</java-resource-class>
>
> I run the client which extends WsResourceClient class to invoke
> firstOperation, and I get "There is no resource available at the given EPR"
> exception from client.The trace information from client as following:
>
> [CLIENT TRACE] SOAP envelope contents (outgoing):
>
> <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">
>    <soap:Header>
>        <wsa:To
> xmlns:wsa="http://www.w3.org/2005/08/addressing">http://127.0.0.1:8086/simple/services/SimpleResource</wsa:To>
>        <wsa:Action
> xmlns:wsa="http://www.w3.org/2005/08/addressing">http://ws.apache.org/muse/test/simple/first/FirstOperation</wsa:Action>
>        <wsa:MessageID
> xmlns:wsa="http://www.w3.org/2005/08/addressing">uuid:2ba3f950-9ab8-8759-1749-57cbe781cd1b</wsa:MessageID>
>        <wsa:From xmlns:wsa="http://www.w3.org/2005/08/addressing">
>
> <wsa:Address>http://www.w3.org/2005/08/addressing/role/anonymous</wsa:Address>
>        </wsa:From>
>        <muse-wsa:ResourceId
>            xmlns:muse-wsa="http://ws.apache.org/muse/addressing"
>            xmlns:wsa="http://www.w3.org/2005/08/addressing"
> wsa:IsReferenceParameter="true">MuseResource-1</muse-wsa:ResourceId>

Do you have a resource with this resourceid? According to the result
from Muse you don't.  Depending on the routingpersistence settings you
should have a file somewhere under SimpleResource that has this
reference parameter.

In future posts to the mailing list can you please copy and paste the
actual text of available EPRS (not just the escaped xml), its
particularly difficult to read.

---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org