HomePhabricator
Diffusion Comm 32d6628a1db5

[services] Tunnelbroker - Changes to store the `deviceType` as an int instead…

Description

[services] Tunnelbroker - Changes to store the deviceType as an int instead of string

Summary:
This diff introduces changes to the type for deviceType field from a string to an integer.
The deviceType is an enum type in our proto file. The values come from the gRPC requests as an integer enum representation, Rust Tonic proto file compiler also creates the enum representation as an integer.

Before switching to Rust we are using the string as a storing type of the enum value in the database because of the enum matching was done using strings on the C++ side.
Now it doesn't make sense to store the enum value as a string in a database, because the matching of the enum in Rust uses integer representation as well as in gRPC implementation itself.

Linear task: ENG-2059

Test Plan:
The legacy C++ codebase is successfully built.
The usage of the functions is in D5490 and it successfully built

Reviewers: jon, marcin, tomek

Reviewed By: tomek

Subscribers: ashoat, tomek, atul, abosh

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