Hi James,
all notification stuff is implemented the way ms exchange handles notifications. So 
you can have a look at their pages how this parameters can be used (especially the 
depth/methods combinations are a little bit confusing).
The notification delay is used to collect events for a longer term and notify the 
client later. So if many events occur, it might be a tuning option to set the 
notification delay to a value greater then zero.
I've added some Slide-specific extensions that could be a choice for implementing 
clustering: You can listen to a method with infinite depth so that you can for example 
listen on the root collection with depth infinity to get all events of a special type. 
If you get notified, the event information map (a Slide extension as well) contains 
the uri of the changed resource.
1) First solution to build clustering on top of notifications (simpler one)
So you can register three subscribers (one on "Update", one on "Update/newmember" and 
one on "Delete") with infinite depth and unlimited subscription lifetime (or you have 
to renew the subscription periodically).
Every time one of these subscribers get notified, you have to lookup the "uri" entry 
in the information map and remove this entry from the stores cache.
2) Second (more complex but more efficient) solution
You have to extend the EventCollectionFilter-class and add a new method that gives you 
all changes uris.
This static method would return a UrisChangedEvent (new class to be written) that 
contains all changed uris in the information map. This method should filter out double 
events (have a look at the other methods in this class).
After that you have to extend the NotificationTrigger-class to enable listening on 
UrisChangedEvents. This might be a little bit tricky and I can do it for you if you 
like as I'd like to enable a generic listening for all types of events...
Now you should be able to register a single Subscriber that gets notified with all 
changed uris at once.
 
Good luck ;-)
 
Daniel

________________________________

Von: James Mason [mailto:[EMAIL PROTECTED]
Gesendet: Fr 06.08.2004 18:32
An: Slide Developers Mailing List
Betreff: Re: Need documentation for NotificationListener



Awesome, thanks.

Question about the notification type. What difference does it make :)? I
need to get notifications any time something changes
(add/change/delete). I've create an event that generates this
information, but I see no way to indicate that the client is interested
in this event. Is this what what "method" is for, or is it something
else? Do I just need to create four subscriptions, one for each method,
and not bother with the event type I created?

-James

Stefan L�tzkendorf wrote:

> James,
>
> @param method the "notification type", determines for what events do you
>    want do subscribe. one of  "Update", "Update/newmember", "Delete",
> "Move"
>    (I dont know whether we are support all)
> @param uri the resource for that you subscribe
> @param depth the depth of the collection tree that you want to observe
> @param lifetime the duration for that you want to observe (in seconds)
> @param notificationDelay the time the server waits before it sends a notify
>    message to the host provided in the constructor  (in seconds)
> @param listener the Listner that is called on incomming fotifications
> @param credentials credentials for authntication on the server observed
>
> @seealso WebdavResource#subscribeMethod
> @seealso
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/e2k3/e2k3/_webdav_subscribe.asp
>
>
> Regads, Stefan
>
> James Mason wrote:
>
>> Daniel,
>> Can you provide any documentation for
>> NotificationListener.subscribe()? Specifically what the method
>> parameter is and what the valid values are, as well as the effect of
>> notificationDelay.
>>
>> What units the time parameters are in would be useful too :).
>>
>> Thanks,
>> James
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>


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




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

Reply via email to