Hi Jan,
The initializeCompleted always only works on a singel resource. I assume as
you couldn't get the reference from the external soap request that the producer
is in a different resource. To lookup other resources use
getResource().getResourceManager().getResource(new EndpointReference(
new
URI(museIsoLayer.getRouter().getEnvironment().getDefaultURI()+resourceName)));
where resourceName is the <context-path>adapter</context-path>.
This will also work for non muse.xml resources.
cheers,
Chris
-----Original Message-----
From: Jan Torben Heuer [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 08, 2008 1:58 PM
To: [email protected]
Subject: Lookup other capabilites
Hi,
I need a reference to the NotificationProducer instance in my Resource.
Therefore I wrote this method:
private NotificationProducer getNotificationProducer() throws SoapFault {
NotificationProducer wsn = (NotificationProducer)
getResource().getCapability(WsnConstants.PRODUCER_URI);
return wsn;
}
But no matter when I call it, it is always to early: In the logs I can see that
the NotificationProducer is initialized afterwards. I tried "initialize"
and "initializeCompleted" and I even tried the actual method which is called on
external soap requests.
So my question is:
(1) Is it only a problem of my "InlineEnvironment" JUnit loader?
(2) Is there a method that should be calles after all Resources have been
initialized (I mean those that have this router-entries defined)?
Thanks,
Jan
--
Jan Torben Heuer Institute for Geoinformatics
[EMAIL PROTECTED] Robert-Koch-Strasse 26-28
+49 251 83-31960 48151 Münster, Germany
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]