[omniORB] Newbee Design Question

Julien Chevalley Julien.Chevalley at Ripple-Systems.com
Fri Jul 9 17:53:00 BST 2004


Hi Gerd,

Which of event driven or polling based models is best depends on how
frequently the data changes.

If they changes are not very frequent, event driven is best.

If they are (e.g. many changes per second), polling will be best.

Polling is also best if reliability is a concern. With a purely event-driven
system, when you don't get any events you don't know if it is because
nothing is happening or because the server side process is dead.

You don't need to implement the observer pattern yourself. You can use the
OMG Event Service (broadcast) or Notification Service (publish / subscribe).
There are Omni implementations for both of these. They provide an "out of
the box" solution to all the problems you mention (clients that hang or
crash... etc): your servant simply pushes a message to the service. The
service then takes care of dispatching the message to the clients,
asynchronously.

Best regards,

Julien Chevalley

-----Original Message-----
From: Gerd Schmitt [mailto:extern.schmitt at kmweg.de]
Sent: Friday, 9 July 2004 4:23 PM
To: omniorb-list at omniorb-support.com
Subject: [omniORB] Newbee Design Question



Hi, OmniOrbers,

excuse me if that is a inapropriate place for this question.
If that's the case please point me to the proper one.


About 7 years ago I came in touch with Corba but didn't
do anything ever since. Now I'm considering to introduce
it to my recent project. I'd like to hear an experts
opinion if this seems reasonable or if I would be
better of doing it by simple network calls.

We have several GUIs that share common data, i.e.
a simulation state (which is shown on the GUI).
I consider to setup a server with a servant that
holds among other things this state.

Now, if  the user triggers a change I can easily forward
this call to the the servant, but how do the GUIs
recognize this state change?
Would it make sense to setup something like the
"Observer Pattern"? Or would you just poll the servant
every second to detect the change (which in my mind dosn't
seem very nice).

I assume setting up a callback mechanism would require
servants in each GUI application which will be called by the
state servant. To do so they would need to register themselfs
first. But what happens if one of the GUIs hangs or crashes?
Would this lock up the state server? If not, is the server
able to detect the crash of the remote GUI. I don't want
to restart every application in this case but just the crashed one.

Are there any other issues I haven't thought of?


Any comments would be appriciated.


Gerd Schmitt
extern.schmitt at kmweg.de


_______________________________________________
omniORB-list mailing list
omniORB-list at omniorb-support.com
http://www.omniorb-support.com/mailman/listinfo/omniorb-list



More information about the omniORB-list mailing list