HomePhabricator
Diffusion Comm 3733bf3e39eb

[keyserver] Replace deprecated sendToDevice firebase-admin method

Description

[keyserver] Replace deprecated sendToDevice firebase-admin method

Summary: This method is deprecated and is now completely failing all requests. This diff resolves ENG-235.

Test Plan:
I set up a test environment on my personal server. It's running the latest keyserver release (115). In this environment, I created a test script to generate some notifs by sending messages from commbot to a test account. I confirmed that the test account received a notif on an Android device it's logged into.

I also did some testing to make sure the error handling logic worked correctly. In my test environment, I set the device token to fake and checked what the error response looked like, and made sure that error.errorInfo.code contained the error code. For my fake device token, the error code ended up being messaging/invalid-argument, but I'm pretty sure that the error code would appear in the same place for the types of errors we care about (fcmTokenInvalidationErrors).

Reviewers: varun, will

Reviewed By: varun, will

Subscribers: marcin, kamil, tomek

Differential Revision: https://phab.comm.dev/D13368

Details

Provenance
ashoatAuthored on Sep 17 2024, 12:47 PM
Reviewer
varun
Differential Revision
D13368: [keyserver] Replace deprecated sendToDevice firebase-admin method
Parents
rCOMM849adf8a969d: [grpc_clients] bump gRPC connection timeout to 30 seconds
Branches
Unknown
Tags
Unknown