Closed borissmidt closed 3 years ago
I think this is a nice idea. I believe if scalapb could provide these helpers, it'd be ideal, though we might also want to implement them ourselves. This would avoid a lot of duplication on downstream users that need to create their own helpers to turn protobuf types into java types reliably.
JUst so your are up to date. in the latest scalapb you can actually do all the conversions by the generator and describe it into the proto file or with auxiliarian descriptions. So that is very cool! https://scalapb.github.io/docs/customizations
This might be an issue that would better fit in scalapb itself i think. But it would be nice if we could register some types to the generator and tell it to use a certain class to wrap and unwrap certain grpc types. So
protobuf.Time
would becomejava.time.Instant
and thus request response would use these domain level 'types' instead of the very crudeprotobuf.Time
pojo.