Is it true that I cannot send data greater than 64K between an RMI client and server?

Govind Seshadri

Yes, that's true only with RMI systems prior to JDK 1.3, where you cannot serialize a string greater than 64k. You would have a java.io.UTFDataFormatException thrown if you tried. However, since the serialization protocol has been enhanced with JDK 1.3, you should now be able to serialize strings greater than 64K.

However, do keep mind that for this to work, both the client and server JVMs need to be JDK 1.3 compliant. Otherwise, if your, say, JDK 1.2-compliant RMI server tried to read serialized data greater than 64K sent by a JDK 1.3-compliant RMI client, the server would throw a java.io.StreamCorruptedException.

0 Comments  (click to add your comment)
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.