Skip to content
This repository was archived by the owner on Mar 24, 2018. It is now read-only.
This repository was archived by the owner on Mar 24, 2018. It is now read-only.

Protobuf generated by ruby client can't be deserialized by java server #6

@edavedian

Description

@edavedian

I have written a ruby client which makes a REST call to a java server using the AddressBook example. When the protobuf in being deserialized by java, I am getting the following exception even though 'id' property was set in ruby client:

: com.google.protobuf.UninitializedMessageException: Message missing required fields: id
at com.google.protobuf.AbstractMessage$Builder.newUninitializedMessageException(AbstractMessage.java:550)
at com.symantec.AddressBookProtos$Person$Builder.build(AddressBookProtos.java:651)
at com.symantec.AddressBookProtos$Person$Builder.build(AddressBookProtos.java:1)
at com.symantec.ProtobufMessageBodyReader.readFrom(ProtobufMessageBodyReader.java:36)
... 39 more

For debugging purposes, I also serialized the same buffer in java and I realized that there is a small difference between the bytes serialized by ruby and the bytes serialized by java. The ruby generated bytes have an additional byte (2D) at the beginning and the rest is the same. Could this be the cause of the failure during deserialization?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions