-
Notifications
You must be signed in to change notification settings - Fork 4
feat: Add map share rpc protobufs #1198
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
base: main
Are you sure you want to change the base?
Conversation
|
I had a good think about this today, and I think it's much simpler to move all of this into the map server and keep it separate from core, other than sending an actual map share "offer" (I think you've called this Routes for the Map-Sharer (although Map Receiver would use the DELETE route)
Routes for Map Receiver:
On Map-sharer side, frontend:
On Map-sharer side, Core backend:
On Map-receiver side, frontend:
On Map-receiver side, backend:
The rest of the backend code will all be in the map server, e.g. in the map server on the receiver, I'd prefer to use SSE (server-sent-events) for this, because it's the most lightweight and simple, however React Native support is pretty poor, and React Native has first-class support for WebSocket, so I'm not so sure. |
|
Sure. Shall I get started on the map server code as part of this or do you have that in a separate module or PR already? |
|
Should the extension message maybe contain the server URL and public key as well? Or is that going to be hidden within the map share server too? |
gmaclennan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good, just some tweaks to the message schema, plus I think a need for some validation. protobuf will decode missing fields without complaining and return them with defaults (empty string, 0, false), so we should validate that values which are required are non-empty - namely the strings. We should maybe just silently ignore an invalid received map share message? I'm not sure what else we can do with it? We do need to add some kind of Sentry / OpenTelemetry reporting for these kind of errors.
And some tests for those invalid values/messages.
|
Would you be able to add |
|
@gmaclennan Made changes
|
No description provided.