This PR aims to decouple the NodeInfo API layer from the database by introducing a new protobuf-based entity.
By separating the internal database model from the API representation, this reduces tight coupling and makes it easier to update or modify the internal database without impacting the API. Using protobuf ensures changes to the project's protobuf definitions are available in the database without migrations or schema changes, improving database flexibility and reducing maintenance overhead.
Key changes:
Introduces a protobuf-based NodeEntity as the new Room database entity;
Replaces NodeInfo references with NodeEntity in the DAO layer, NodeDB, and MeshService;
Decouples NodeInfo from the database schema, allowing future changes without impacting the API;
Protobuf definitions are used to define the data format independently of the API.
Note:
Further work is required to fully replace all instances of NodeInfo with NodeEntity exposed to the UI layer.
This PR aims to decouple the
NodeInfo
API layer from the database by introducing a new protobuf-based entity.By separating the internal database model from the API representation, this reduces tight coupling and makes it easier to update or modify the internal database without impacting the API. Using protobuf ensures changes to the project's protobuf definitions are available in the database without migrations or schema changes, improving database flexibility and reducing maintenance overhead.
Key changes:
NodeEntity
as the new Room database entity;NodeInfo
references withNodeEntity
in the DAO layer,NodeDB
, andMeshService
;NodeInfo
from the database schema, allowing future changes without impacting the API;Note:
NodeInfo
withNodeEntity
exposed to the UI layer.