You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pubscribe-user@ws.apache.org by Leonardo Lemes <le...@gmail.com> on 2005/09/27 19:47:37 UTC

Pubscribe

Hi all, I am new to Pubscribe and I have just installed it sucessfully
(Pubscribe 1.0). Now I am executing some requests of the filesystem example
and I would like to ask you:
 1) Which is the request I should send to the service to obtain all the
available properties to which I can do a subscription (from the
FileSystemPortType)?
I have tried the GetResourceProperty_Topic.soap request. Is this the rigth
and best choice?
 2) When I receive the response message above, it is printed on the screen.
Ok. But how could I catch the response to run a parser over it and so seed
an management application with the informarion I just took from the
response?
 3) I am trying to destroy a subscription also, but it is not working. What
I have done so far here is: I do a subscription, for example, with the
Subscribe_updateMountPointProp.soap request, copy the "uuid" from the
response, and paste this "id" in the "Destroy_Subscription.soap" this way
<sub:ResourceIdentifier mustUnderstand="1"> here I paste the uuid
</sub:ResourceIdentifier>. But when I send this request, it does not work. I
receive the following message:
-----

[echo] ========================== RESPONSE ============================
[soapClient] SOAP request failed with HTTP status: 500 Internal Server Error
[soapClient] <?xml version=" 1.0" encoding="UTF-8"?><soapenv:Envelope
xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envel
ope/" xmlns:xsd=" http://www.w3.org/2001/XMLSchema" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance">
[soapClient] <soapenv:Body>
[soapClient] <soapenv:Fault>
[soapClient] <faultcode>soapenv:Client</faultcode>
*[soapClient] <faultstring>The expected resource identifier reference
parameter named { http://ws.apache.org/resource/ex
ample/filesystem}ResourceIdentifier was not found in the SOAP
header.</faultstring>
*[soapClient] <detail/>
[soapClient] </soapenv:Fault>
[soapClient] </soapenv:Body>
[soapClient] </soapenv:Envelope>
 BUILD SUCCESSFUL
Total time: 1 second
-------
 What I am doing wrong? Could you help me?
 Thanks a lot
  Leonardo Lemes

Re: Pubscribe

Posted by Leonardo Lemes <le...@gmail.com>.
Hi Sal,
just one more thing:

On 9/28/05, Sal Campana <sc...@apache.org> wrote:
>
> 1) Yes. GetResourceProperty on the Topic property returns all Topics
> for which you can subscribe...This is the intent of this resource
> property. It's the best choice.


ok

2) Take a look at the class our scripts reference for sending requests.
> You could use the class and capture the input to
> XmlBean.Factory.parse(...) and get an object which you could then work
> with. You are basically asking about a client, and there are plenty of
> ways of doing it I've only mentioned one.


Here I didn't get it. Which class? Could you please clarify just a little
more?
Has someone already implemented some kind of client? Do you intend to
distribute it in the nexts versions?

3) I suspect that you've sent the destroy request to the wrong
> endpont. The response to a subscribe returns an EPR which not only
> gives you the UUID of your subscription, but also it provides the TO
> filed which tells you where to send requests. In order to interact with
> your subscription you will need to make sure our scripts' url field is
> set to the returned TO location (which is actually the
> SubscriptionManager service)


Ok. I was sending it to the FileSystem and not to the SubscriptionManager.
Now is everything working fine here.
Thank you, Leonardo Lemes

 Leonardo Lemes wrote:
>
> >Hi all, I am new to Pubscribe and I have just installed it sucessfully
> >(Pubscribe 1.0). Now I am executing some requests of the filesystem
> example
> >and I would like to ask you:
> > 1) Which is the request I should send to the service to obtain all the
> >available properties to which I can do a subscription (from the
> >FileSystemPortType)?
> >I have tried the GetResourceProperty_Topic.soap request. Is this the
> rigth
> >and best choice?
> > 2) When I receive the response message above, it is printed on the
> screen.
> >Ok. But how could I catch the response to run a parser over it and so
> seed
> >an management application with the informarion I just took from the
> >response?
> > 3) I am trying to destroy a subscription also, but it is not working.
> What
> >I have done so far here is: I do a subscription, for example, with the
> >Subscribe_updateMountPointProp.soap request, copy the "uuid" from the
> >response, and paste this "id" in the "Destroy_Subscription.soap" this way
> ><sub:ResourceIdentifier mustUnderstand="1"> here I paste the uuid
> ></sub:ResourceIdentifier>. But when I send this request, it does not
> work. I
> >receive the following message:
> >-----
> >
> >[echo] ========================== RESPONSE ============================
> >[soapClient] SOAP request failed with HTTP status: 500 Internal Server
> Error
> >[soapClient] <?xml version=" 1.0" encoding="UTF-8"?><soapenv:Envelope
> >xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envel
> >ope/" xmlns:xsd=" http://www.w3.org/2001/XMLSchema" xmlns:xsi="
> >http://www.w3.org/2001/XMLSchema-instance">
> >[soapClient] <soapenv:Body>
> >[soapClient] <soapenv:Fault>
> >[soapClient] <faultcode>soapenv:Client</faultcode>
> >*[soapClient] <faultstring>The expected resource identifier reference
> >parameter named { http://ws.apache.org/resource/ex
> >ample/filesystem}ResourceIdentifier was not found in the SOAP
> >header.</faultstring>
> >*[soapClient] <detail/>
> >[soapClient] </soapenv:Fault>
> >[soapClient] </soapenv:Body>
> >[soapClient] </soapenv:Envelope>
> > BUILD SUCCESSFUL
> >Total time: 1 second
> >-------
> > What I am doing wrong? Could you help me?
> > Thanks a lot
> > Leonardo Lemes
> >
> >
> >
>
>

Re: Pubscribe

Posted by Sal Campana <sc...@apache.org>.
1) Yes.  GetResourceProperty on the Topic property returns all Topics 
for which you can subscribe...This is the intent of this resource 
property.  It's the best choice.

2) Take a look at the class our scripts reference for sending requests.  
You could use the class and capture the input to 
XmlBean.Factory.parse(...) and get an object which you could then work 
with.  You are basically asking about a client, and there are plenty of 
ways of doing it I've only mentioned one.

3)  I suspect that you've sent the destroy request to the wrong 
endpont.  The response to a subscribe returns an EPR which not only 
gives you the UUID of your subscription, but also it provides the TO 
filed which tells you where to send requests.  In order to interact with 
your subscription you will need to make sure our scripts' url field is 
set to the returned TO location (which is actually the 
SubscriptionManager service)


Leonardo Lemes wrote:

>Hi all, I am new to Pubscribe and I have just installed it sucessfully
>(Pubscribe 1.0). Now I am executing some requests of the filesystem example
>and I would like to ask you:
> 1) Which is the request I should send to the service to obtain all the
>available properties to which I can do a subscription (from the
>FileSystemPortType)?
>I have tried the GetResourceProperty_Topic.soap request. Is this the rigth
>and best choice?
> 2) When I receive the response message above, it is printed on the screen.
>Ok. But how could I catch the response to run a parser over it and so seed
>an management application with the informarion I just took from the
>response?
> 3) I am trying to destroy a subscription also, but it is not working. What
>I have done so far here is: I do a subscription, for example, with the
>Subscribe_updateMountPointProp.soap request, copy the "uuid" from the
>response, and paste this "id" in the "Destroy_Subscription.soap" this way
><sub:ResourceIdentifier mustUnderstand="1"> here I paste the uuid
></sub:ResourceIdentifier>. But when I send this request, it does not work. I
>receive the following message:
>-----
>
>[echo] ========================== RESPONSE ============================
>[soapClient] SOAP request failed with HTTP status: 500 Internal Server Error
>[soapClient] <?xml version=" 1.0" encoding="UTF-8"?><soapenv:Envelope
>xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envel
>ope/" xmlns:xsd=" http://www.w3.org/2001/XMLSchema" xmlns:xsi="
>http://www.w3.org/2001/XMLSchema-instance">
>[soapClient] <soapenv:Body>
>[soapClient] <soapenv:Fault>
>[soapClient] <faultcode>soapenv:Client</faultcode>
>*[soapClient] <faultstring>The expected resource identifier reference
>parameter named { http://ws.apache.org/resource/ex
>ample/filesystem}ResourceIdentifier was not found in the SOAP
>header.</faultstring>
>*[soapClient] <detail/>
>[soapClient] </soapenv:Fault>
>[soapClient] </soapenv:Body>
>[soapClient] </soapenv:Envelope>
> BUILD SUCCESSFUL
>Total time: 1 second
>-------
> What I am doing wrong? Could you help me?
> Thanks a lot
>  Leonardo Lemes
>
>  
>