XMPP BC as consumer : Content not allowed in prolog
I have a XMPP BC as consumer that receives external XMPP messages. This SU consumes another XMPP BC provider. I try to send a message to XMPP BC consumer to get the echo from XMPP BC provider.
Ok, it is a stupid use case but it is useful to test XMPP and petas !
The jabber server is ejabberd and the jabber client is Exodus.
When I type "coucou" on Exodus chat and press Enter, I have the following error message on petals console :
[petals.container.components.petals-bc-xmpp]-INFO 2009-01-12 10:41:26,343 Message received from:cpipo@po62403/PO62403
[petals.container.components.petals-bc-xmpp]-INFO 2009-01-12 10:41:26,343 Message : coucou
[petals.container.components.petals-bc-xmpp]-INFO 2009-01-12 10:41:26,343 Sending message to cpipo@PO62403/PO62403 [Fatal Error] :1:1: Content is not allowed in prolog.
[petals.container.components.petals-bc-xmpp]-INFO 2009-01-12 10:41:26,343 Message received
On the contrary, note that the XMPP BC as a provider works nicely when I send to it a message via petals-sample-client BC.
I think that the problem is not a WSDL one but a XML marshalling one...
May I ask you why are you using the XMPP component? Just for test or for a real need? The XMPP component is quite old (over than 1 year), is just a prototype and is not in the PEtALS community top priority list.
What I can suggest you is to look at the source code, to try to debug it (the petals developer guide explains how to do it with eclipse) and send us patch if needed.
XMPP is just used to demonstrate with fun to novices the interoperability of the ESB. It is not an operationnal feature for us.
I began to have a look on source and that's why I asked an HTTP access to sources !
Thanks for your quick answer, I am going to investigate on that problem of marshalling...
There was a demo we set up with XMPP, webservices and REST services but it is not up to date. You can have a look to the sources in trunk/petals-demos/petals-wsportal and maybe update it.
If I remember, this demo allows you query services from your jabber client, for example, typing "!weather Toulouse" returns the actual Toulouse weather (for now it is quite sunny but -4°C
), or "!stock GOOG" returns the google stock value.
This is a mere xpath problem, not a PEtALS problem
You don’t have to use prefix like this.
Please refer to standard Xpath documentation that you can find on internet
You can try
/*[namespace-uri()='http://blabla' and local-name()='scenario']
De : cpipo [mailto:[hidden email]] Envoyé : mercredi 14 janvier 2009 13:28 À :[hidden email] Objet : Re: XMPP BC as consumer : Content not allowed in prolog
I had to install a pojo SU to print the XML message content of the Exchange. The content was :
And, what I must write in the router test is name(/*)='ns4:scenario' !!!
Yes, it works, but how can I guess, without printing the NMR message, which prefix Petals associates to my namespace ?!