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

Could we expose sdkToProto function #754

Open
pingsutw opened this issue Feb 9, 2022 · 1 comment
Open

Could we expose sdkToProto function #754

pingsutw opened this issue Feb 9, 2022 · 1 comment

Comments

@pingsutw
Copy link
Contributor

pingsutw commented Feb 9, 2022

I want to convert the CloudEvent object to CloudEvent proto, but the SDK doesn't expose this function.
I've to do the following steps to get proto.

eventProto := cloudeventsModel.CloudEvent{}
byte, _ := pbcloudevents.Protobuf.Marshal(&event)
proto.Unmarshal(byte, &eventProto)

is there any other way to convert the object to a proto?

@embano1
Copy link
Member

embano1 commented Dec 11, 2022

Resolved #793

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

No branches or pull requests

2 participants