[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [xmlblaster] get() PtP messages



Hi Oleg,

Oleg Orlov wrote:

-----Original Message----- From: owner-xmlblaster at server.xmlBlaster.org [mailto:owner-xmlblaster at server.xmlBlaster.org]On Behalf Of Michele Laghi


Hi Oleg,


Hello Michele!
Thanks for your response.


you can invoke before connecting
// setup the receiver client ...
receiver = glob.getXmlBlasterAccess();
// setup the caching for 10 messages
receiver.createSynchronousCache(10);
and then when you want to retreive the messages:
MsgUnit[] msg = receiver.getCached(key, qos);
The messages are retrived transparently by the client library and you
can invoke getCached synchroneously.


getCached() uses subscribe() behind the scenes. In my use case client need
to connect, receive ALL own messages and disconnect.
Is where any way to understand, what where is no more incoming messages?
Can XPATH query help me?

OK, if you connect and disconnect each time and have a callback server and the messages are PtP then you get them all already (for Pub/Sub it is also possible but you need to retreive the history entries).


If your client does not have a callback server then getting PtP messages synchroneously is not supported yet. It is one of the next features going to be implemented (currently receiving PtP needs a callback server).




Saluti
Michele


Regards, Oleg.


Cheers Michele