Replace gRPC Backend (#10)

**Rationale:**

Having two separate servers and communication methods resulted in additional maintenance & the need to convert often between backend & frontend data types.
By moving the backend communication off of gRPC and to just use websockets it both gives more control & allows for simplification of the implementation.

#8

**Changes:**

- Replaces gRPC backend.
  - New implementation automatically handles reconnect logic
- Implements an api layer
- Migrates examples to the api layer
- Implements a proc macro to make command handling easier
- Implements unit tests for the api layer (90+% coverage)
- Implements integration tests for the proc macro (90+% coverage)

Reviewed-on: #10
Co-authored-by: Sergey Savelyev <sergeysav.nn@gmail.com>
Co-committed-by: Sergey Savelyev <sergeysav.nn@gmail.com>
This commit was merged in pull request #10.
This commit is contained in:
2026-01-01 10:11:53 -08:00
committed by sergeysav
parent f658b55586
commit 788dd10a91
68 changed files with 3934 additions and 1504 deletions

View File

@@ -6,25 +6,20 @@ version = "0.1.0"
authors = ["Sergey <me@sergeysav.com>"]
[dependencies]
fern = "0.7.1"
log = "0.4.29"
prost = "0.13.5"
rand = "0.9.0"
tonic = { version = "0.12.3" }
tokio = { version = "1.43.0", features = ["rt-multi-thread", "signal", "fs"] }
chrono = "0.4.42"
actix-web = { version = "4.12.1", features = [ ] }
actix-ws = "0.3.0"
tokio-util = "0.7.17"
serde = { version = "1.0.228", features = ["derive"] }
serde_json = "1.0.145"
hex = "0.4.3"
papaya = "0.2.3"
thiserror = "2.0.17"
derive_more = { version = "2.1.0", features = ["from"] }
anyhow = "1.0.100"
sqlx = { version = "0.8.6", features = [ "runtime-tokio", "tls-native-tls", "sqlite" ] }
uuid = { version = "1.19.0", features = ["v4"] }
[build-dependencies]
tonic-build = "0.12.3"
actix-web = { workspace = true, features = [ ] }
actix-ws = { workspace = true }
anyhow = { workspace = true }
api = { path = "../api" }
chrono = { workspace = true }
derive_more = { workspace = true, features = ["from"] }
fern = { workspace = true, features = ["colored"] }
futures-util = { workspace = true }
log = { workspace = true }
papaya = { workspace = true }
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }
sqlx = { workspace = true, features = [ "runtime-tokio", "tls-rustls-ring-native-roots", "sqlite" ] }
thiserror = { workspace = true }
tokio = { workspace = true, features = ["rt-multi-thread", "signal", "fs"] }
tokio-util = { workspace = true }
uuid = { workspace = true }