Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for messages without fields (empty messages) #32

Closed
technocoreai opened this issue Oct 21, 2014 · 4 comments
Closed

Support for messages without fields (empty messages) #32

technocoreai opened this issue Oct 21, 2014 · 4 comments
Labels
Milestone

Comments

@technocoreai
Copy link

ProtoToJavaBeanCompiler ignores messages without any fields for some reason. The comment looks like it's related to RPC services somehow, but it's possible to have an empty message in a proto schema without services (for future extensibility) and protoc compiles such schemas just fine.

@posix4e
Copy link
Contributor

posix4e commented Nov 11, 2014

We have this need. For now my workaround is plopping in an optional boolean

@kshchepanovskyi
Copy link
Member

Let's fix it :)

@kshchepanovskyi
Copy link
Member

This problem also affects RuntimeSchema:

16:28:54.118 [pool-19-thread-1] ERROR  c.p.l.t.i.c.utils.GameEngineHelper - Can't emit StartGameActions
java.lang.RuntimeException: Not able to map any fields from class com.playtech.live.tableservice.api.event.StartGameActions.  All fields are either transient/static.
    at com.dyuproject.protostuff.runtime.RuntimeSchema.createFrom(RuntimeSchema.java:245) ~[protostuff-runtime-1.0.7.jar:1.0.7]
    at com.dyuproject.protostuff.runtime.RuntimeSchema.createFrom(RuntimeSchema.java:147) ~[protostuff-runtime-1.0.7.jar:1.0.7]
    at com.playtech.openapi.core.frontend.messages.resolver.SchemaCache.createSchema(SchemaCache.java:46) ~[com.playtech.openapi.core-14.10.0.11.jar:14.10.0.1410061255-SNAPSHOT]
    at com.playtech.openapi.core.frontend.messages.resolver.SchemaCache.getSchema(SchemaCache.java:38) ~[com.playtech.openapi.core-14.10.0.11.jar:14.10.0.1410061255-SNAPSHOT]
    at com.playtech.live.tableservice.transport.util.LogRecordSerializer.serialize(LogRecordSerializer.java:26) ~[classes/:na]

@kshchepanovskyi kshchepanovskyi changed the title Empty message support in ProtoToJavaBeanCompiler Empty message support Dec 14, 2014
@kshchepanovskyi kshchepanovskyi changed the title Empty message support Support for messages without fields (empty messages) Dec 14, 2014
kshchepanovskyi added a commit that referenced this issue Dec 14, 2014
@kshchepanovskyi
Copy link
Member

Merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants