Re: Events between machines
From: Magne Ryholt (magne.ryholt_at_bluezone.no)
Date: 12/18/04
- Next message: todd.mancini_at_gmail.com: "Re: Design Question on using Remoting"
- Previous message: todd.mancini_at_gmail.com: "Re: Can I create a remote object without a DLL on the client?"
- In reply to: Ingo Rammer: "Re: Events between machines"
- Next in thread: Ingo Rammer: "Re: Events between machines"
- Reply: Ingo Rammer: "Re: Events between machines"
- Messages sorted by: [ date ] [ thread ]
Date: Sat, 18 Dec 2004 18:39:35 +0100
Hi Ingo,
Thanks a lot for your very informative answer.
I had no idea that it is possible to send to private queue in other
machines, in an environment without domain controller, but it works just
fine.
Do you think it will give best performance to deliver the actual data
directly in the message sent to the queues ?
(as opposed to get it as return value by a method call to the remote object)
Do you know any url's to some benchmarking of performance between the
different techniques ?
My need could be several (say max 5) messages per. second, each message
containing an equivalent of an array of say 500 simple type 32 bits data
(float, int etc).
"Ingo Rammer" <ingorammer@online.nospam> wrote in message
news:%23GrXsqQ5EHA.3380@TK2MSFTNGP09.phx.gbl...
> Hi Magne,
>
> The problem with UDP is that it is generally not reliable. Even if no
> fragmentation occurs, you might still loose some events. (Or you might
> even loose a lot of events, if you are for example running on a WLAN.)
> This doesn't necessarily mean that UDP is bad ... this behavior is
> perfectly ok for a lot of applications. One just as to design the app in a
> way that it would also work if no single event would ever reach the
> clients. [as a possible but unlikely edge case]
>
> If you need reliable delivery of events, I'd suggest to go for MSMQ
> instead. In this case, you can create one client-side queue on each client
> machine (as a private queue ... it doesn't need to be in the Active
> Directory.)
>
> Of course you need to install MSMQ on your client's machines first as it
> is an optinal component of Windows.
>
> The server can then use a feature of MSMQ 3.0 (if you run on Windows XP or
> Windows Server 2003) which allows you to send a message to multiple
> destination queues at the same time without relying on IP multicasting.
> You can simply specify more then one destination by separating them with
> "," (comma).
>
> A valid path name is for example
> "FormatName:direct=os:client01\private$\testqueue,os:client01\private$\testqueue"
>
> I've attached the source code for a small client and a small server to
> this post. (If you need additional delivery guarantees, you can enable
> durability of messages.)
>
> Please note: Before using this sample in production environments, you
> should decide on a time-to-live for every message. Otherwise some outgoing
> queues might collect a multitude of messages which will - at some point in
> time - make your server rather slow (err ... as in "non-workingly slow").
> You can set the message's TimeToReachQueue property accordingly.
>
> Cheers,
> -Ingo
>
> thinktecture
> http://www.thinktecture.com
> In-depth support and consulting for software architects and developers
>
>
>
> "Magne Ryholt" <magne.ryholt@bluezone.no> wrote in message
> news:OSLAeEQ5EHA.1264@TK2MSFTNGP12.phx.gbl...
>> Div. articles (e.g. Ingo Rammer
>> http://www.thinktecture.com/Resources/RemotingFAQ/RemotingUseCases.html)
>> concludes with the advice: Don't use events (callback) between machine,
>> even
>> in an intranet environment.
>>
>> Assume one server and several clients, all on the same subnet (datalayer
>> is
>> 100Mb ethernet)..
>> The server wants to update the clients with *something*, but don't want
>> to
>> use callback.
>>
>> Assume the server send small udp packets without actual data, but with
>> info.
>> regarding how the clients (which are listening for these udp packets)
>> could
>> get the changed, actual data from the server by using *normal* method
>> calls
>> with return values.
>> It is not neccessary for the server to know if the clients receive these
>> packets, it is nothing it can do about it anyway.
>>
>> This way callbacks could be avoided, however a little extra overhead is
>> introduced and an extra thread is needed on the clients.
>> To make it working simple, the UDP packet should not be fragmented.
>>
>> Any comments on this approach ? Reliability ?
>> How to make sure that udp packets are not fragmented ? Is there any
>> managed
>> or unmanaged method returning the MTU ?
>>
>>
>
>
>
- Next message: todd.mancini_at_gmail.com: "Re: Design Question on using Remoting"
- Previous message: todd.mancini_at_gmail.com: "Re: Can I create a remote object without a DLL on the client?"
- In reply to: Ingo Rammer: "Re: Events between machines"
- Next in thread: Ingo Rammer: "Re: Events between machines"
- Reply: Ingo Rammer: "Re: Events between machines"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|