Jeremie Fraeys
1f495dfbb7
api: regenerate OpenAPI types and server code
...
- Update openapi.yaml spec
- Regenerate server_gen.go with oapi-codegen
- Update adapter, routes, and server configuration
2026-03-04 13:23:34 -05:00
Jeremie Fraeys
420de879ff
feat(api): integrate scheduler protocol and WebSocket enhancements
...
Update API layer for scheduler integration:
- WebSocket handlers with scheduler protocol support
- Jobs WebSocket endpoint with priority queue integration
- Validation middleware for scheduler messages
- Server configuration with security hardening
- Protocol definitions for worker-scheduler communication
- Dataset handlers with tenant isolation checks
- Response helpers with audit context
- OpenAPI spec updates for new endpoints
2026-02-26 12:05:57 -05:00
Jeremie Fraeys
23e5f3d1dc
refactor(api): internal refactoring for TUI and worker modules
...
- Refactor internal/worker and internal/queue packages
- Update cmd/tui for monitoring interface
- Update test configurations
2026-02-20 15:51:23 -05:00
Jeremie Fraeys
f0ffbb4a3d
refactor: Phase 5 complete - API packages extracted
...
Extracted all deferred API packages from monolithic ws_*.go files:
- api/routes.go (75 lines) - Extracted route registration from server.go
- api/errors.go (108 lines) - Standardized error responses and error codes
- api/jobs/handlers.go (271 lines) - Job WebSocket handlers
* HandleAnnotateRun, HandleSetRunNarrative
* HandleCancelJob, HandlePruneJobs, HandleListJobs
- api/jupyter/handlers.go (244 lines) - Jupyter WebSocket handlers
* HandleStartJupyter, HandleStopJupyter
* HandleListJupyter, HandleListJupyterPackages
* HandleRemoveJupyter, HandleRestoreJupyter
- api/validate/handlers.go (163 lines) - Validation WebSocket handlers
* HandleValidate, HandleGetValidateStatus, HandleListValidations
- api/ws/handler.go (298 lines) - WebSocket handler framework
* Core WebSocket handling logic
* Opcode constants and error codes
Lines redistributed: ~1,150 lines from ws_jobs.go (1,365), ws_jupyter.go (512),
ws_validate.go (523), ws_handler.go (379) into focused packages.
Note: Original ws_*.go files still present - cleanup in next commit.
Build status: Compiles successfully
2026-02-17 13:25:58 -05:00
Jeremie Fraeys
db7fbbd8d5
refactor: Phase 5 - split API package into focused files
...
Reorganized internal/api/ package to follow single-concern principle:
- api/factory.go (new file, 257 lines)
- Extracted component initialization from server.go
- initializeComponents(), setupLogger(), initExperimentManager()
- initTaskQueue(), initDatabase(), initDatabaseSchema()
- initSecurity(), initJupyterServiceManager(), initAuditLogger()
- api/middleware.go (new file, 31 lines)
- Extracted wrapWithMiddleware() - security middleware chain
- Centralized auth, rate limiting, CORS, security headers
- api/server.go (reduced from 446 to 212 lines)
- Now focused on Server lifecycle: NewServer, Start, WaitForShutdown, Close
- Removed initialization logic (moved to factory.go)
- Removed middleware wrapper (moved to middleware.go)
- api/metrics_middleware.go (existing, 64 lines)
- Already had wrapWithMetrics(), left in place
Lines redistributed: ~180 lines from monolithic server.go
Build status: Compiles successfully
2026-02-17 13:11:02 -05:00
Jeremie Fraeys
2e701340e5
feat(core): API, worker, queue, and manifest improvements
...
- Add protocol buffer optimizations (internal/api/protocol.go)
- Add filesystem queue backend (internal/queue/filesystem_queue.go)
- Add run manifest support (internal/manifest/run_manifest.go)
- Worker and jupyter task refinements
- Exported test wrappers for benchmarking
2026-02-12 12:05:17 -05:00
Jeremie Fraeys
add4a90e62
feat(api): refactor websocket handlers; add health and prometheus middleware
2026-01-05 12:31:07 -05:00
Jeremie Fraeys
cd5640ebd2
Slim and secure: move scripts, clean configs, remove secrets
...
- Move ci-test.sh and setup.sh to scripts/
- Trim docs/src/zig-cli.md to current structure
- Replace hardcoded secrets with placeholders in configs
- Update .gitignore to block .env*, secrets/, keys, build artifacts
- Slim README.md to reflect current CLI/TUI split
- Add cleanup trap to ci-test.sh
- Ensure no secrets are committed
2025-12-07 13:57:51 -05:00