Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


TCP .NET/C# Server with Java client?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 Rich76   Members   -  Reputation: 178

Like
0Likes
Like

Posted 19 February 2011 - 03:30 PM

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 protobuf-net. 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..

Sponsor:

#2 hplus0603   Moderators   -  Reputation: 5547

Like
1Likes
Like

Posted 19 February 2011 - 06:05 PM

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 protobuf-net. 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..


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.
enum Bool { True, False, FileNotFound };

#3 Rich76   Members   -  Reputation: 178

Like
0Likes
Like

Posted 19 February 2011 - 07:41 PM

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.


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







Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS