Sign in to follow this  
Rich76

TCP .NET/C# Server with Java client?

Recommended Posts

Rich76    207
I have a .NET TCP server and client. I have a Data library with Structs, Classes, Serialize/Deserialize methods that is used by both the server and client to communicate over TCP. What can I do to allow my .NET TCP server to communicate with a Java client?

The data is contained in Structs and Classes and then serialized with [url="http://code.google.com/p/protobuf-net/"]protobuf-net[/url]. I imagine .NET Classes/Structs don't equal Java Classes/Structs..

What do I need to do to make this work? I know there is terminology for what I'm trying to do, but I can't think of it..

Share this post


Link to post
Share on other sites
hplus0603    11347
[quote name='Rich76' timestamp='1298151028' post='4776430']
I have a .NET TCP server and client. I have a Data library with Structs, Classes, Serialize/Deserialize methods that is used by both the server and client to communicate over TCP. What can I do to allow my .NET TCP server to communicate with a Java client?

The data is contained in Structs and Classes and then serialized with [url="http://code.google.com/p/protobuf-net/"]protobuf-net[/url]. I imagine .NET Classes/Structs don't equal Java Classes/Structs..

What do I need to do to make this work? I know there is terminology for what I'm trying to do, but I can't think of it..
[/quote]

You need to implement a (wire) protocol that both sides understand. If you use "protobuf" (the IDL described by Google) as the wire protocol, there should be a library for Java that can read those.

Also, there are a number of cross-platform techniques for sending objects and requests across a wire, including XDR (for UNIX, used for the NFS), DCOM (used by windows) and CORBA (used by enterprise systems). Java RMI, or .NET Remoting, are similar, but are not designed to be cross-language.

Share this post


Link to post
Share on other sites
Rich76    207
[quote name='hplus0603' timestamp='1298160339' post='4776493']
You need to implement a (wire) protocol that both sides understand. If you use "protobuf" (the IDL described by Google) as the wire protocol, there should be a library for Java that can read those.

Also, there are a number of cross-platform techniques for sending objects and requests across a wire, including XDR (for UNIX, used for the NFS), DCOM (used by windows) and CORBA (used by enterprise systems). Java RMI, or .NET Remoting, are similar, but are not designed to be cross-language.
[/quote]

As usual, thank you for the help. :)))


Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this