UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

88 lines (87 loc) • 3.39 kB
//#region src/state/openclaw-state-db-contract.ts const DOCTOR_OWNED_STATE_TABLES = ["agent_deletion_journal"]; const FIRST_USE_STATE_TABLES = [ "user_profile_identities", "local_workspace_projections", "update_runs", "session_repository_workspaces", "github_repository_publication_requests", "github_publication_session_lifecycles", "skill_library_entries", "skill_library_revisions", "skill_library_events", "skill_library_uploads", "github_personal_publication_requests", "cron_job_runtime_authorities", "cron_run_trigger_state_retirements", "execution_identity_contexts", "mcp_oauth_pending_authorizations", "node_worker_launch_containers", "node_worker_launch_cleanup", "node_worker_launch_process_scopes", "node_worker_launches", "node_worker_prepared_workspaces", "node_worker_turns", "operator_approval_execution_identities", "operator_approval_standing_grants", "operator_approval_standing_grant_generations", "web_push_approval_deliveries", "execution_decision_facts", "execution_owner_lifecycle_bindings", "outbound_message_execution_bindings", "outbound_message_progress" ]; const FIRST_USE_STATE_INDEXES = [ "idx_user_profile_identities_profile_id", "idx_user_profile_identities_authorization", "idx_update_runs_created", "idx_update_runs_active", "idx_github_repository_publication_shared_request", "idx_github_repository_publication_personal_request", "idx_github_personal_publication_owner_session", "idx_github_personal_publication_pending", "idx_node_worker_launches_terminal_completed", "idx_node_worker_turns_terminal_completed", "idx_node_worker_turns_active_owner", "idx_operator_approval_standing_grants_binding", "idx_web_push_approval_deliveries_subscription", "execution_identity_contexts_run_created_idx", "execution_decision_facts_context_occurred_idx", "execution_decision_facts_run_occurred_idx", "outbound_message_execution_bindings_execution_event_idx", "outbound_message_progress_occurred_idx", "outbound_message_progress_run_occurred_idx" ]; const LAZY_ADDITIVE_STATE_TABLES = [ ...FIRST_USE_STATE_TABLES, "agent_provenance", "cron_run_receipts", "config_revision_keys", "secret_store_entries", "projects", "worktree_templates", "user_preferences", "device_pair_setup_completions", "github_publication_requests", "device_pairing_join_codes", "skill_workshop_proposal_events", "skill_workshop_collection_reviews", "skill_workshop_proposal_rollbacks", "skill_workshop_proposals", "worker_environment_ssh_fallback_ports", "worker_session_placement_moves" ]; const LAZY_ADDITIVE_STATE_INDEXES = [ ...FIRST_USE_STATE_INDEXES, "idx_cron_run_receipts_active_job", "idx_cron_run_receipts_job_history", "idx_github_publication_requests_pending", "secret_store_entries_live_idx", "idx_skill_workshop_collection_reviews_owner_time" ]; /** Maximum time one synchronous SQLite call may wait for a lock. */ const OPENCLAW_SQLITE_BUSY_TIMEOUT_MS = 5e3; /** User-facing guide for schema refusals; lives here so error sites avoid import cycles. */ const OPENCLAW_DATABASE_SCHEMA_DOCS_URL = "https://docs.openclaw.ai/reference/database-schemas"; //#endregion export { LAZY_ADDITIVE_STATE_TABLES as a, LAZY_ADDITIVE_STATE_INDEXES as i, FIRST_USE_STATE_INDEXES as n, OPENCLAW_DATABASE_SCHEMA_DOCS_URL as o, FIRST_USE_STATE_TABLES as r, OPENCLAW_SQLITE_BUSY_TIMEOUT_MS as s, DOCTOR_OWNED_STATE_TABLES as t };