[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Getting notifications of subscriptions and logins...
James & Sue Ann Birchfield wrote:
>
First an important note:
We are reorganizing our package structure in the next
week. So be prepared to do some code replacement
with the next xmlBlaster release!
> Got a quick question....
>
> I know transaction support isn't available, but I am trying to register
> interest in subscriptions and clients logging in.
>
> I am implementing both SubscriptionListener and
> ClientListener and implementing the methods.
> I am registering interest like this:
>
> ---snippet---
> xmlBlaster = corbaConnection.login(ME, passwd, qos);
>
> AuthServerImpl authImpl = new AuthServerImpl(corbaConnection.getOrb());
--- This is CORBA access
> Authenticate auth = Authenticate.getInstance(authImpl);
> auth.addClientListener(this);
> RequestBroker.getInstance(auth).addSubscriptionListener(this);
--- Here you instantiate a local xmlBlaster in the client
> ---end snippet---
OOps, i believe you are mixing up the CORBA access and the
native access.
Only the CORBA access is implemented, the native access
interface will be specified hopefully in the next release.
(after package reorganization).
Usually you should only access xmlBlaster through the CORBA interface
Getting a login notification through CORBA is not yet implemented.
>
> The above doesn't seem to work. Am I missing something?
>
> Is there a way to also get the identity(or reference) to the author of
> a published message?
Yes, the login name of the publisher is delivered in the QOS,
for example:
<qos>
<sender> <!-- The publisher login name of this message -->
Phillipe
</sender>
</qos>
You don't need to parse this by yourself, the convenience class
org/xmlBlaster/client/UpdateQoS.java
has an access method sender() to retrieve it.
>
> Thanks for any help!
>
> BTW, I am loving it more and more the more I play.
> I was pasing serialized objects around today....sweet!!!!!
>
> =====================================
> James Birchfield
> Chief Technology Officer
> jmbirchfield at proteus-technologies.com
> http://www.proteus-technologies.com
> =====================================
--
Marcel Ruff
ruff at swand.lake.de
http://www.lake.de/home/lake/swand/
http://www.xmlBlaster.org