I think I solved this myself. I extended SimpleNotificationProducer and
overwrote 

public void publish(QName topicName, Element[] content)

to get the property collection, find in the read listeners for "content" and
then execute the readRequested on each of them. This works very nice and the
output XML (SOAP) is similar to what is obtained via
getResourcePropertyAndMetrics. Once the new content is obtained I pass it to
super.publish().

The only problem with this solution is that a publish is not exactly a read,
semantically.


Bogdan Solomon wrote:
> 
> This one has me blocked at the moment.
> 
> I have made a capability that I know can send information as a metric. I
> have then modified this capability and added notifications to it, and I
> tried sending the object as a notification. This also works now. So what I
> would need to do next, is send the metric information attached to my
> "object" through the notification. 
> 
> Is there anyway to do this, without having to construct the XML by hand?
> Since I am publishing the notification, it does not seem to go through the
> decoration layer that adds the metric metadata.
> 

-- 
View this message in context: 
http://www.nabble.com/WSDM-Metric-via-Notification-tf3909596.html#a11105390
Sent from the Muse User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to