Java serialization and .NET?


Quiz:  What do you think?    Java has a binary serialization format.  .NET has J#, which includes the JDK 1.1.4 class libraries, which includes Java serialization.  Will it be possible for a Java app running under JDK 1.4 to serialize an object graph to a stream, and then de-serialize that object graph in .NET?   We are not talking about angle brackets here, it would be binary serialization.

Does it work?

If it does work, Do I have to restrict myself strictly to J# on the .NET side?

I’ll post my answers tomorrow.

Comments (6)

  1. This would be pure sex if it worked…

  2. Good question 🙂 I really don’t know.

  3. Tom Kerigan says:

    Why would Microsoft base J# on such a decrepit set of class libraries? JDK 1.1.4 was released over 7 years ago and went out of service in July of 2001, according to javasoft.com. No developer wanting to use any code constructs remotely current and up-to-date would touch this stuff with a 10 foot pole!!! How does Microsoft expect to entice anyone from the J2SE world to even dabble in .NET with such a legacy implementation of Java in their product?

  4. Dino says:

    Kerigan, I think your understanding of technology and history is incomplete.

    First, the technology: regarding your comment about J# being "based" on an old set of class libraries. In addition to the Java 1.1.4 library, a J# app can take advantage of the full .NET base class library, and any .NET class lib written in any other .NET language. J# is not "based" on Java 1.1.4. Java 1.1.4 is just one of the library sets a J# application can take advantage of.

    Now the history:

    MS licensed Java from Sun. After MS received and implemented 1.1.4, there arose a either contract or copyright dispute (Sun says copyright, MS says contract). In any case, the Java drops to MS stopped, and the contract was suspended. Because of this, MS could no longer implement JDK 1.whatever in J++. 1.1.4 was the end of the line.

    One of the primary goals of J# is to enable J++ devs to bring their skills and code forward. That’s why 1.1.4 support is relevant and valuable. The Java library support in J# is not intended to entice J2EE developers. It is intended to help Microsoft J++ developers.

  5. Tom Kerigan says:

    Dino,

    If the purpose of J# wasn’t to suck Java developers into the .NET world, then why does Microsoft publish articles like "Moving Java Applications to .NET" (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/dotnet_movingjavaapps.asp)

    on MSDN? The paper clearly talks to ways that Java developers can migrate their applications to .NET by using the features of J#.

    Let’s face it – Microsoft wants people to move from Java to .NET and one of their many tactics to attempt it is to write articles (albeit cobbled together and horribly inaccurate) like the one I referenced above. Their only agenda with J# is not to just preserve the J++ developer base.

  6. dino says:

    This has all been hashed over, 2 years ago, when J# was released, but I’ll play along… Look, the primary goal of J# was, and is, and remains, to satisfy existing Microsoft (J++) customers. You can disagree with that, but it is a matter of fact. It’s just true. It’s what we work on inside Microsoft, it is the #1 metric against which the J# was measured. Will it satisfy J++ developers?

    A secondary J# goal is (and was, and remains) to provide Java-language syntax support. So anyone that knows the Java language, can use it.

    J# is absolutely not positioned to replace J2EE or J2SE or J2xE, or "entice" developers who use those things. As you clearly pointed out, J# is not really capable, since it has class library support from 1998. !! That said, being able to code in a familiar syntax is nice, sometimes.

    Microsoft would like developers to use .NET – no doubt about it. That’s why they pay big bucks for .NET marketing people like me ;). That’s also why Microsoft publishes articles like the one you cited. I don’t think this is shameful or regrettable at all. Conversely, Sun wants people to use J2SE 5.0, and IBM wants devs to use WebSphere. This is called competition. I think it’s all good.