完善 server-rs DDD 重构计划与骨架
This commit is contained in:
3
server-rs/crates/module-big-fish/src/application.rs
Normal file
3
server-rs/crates/module-big-fish/src/application.rs
Normal file
@@ -0,0 +1,3 @@
|
||||
//! 大鱼吃小鱼应用编排过渡落位。
|
||||
//!
|
||||
//! 这里只组合领域规则并返回结果或事件,不直接调用外部图片、视频或存储服务。
|
||||
3
server-rs/crates/module-big-fish/src/commands.rs
Normal file
3
server-rs/crates/module-big-fish/src/commands.rs
Normal file
@@ -0,0 +1,3 @@
|
||||
//! 大鱼吃小鱼写入命令过渡落位。
|
||||
//!
|
||||
//! 用于表达创建会话、写入消息、更新资产槽和推进运行态等输入。
|
||||
4
server-rs/crates/module-big-fish/src/domain.rs
Normal file
4
server-rs/crates/module-big-fish/src/domain.rs
Normal file
@@ -0,0 +1,4 @@
|
||||
//! 大鱼吃小鱼领域模型过渡落位。
|
||||
//!
|
||||
//! 后续迁移创作会话、资产槽和运行态聚合时,只保留玩法状态与规则;
|
||||
//! 图片生成、OSS 与 HTTP handler 均留在 adapter 层。
|
||||
3
server-rs/crates/module-big-fish/src/errors.rs
Normal file
3
server-rs/crates/module-big-fish/src/errors.rs
Normal file
@@ -0,0 +1,3 @@
|
||||
//! 大鱼吃小鱼领域错误过渡落位。
|
||||
//!
|
||||
//! 错误只表达玩法规则失败,由 HTTP 和 SpacetimeDB adapter 分别映射展示。
|
||||
3
server-rs/crates/module-big-fish/src/events.rs
Normal file
3
server-rs/crates/module-big-fish/src/events.rs
Normal file
@@ -0,0 +1,3 @@
|
||||
//! 大鱼吃小鱼领域事件过渡落位。
|
||||
//!
|
||||
//! 用于表达草稿变化、资产槽变化和运行态 tick 等事实。
|
||||
@@ -1,3 +1,9 @@
|
||||
mod application;
|
||||
mod commands;
|
||||
mod domain;
|
||||
mod errors;
|
||||
mod events;
|
||||
|
||||
use std::{error::Error, fmt};
|
||||
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
Reference in New Issue
Block a user