![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
| | Thread Tools | Display Modes |
| | #1 (permalink) |
| Guest | Remote event possible with WCF ? Hi, I'd like to know if i can have this type of behavior : I have a object "SeverMonitor" which has 2 events "EventA" and "EventB". When i create an instance of ServerMonitor it will periodically poll a database and raise EventA or EventB based on some data. I know how to do this. Now i'd like to make ServerMonitor an Single Remote Object and have client apps adding event handlers to EventA and EventB and when i raise EventA or EventB, all clients will be called. It looks like a duplex contrat but i don't want to have a server object for each client (PerSession) but a Single server object. Of course i could use something else as events like calling a OnWay method to register to an event (RegisterEventA) and my server object will keep a callback for each client... Anyone knows if it's possible to have this type of behavior ? Thanks Guillaume R. |
| | #2 (permalink) |
| Guest | RE: Remote event possible with WCF ? Well according to http://msdn.microsoft.com/winfx/defa...s/default.aspx "Windows Communication Foundation does not allow you to pass object references across service boundaries." So my thought is that even using the Session enabled (PerSession) services will not enable this kind of functionality. It will however keep a reference to one instance, so if that instance is doing some polling and the client runs off to do other work the client could in theory poll that instance for a change in the situation. Actually in that scenario you might want to consider the InstanceContextMode.Single ServiceBehavior ... What kind of client to you forsee needing this functionality ? (web, thick, other application) -Sean "Guillaume" wrote: > Hi, > I'd like to know if i can have this type of behavior : > > I have a object "SeverMonitor" which has 2 events "EventA" and "EventB". > When i create an instance of ServerMonitor it will periodically poll a > database and raise EventA or EventB based on some data. I know how to do this. > Now i'd like to make ServerMonitor an Single Remote Object and have client > apps adding event handlers to EventA and EventB and when i raise EventA or > EventB, all clients will be called. > It looks like a duplex contrat but i don't want to have a server object for > each client (PerSession) but a Single server object. > Of course i could use something else as events like calling a OnWay method > to register to an event (RegisterEventA) and my server object will keep a > callback for each client... > > Anyone knows if it's possible to have this type of behavior ? > > Thanks > > Guillaume R. |
| |
| |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Vista Remote Event Log viewer | mlai | Vista networking & sharing | 12 | 11-05-2007 11:24 PM |
| Vista Remote Event Log viewer | mlai | Vista performance & maintenance | 6 | 11-05-2007 09:53 AM |
| PowerShell Event Logs (read and write) (Local and Remote) | jeronimo | PowerShell | 1 | 09-21-2007 03:43 PM |
| How to Backup remote Event Log | Kingpinofdisks | PowerShell | 4 | 09-17-2007 03:41 PM |
| Querying a number of servers for a specific Event ID -Remote? | Kevini | PowerShell | 1 | 12-18-2006 03:37 PM |