mirror of
https://github.com/qingchencloud/clawpanel.git
synced 2026-07-12 16:01:56 +08:00
feat(hermes): add kanban worker log controls
This commit is contained in:
@@ -181,6 +181,8 @@ const KANBAN_DEFAULTS = {
|
||||
failureLimit: 2,
|
||||
autoDecompose: true,
|
||||
autoDecomposePerTick: 3,
|
||||
workerLogRotateBytes: 2097152,
|
||||
workerLogBackupCount: 1,
|
||||
dispatchStaleTimeoutSeconds: 14400,
|
||||
}
|
||||
|
||||
@@ -1525,6 +1527,14 @@ export function render() {
|
||||
<span class="hm-field-label">${t('engine.hermesKanbanConfigAutoDecomposePerTick')}</span>
|
||||
<input id="hm-kanban-auto-decompose-per-tick" class="hm-input" type="number" inputmode="numeric" min="1" max="1000" step="1" value="${esc(kanbanValues.autoDecomposePerTick)}" ${disabled ? 'disabled' : ''}>
|
||||
</label>
|
||||
<label class="hm-field">
|
||||
<span class="hm-field-label">${t('engine.hermesKanbanConfigWorkerLogRotateBytes')}</span>
|
||||
<input id="hm-kanban-worker-log-rotate-bytes" class="hm-input" type="number" inputmode="numeric" min="1" max="1073741824" step="1024" value="${esc(kanbanValues.workerLogRotateBytes)}" ${disabled ? 'disabled' : ''}>
|
||||
</label>
|
||||
<label class="hm-field">
|
||||
<span class="hm-field-label">${t('engine.hermesKanbanConfigWorkerLogBackupCount')}</span>
|
||||
<input id="hm-kanban-worker-log-backup-count" class="hm-input" type="number" inputmode="numeric" min="0" max="100" step="1" value="${esc(kanbanValues.workerLogBackupCount)}" ${disabled ? 'disabled' : ''}>
|
||||
</label>
|
||||
<label class="hm-field">
|
||||
<span class="hm-field-label">${t('engine.hermesKanbanConfigDispatchStaleTimeoutSeconds')}</span>
|
||||
<input id="hm-kanban-dispatch-stale-timeout-seconds" class="hm-input" type="number" inputmode="numeric" min="0" max="604800" step="60" value="${esc(kanbanValues.dispatchStaleTimeoutSeconds)}" ${disabled ? 'disabled' : ''}>
|
||||
@@ -3530,6 +3540,8 @@ export function render() {
|
||||
failureLimit: el.querySelector('#hm-kanban-failure-limit')?.value || '2',
|
||||
autoDecompose: el.querySelector('#hm-kanban-auto-decompose')?.checked ?? true,
|
||||
autoDecomposePerTick: el.querySelector('#hm-kanban-auto-decompose-per-tick')?.value || '3',
|
||||
workerLogRotateBytes: el.querySelector('#hm-kanban-worker-log-rotate-bytes')?.value || '2097152',
|
||||
workerLogBackupCount: el.querySelector('#hm-kanban-worker-log-backup-count')?.value || '1',
|
||||
dispatchStaleTimeoutSeconds: el.querySelector('#hm-kanban-dispatch-stale-timeout-seconds')?.value || '14400',
|
||||
}
|
||||
kanbanSaving = true
|
||||
|
||||
@@ -1042,8 +1042,10 @@ export default {
|
||||
hermesKanbanConfigFailureLimit: _('失败重试上限', 'Failure retry limit', '失敗重試上限'),
|
||||
hermesKanbanConfigAutoDecompose: _('自动拆解待办任务', 'Auto decompose tasks', '自動拆解待辦任務'),
|
||||
hermesKanbanConfigAutoDecomposePerTick: _('每轮自动拆解数量', 'Auto decompose per tick', '每輪自動拆解數量'),
|
||||
hermesKanbanConfigWorkerLogRotateBytes: _('Worker 日志轮转大小(字节)', 'Worker log rotation size (bytes)', 'Worker 日誌輪轉大小(位元組)'),
|
||||
hermesKanbanConfigWorkerLogBackupCount: _('Worker 日志备份数量', 'Worker log backups', 'Worker 日誌備份數量'),
|
||||
hermesKanbanConfigDispatchStaleTimeoutSeconds: _('无心跳回收时间(秒)', 'Heartbeat reclaim timeout (s)', '無心跳回收時間(秒)'),
|
||||
hermesKanbanConfigFootnote: _('写入 kanban.dispatch_in_gateway、dispatch_interval_seconds、max_spawn、max_in_progress、failure_limit、auto_decompose、auto_decompose_per_tick、dispatch_stale_timeout_seconds。两个并发上限填 0 表示不写入限制;无心跳回收填 0 表示关闭自动回收。', 'Writes kanban.dispatch_in_gateway, dispatch_interval_seconds, max_spawn, max_in_progress, failure_limit, auto_decompose, auto_decompose_per_tick, and dispatch_stale_timeout_seconds. Set concurrency caps to 0 to omit limits; set heartbeat reclaim to 0 to disable automatic reclaim.', '寫入 kanban.dispatch_in_gateway、dispatch_interval_seconds、max_spawn、max_in_progress、failure_limit、auto_decompose、auto_decompose_per_tick、dispatch_stale_timeout_seconds。兩個並發上限填 0 表示不寫入限制;無心跳回收填 0 表示關閉自動回收。'),
|
||||
hermesKanbanConfigFootnote: _('写入 kanban.dispatch_in_gateway、dispatch_interval_seconds、max_spawn、max_in_progress、failure_limit、auto_decompose、auto_decompose_per_tick、worker_log_rotate_bytes、worker_log_backup_count、dispatch_stale_timeout_seconds。两个并发上限填 0 表示不写入限制;Worker 日志超过轮转大小会在下次启动前处理,备份数量填 0 表示超限时不保留旧日志;无心跳回收填 0 表示关闭自动回收。', 'Writes kanban.dispatch_in_gateway, dispatch_interval_seconds, max_spawn, max_in_progress, failure_limit, auto_decompose, auto_decompose_per_tick, worker_log_rotate_bytes, worker_log_backup_count, and dispatch_stale_timeout_seconds. Set concurrency caps to 0 to omit limits; worker logs are handled before the next worker starts after they exceed the rotation size, and 0 backups means old logs are not kept; set heartbeat reclaim to 0 to disable automatic reclaim.', '寫入 kanban.dispatch_in_gateway、dispatch_interval_seconds、max_spawn、max_in_progress、failure_limit、auto_decompose、auto_decompose_per_tick、worker_log_rotate_bytes、worker_log_backup_count、dispatch_stale_timeout_seconds。兩個並發上限填 0 表示不寫入限制;Worker 日誌超過輪轉大小會在下次啟動前處理,備份數量填 0 表示超限時不保留舊日誌;無心跳回收填 0 表示關閉自動回收。'),
|
||||
hermesSecurityConfigTitle: _('Tirith 安全扫描', 'Tirith security scanning', 'Tirith 安全掃描'),
|
||||
hermesSecurityConfigDesc: _('控制终端命令执行前的 Tirith 内容扫描,拦截明显的 URL 伪装、管道执行和注入风险。', 'Control Tirith content scanning before terminal commands run to catch obvious URL spoofing, pipe-to-shell, and injection risks.', '控制終端命令執行前的 Tirith 內容掃描,攔截明顯的 URL 偽裝、管道執行和注入風險。'),
|
||||
hermesSecurityConfigStatusReady: _('结构化配置', 'structured settings', '結構化設定'),
|
||||
|
||||
Reference in New Issue
Block a user