Reputation: 21
func processPubSubMsgFn(ctx context.Context, in *pubsub.PubsubMessage) v1.someProto {
someProto := &v1.someProto{}
if err := proto.Unmarshal((in.Data), someProto); err != nil {
log.Fatalln("Failed to parse address book:", err)
}
return *someProto
}
Causes: bad return type caused by: encoding struct v1.someProto type has unexported field: state
When trying to run the pipeline, In java I would set the coder for the message type, not sure how to do this in the Go Version of Apache Beam
Upvotes: 0
Views: 564
Reputation: 656
From what i see in apache beam sdk you should return *v1.someProto
instead of v1.someProto
.
Upvotes: 1