feat(FN-3507): block dispatch when project lacks node mapping
Adds validation to block task dispatch when no project-node mapping exists (FN-3507), including a read helper in CentralCore and a new `node-dispatch-validation` module integrated into the scheduler and in-process runtime, with test coverage across routing and validation scenarios. Fusion-Task-Id: FN-3507
This commit is contained in:
@@ -1769,6 +1769,16 @@ export class CentralCore extends EventEmitter<CentralCoreEvents> {
|
||||
return row ? this.rowToProjectNodePathMapping(row) : undefined;
|
||||
}
|
||||
|
||||
async getProjectNodePath(projectId: string, nodeId: string): Promise<string | undefined> {
|
||||
this.ensureInitialized();
|
||||
|
||||
const row = this.db!
|
||||
.prepare("SELECT path FROM projectNodePathMappings WHERE projectId = ? AND nodeId = ?")
|
||||
.get(projectId, nodeId) as { path: string } | undefined;
|
||||
|
||||
return row?.path;
|
||||
}
|
||||
|
||||
async listProjectNodePathMappings(filters?: {
|
||||
projectId?: string;
|
||||
nodeId?: string;
|
||||
|
||||
Reference in New Issue
Block a user