From f98cf669491b001b838409faa1d48026051d3393 Mon Sep 17 00:00:00 2001 From: aitbc Date: Sun, 3 May 2026 23:34:42 +0200 Subject: [PATCH] docs: update documentation for completed placeholder implementations - Update plan file to mark all implementations as completed - Update blockchain-node.md to document HMAC-SHA256 MAC computation in keystore - Add Agent Integration Service section to coordinator-api.md documenting: - Systemd-based deployment - Health checks with systemd + HTTP monitoring - Instance lifecycle management (deployment, removal, rollback) - Metrics collection with database fallback - Configurable alerting rules --- docs/apps/blockchain/blockchain-node.md | 3 ++- docs/apps/coordinator/coordinator-api.md | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/docs/apps/blockchain/blockchain-node.md b/docs/apps/blockchain/blockchain-node.md index 64f035a3..06c3a10b 100644 --- a/docs/apps/blockchain/blockchain-node.md +++ b/docs/apps/blockchain/blockchain-node.md @@ -127,7 +127,8 @@ The node can run multiple chains simultaneously by setting `supported_chains` in ## Keystore Management ### Encrypted Keystore Format -- Uses Web3 keystore format (AES‑256‑GCM + PBKDF2). +- Uses Web3 keystore format (AES‑256‑GCM + PBKDF2 + HMAC-SHA256 MAC). +- MAC computed over derived_key[16:32] + ciphertext for password validation. - Password stored in `keystore/.password` (chmod 600). - Private keys are **never** stored in plaintext. diff --git a/docs/apps/coordinator/coordinator-api.md b/docs/apps/coordinator/coordinator-api.md index a41c560f..39535184 100644 --- a/docs/apps/coordinator/coordinator-api.md +++ b/docs/apps/coordinator/coordinator-api.md @@ -66,6 +66,28 @@ The multi-modal RL router proxies to the AI service for job management: All endpoints use `AITBCHTTPClient` to proxy requests to the AI service (default port 8106). When the AI service is unavailable, endpoints return error responses indicating the service is unreachable. +## Agent Integration Service + +The agent integration service provides deployment and management capabilities for agent instances: + +- **Systemd-based Deployment**: Agent instances are deployed as systemd services with automatic startup and monitoring +- **Health Checks**: HTTP health checks combined with systemd status monitoring for instance health tracking +- **Instance Lifecycle**: Full lifecycle management including deployment, removal, and rollback to previous versions +- **Metrics Collection**: Automatic metrics collection from agent endpoints with database fallback for monitoring +- **Alerting Rules**: Configurable alerting thresholds for CPU, memory, error rate, and response time monitoring + +### Deployment Features +- Dynamic systemd service file generation +- Service enablement and automatic startup +- Startup monitoring with active status verification +- Graceful failure handling with cleanup + +### Monitoring Features +- Multi-source health checks (systemd + HTTP endpoints) +- Historical health check tracking (last 100 checks) +- Metrics aggregation with fallback to database values +- Configurable alert thresholds and channels + ## Development Setup 1. Create a virtual environment in `apps/coordinator-api/.venv`.