[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

le_khan

6/29/2004 1:36:00 PM

Hi NG

In one of his numerous articles, Ingo Rammer advise the .net remoting
developpers not to use events for networked application.
I'm a newbie in programming and actually, I do use events in my .net
remoting application...since I haven't yet found other ways to do what
I want.

Here is the actual scenario :
When changes are made on the remote object (Singleton SAO) by a
client, this client send a notification event to the server
So that the server will make some computations and notify all the
clients of the changes by events
The clients will thus refresh the display

How could I implement this without using events?

thank you
k
4 Answers

Allen Anderson

6/29/2004 1:53:00 PM

0

which article are you refering to on Ingo''s site? If memory serves me
correctly his position wasn''t specifically against events as much as
it was against anything but singlecall objects (which you can''t run
events from for obvious reasons).

Personally I find nothing wrong with using events (although you take
the performance hit by losing the ability to cluster as well) as long
as you are careful to call the events manually instead relying on the
event mechanism (which can hang for many seconds).

Allen Anderson
http://www.glacialcomp...
mailto: allen@put my website base here.com

On 29 Jun 2004 06:35:56 -0700, le_khan@yahoo.fr (k a) wrote:

>Hi NG
>
>In one of his numerous articles, Ingo Rammer advise the .net remoting
>developpers not to use events for networked application.
>I''m a newbie in programming and actually, I do use events in my .net
>remoting application...since I haven''t yet found other ways to do what
>I want.
>
>Here is the actual scenario :
>When changes are made on the remote object (Singleton SAO) by a
>client, this client send a notification event to the server
>So that the server will make some computations and notify all the
>clients of the changes by events
>The clients will thus refresh the display
>
>How could I implement this without using events?
>
>thank you
>k

Sunny

6/29/2004 2:17:00 PM

0

Hi,

the idea is to rethink your solution and see if you can avoid events. If
you can not, the ok, go with it. In your situation you have 2 options:

1. events - this is easiest and natural way. Just be sure to implement
some kind of your own broadcasting machine, because you can have
problems with native events support if some of the clients fails. Then
all other clients will not receive the event as well. You cant read this
article for ideas:
http://www.genuinechannels.com/Content.aspx?id=27&...

2. Create a separate thread at the client and at regular intervals pull
from the server the new state. If you change the state of the server
really often, then this will not create a big overload. But this is
unreasonable if you lets say change server state every 1/2 hour, but
pull for new state every 30 secs.

Sunny


In article <8f1b5e2a.0406290535.cef1bc6@posting.google.com>,
le_khan@yahoo.fr says...
> Hi NG
>
> In one of his numerous articles, Ingo Rammer advise the .net remoting
> developpers not to use events for networked application.
> I''m a newbie in programming and actually, I do use events in my .net
> remoting application...since I haven''t yet found other ways to do what
> I want.
>
> Here is the actual scenario :
> When changes are made on the remote object (Singleton SAO) by a
> client, this client send a notification event to the server
> So that the server will make some computations and notify all the
> clients of the changes by events
> The clients will thus refresh the display
>
> How could I implement this without using events?
>
> thank you
> k
>

k a

6/29/2004 3:33:00 PM

0

Thanks for your answers guys!

Using events is for sure the easiest way to do this!

Considering Ingo''s recommandations
(http://www.thinktecture.com/Resources/RemotingFAQ/RemotingUse...
), I was wondering whether it is proper to use events for this purpose.
Now, I''m a bit more confident :)

But, I''ll try the threading solution too.

ka


*** Sent via Devdex http://www.... ***
Don''t just participate in USENET...get rewarded for it!

Allen Anderson

7/6/2004 3:14:00 AM

0

np, glad to help.

On Tue, 29 Jun 2004 08:33:06 -0700, k a <le_khan@yahoo.fr> wrote:

>Thanks for your answers guys!
>
>Using events is for sure the easiest way to do this!
>
>Considering Ingo''s recommandations
>(http://www.thinktecture.com/Resources/RemotingFAQ/RemotingUse...
>), I was wondering whether it is proper to use events for this purpose.
>Now, I''m a bit more confident :)
>
>But, I''ll try the threading solution too.
>
>ka
>
>
>*** Sent via Devdex http://www.... ***
>Don''t just participate in USENET...get rewarded for it!