P1d: Migrate Actix controllers to Axum #2
Labels
No labels
meeting-notes
meeting-sensitive
meeting-transcript
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
coopcloud_code/home#2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of master roadmap #1.
Migrate 15 Actix-Web controllers (189 REST endpoints) to Axum route handlers backed by OsisMarketplace domain.
Scope
Acceptance criteria
Why Actix → Axum
1. AxumRpcServer is the Hero runtime
hero_rpc_osis::rpc::AxumRpcServer— the JSON-RPC 2.0 dispatch layer produced by the code generator — is built on Axum. The freezone backend uses it. Every Hero service uses it. The generatedOsisMarketplacedomain plugs directly into it. Running Actix alongside would mean two web frameworks in one binary for no reason.2. One framework, not two
With the RPC server (P1c) we already added Axum as a dependency. Keeping Actix means two async runtimes, two middleware stacks, two sets of extractors, double the dependency tree, and developers needing to know both.
3. Generated code expects Axum
osis_server_generated.rsproduces Axum router builders. The service handlers use Axum State pattern.build_router()returnsaxum::Router. Fighting this to keep Actix would require compatibility shims.4. Tower middleware ecosystem
Axum is built on Tower — the same stack used by
hero_rpc_osis,tower-sessions,tower-http. The freezone and all Hero services share this. Actix has its own middleware model that does not compose with Tower.5. The roadmap says so
Issue #1 explicitly calls for "migrate Actix-Web to Axum + AxumRpcServer" in P1.
What we are NOT changing
It is a framework swap under the same application — same car, different engine, because the engine needs to match the Hero ecosystem garage.
Progress
P1d Complete: Actix → Axum Migration
Commit:
b5faec9What was done
axum_app/controllers/actix-legacyfeature flagSessiontype — will refactor in P3)tokio::runtimeBuild status
cargo check— clean (0 errors)--features actix-legacy