Re: RPC versus windows sockets
From: Greg Kapoustin [MSFT] (grigorik_at_online.microsoft.com)
Date: 11/06/04
- Previous message: Chris Spencer: "CopyFileEx() fails copying files from a Win98 network drive"
- In reply to: Frank Franzoni: "RPC versus windows sockets"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 5 Nov 2004 16:14:06 -0800
I am not sure what exactly you are referring to by the "difference in
handling."
If you use RPC over ncacn_ip_tcp, then sockets will be used as the
underlying communication mechanism, but RPC will provide you with some
high-level services on top of the transport. For instance, RPC will take
care of data marshalling, SSPI calls to establish the security context and
encrypt/decrypt data, connection, and thread management.
These additional services will have some performance cost. The overhead is
dependent on the scenario, but should not be more than a few 10's of %'s
over a special-purpose socket implementation. Also, you need to consider
whether you require this high-level functionality, and if so, the time and
resources to implement it yourself. For instance, if you send structured
data, you need to develop some marshalling mechanism, which can be very
tricky to write. This alone may be a sufficient reason to use RPC in some
cases.
I your scenario is super-performance-critical, you should prototype
equivalent socket-based and an RPC-based implementation and compare them to
determine whether the overhead is acceptable to you. You may discover that
the RPC implementation performs better than a socket implementation that has
not been tuned.
If you are sending across a bytestream and do not need any high-level
functionality, sockets may be sufficient.
The search through this newsgroup and the web should yield some other
discussions on this subject.
Greg
-- This posting is provided "AS IS" with no warranties, and confers no rights. "Frank Franzoni" <franzoni@gepasoft.de> wrote in message news:cmffn5$o2e$04$1@news.t-online.com... > Hello, > > I have to develope a 'little' client/server application. > I must decide whether to use rpc or windows sockets for communication. > I am interested especially in differences between security, performance > and handling. > Can anybody tell me about his experiences or recommend me sources in the > internet? > Thank you and sorry for my bad english. > > Greetings Franzoni Frank > >
- Previous message: Chris Spencer: "CopyFileEx() fails copying files from a Win98 network drive"
- In reply to: Frank Franzoni: "RPC versus windows sockets"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|