Page MenuHomePhabricator

[lib] implement sending message to Tunnelbroker
ClosedPublic

Authored by kamil on Jun 20 2024, 2:55 PM.
Tags
None
Referenced Files
F3385588: D12524.id41806.diff
Fri, Nov 29, 1:08 AM
Unknown Object (File)
Mon, Nov 25, 2:02 PM
Unknown Object (File)
Mon, Nov 25, 12:43 PM
Unknown Object (File)
Mon, Nov 25, 12:27 PM
Unknown Object (File)
Mon, Nov 25, 10:48 AM
Unknown Object (File)
Thu, Nov 21, 1:58 AM
Unknown Object (File)
Tue, Nov 12, 5:03 AM
Unknown Object (File)
Fri, Nov 8, 10:36 PM
Subscribers

Details

Summary

ENG-8347

Add callback to send message to Tunnelbroker.

Depends on D12523

Test Plan

Call this from both web and native:

const message: SetDeviceToken = {
  type: messageToTunnelbrokerTypes.SET_DEVICE_TOKEN,
  deviceToken: 'token',
};
 await sendMessageToTunnelbroker(JSON.stringify(message));

and verify if deviceToken is persisted in DDB.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Jun 20 2024, 4:13 PM
lib/tunnelbroker/tunnelbroker-context.js
363–364

Leftover?

lib/tunnelbroker/tunnelbroker-context.js
363–364

yeah

This revision is now accepted and ready to land.Jun 24 2024, 11:44 PM
lib/tunnelbroker/tunnelbroker-context.js
437–438 ↗(On Diff #41806)

The naming here is a bit confusing. Should sendMessage be renamed to something that makes it contrast more clearly with sendMessageToTunnelbroker?

lib/tunnelbroker/tunnelbroker-context.js
437–438 ↗(On Diff #41806)

point 1 in ENG-8621