一键导入
dataflow
Kailash DataFlow (Rust) — MANDATORY for DB/CRUD/bulk/migrations via sqlx + ModelDefinition. Raw SQL BLOCKED.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Kailash DataFlow (Rust) — MANDATORY for DB/CRUD/bulk/migrations via sqlx + ModelDefinition. Raw SQL BLOCKED.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Kailash Rust security — input validation, secrets, injection prevention. Hardcoded secrets BLOCKED.
Fork canon-incorporation runbook — rebase onto a canon kailash-rs base, re-apply the fork delta (merge-not-replace), SHA-anchored, gated + redteamed, human-gated cutover. Fork-active / canon-noop.
Kailash Rust validation — parameter, DataFlow, connection, workflow, security. Use for code review.
Project Skills (rs variant): cross-cutting patterns spanning Rust crates and PyO3/Magnus/napi-rs bindings. See enterprise-infra-bindings.md, l3-binding-parity.md, and ffi-handle-lifecycle.md.
Kailash Nexus (Rust) — MANDATORY for API+CLI+MCP unified deployment. Direct axum/tonic BLOCKED.
PyO3 Python bindings for Kailash Rust — maturin, .pyi stubs, Value mapping, register_callback.
| name | dataflow |
| description | Kailash DataFlow (Rust) — MANDATORY for DB/CRUD/bulk/migrations via sqlx + ModelDefinition. Raw SQL BLOCKED. |
Skills for kailash-dataflow -- the database framework built on kailash-core and sqlx.
Source: crates/kailash-dataflow/src/
| File | Description | Use When |
|---|---|---|
dataflow-quickstart.md | 5-minute introduction: DataFlow::new(), ModelDefinition, register_nodes, DataFlowExpress | Getting started, first-time setup |
dataflow-models.md | ModelDefinition builder API, FieldType, FieldBuilder, field constraints, validation | Defining models, field configuration, understanding generated nodes |
dataflow-crud-patterns.md | All 11 CRUD + bulk node input/output shapes, filter operators, workflow integration | Building queries, understanding input ValueMap structure, filter syntax |
dataflow-transactions.md | DataFlowTransaction, begin/commit/rollback, RAII auto-rollback, SqlConnection, pool config | Transaction management, connection pooling, begin_immediate for SQLite |
dataflow-multi-tenancy.md | QueryInterceptor, TenantContext, TenantContextMiddleware, tenant propagation | Row-level tenant isolation, per-tenant queries, admin bypass |
dataflow-gotchas.md | 15 common pitfalls: PK naming, timestamp auto-management, Create vs Update params | Debugging errors, understanding validation failures, avoiding mistakes |
dataflow-pool-prevention.md | Pool auto-scaling, monitoring, leak detection, query cache, lightweight pool, shared pools | Pool exhaustion, connection management, health checks, pool sizing |
dataflow-sync-express.md | DataFlowExpressSync: blocking CRUD for CLI/scripts/FFI, block_on pattern, transaction sync | Sync/blocking DataFlow, non-async contexts, C ABI, Go, Java, Ruby FFI |
sql_safety::quote_identifier() validates and quotes dynamic identifiers for DDL. All 3 dialects supported:
"identifier")`identifier`)Validation: ^[a-zA-Z_][a-zA-Z0-9_]*$, max 63 chars, reject-don't-escape. Construction-time panics in ModelDefinition::new, FieldDef::new, TenantContext::new. See rules/dataflow-identifier-safety.md.
Multi-tenant cache isolation (v3.12+): CacheKey includes optional tenant_id field. Multi-tenant models MUST use get_tenant()/put_tenant() — the single-tenant methods silently share cache slots across tenants. See rules/tenant-isolation.md.
TenantRequired enforcement (v3.12+): ModelDefinition::multi_tenant() marks a model as requiring tenant context. model.require_tenant(tenant_id) returns DataFlowError::TenantRequired when tenant_id is None for multi-tenant models. Use at express/query layer before cache access.
WHERE clause quoting (v3.12+): build_where_clause() and soft_delete_where() now route all column names through quote_identifier() (defense-in-depth). build_select_by_id() and build_delete() return Result and quote PK/soft-delete columns. Callers must handle ? propagation.
dataflow-models.md or dataflow-quickstart.mddataflow-crud-patterns.mddataflow-crud-patterns.mddataflow-quickstart.md (DataFlowExpress section)dataflow-transactions.mddataflow-multi-tenancy.mddataflow-gotchas.mddataflow-gotchas.md (gotcha #3)dataflow-pool-prevention.mddataflow-pool-prevention.mddataflow-pool-prevention.mddataflow-pool-prevention.mddataflow-pool-prevention.mddataflow-pool-prevention.mddataflow-gotchas.md (gotcha #11)dataflow-crud-patterns.mddataflow-quickstart.md (Inspector section)dataflow-quickstart.md (Python binding section)dataflow-sync-express.mddataflow-sync-express.mddataflow-sync-express.md (FFI section)ModelDefinition::new() with fluent .field() calls (not a proc-macro)BTreeMap<Arc<str>, Value> (ValueMap)QueryDialect::from_url()