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

fix: add meta field to WakuMessage, and ephemeral to RelayWakuMessage #2

Merged
merged 1 commit into from
Mar 13, 2024

Conversation

richard-ramos
Copy link
Member

According to https://rfc.vac.dev/spec/14/, the meta field is an optional application specific attribute, so it makes sense for devs to be able to specify this field when using relay. I also ended up adding ephemeral to RelayWakuMessage to not store the message.

@@ -118,6 +118,9 @@ WakuMessage:
format: int64
ephemeral:
type: boolean
meta:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about rateLimitProof? According to https://rfc.vac.dev/spec/17/#wakumessage it can also be part of the message.
Also I saw that RPC protocol will return it, but REST does not

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be honest, I'd like to return all the fields that are part of the wakumessage protobuffer, instead of just an specific subset

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if it's okay to do that?
cc: @NagyZoltanPeter what do you think if we return all fields available in the protobuffer?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This won't be the quickest reply ever. Yes I do think we should mimic protobuf structures over REST API.

@gabrielmer
Copy link
Contributor

Should we merge this PR? But maybe without the ephemeral yet.

I just added support for meta field in nwaku. But having ephemeral might break things, as we don't let users set it when sending messages via REST (we should allow it, right?)

Copy link
Collaborator

@NagyZoltanPeter NagyZoltanPeter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this should be merged!!! Thank you.

@NagyZoltanPeter NagyZoltanPeter merged commit fd9ee59 into master Mar 13, 2024
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

Successfully merging this pull request may close these issues.

None yet

4 participants