fix: plug resource leaks and add hook command timeout
- LSP signal handlers: store refs, return unregister handle, call in stopAll() - session-tools-store: add per-session deleteSessionTools(), wire into session.deleted - executeHookCommand: add 30s timeout with SIGTERM→SIGKILL escalation
This commit is contained in:
committed by
YeonGyu-Kim
parent
ac81e1d7cd
commit
b666ab24df
@@ -1,14 +1,18 @@
|
||||
const store = new Map<string, Record<string, boolean>>()
|
||||
const store = new Map<string, Record<string, boolean>>();
|
||||
|
||||
export function setSessionTools(sessionID: string, tools: Record<string, boolean>): void {
|
||||
store.set(sessionID, { ...tools })
|
||||
store.set(sessionID, { ...tools });
|
||||
}
|
||||
|
||||
export function getSessionTools(sessionID: string): Record<string, boolean> | undefined {
|
||||
const tools = store.get(sessionID)
|
||||
return tools ? { ...tools } : undefined
|
||||
const tools = store.get(sessionID);
|
||||
return tools ? { ...tools } : undefined;
|
||||
}
|
||||
|
||||
export function deleteSessionTools(sessionID: string): void {
|
||||
store.delete(sessionID);
|
||||
}
|
||||
|
||||
export function clearSessionTools(): void {
|
||||
store.clear()
|
||||
store.clear();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user