a46a028ddb
- Removed ensureWorkerRunning calls from multiple hooks (cleanup, context, new, save, summary) to streamline code and avoid unnecessary checks. - Introduced fixed port usage for worker communication across hooks. - Enhanced error handling in newHook, saveHook, and summaryHook to provide clearer messages for worker connection issues. - Updated worker service to start without health checks, relying on PM2 for management. - Cached Claude executable path to optimize repeated calls. - Improved logging for better traceability of worker actions and errors.
20 lines
409 B
JavaScript
20 lines
409 B
JavaScript
/**
|
|
* PM2 Ecosystem Configuration for claude-mem Worker Service
|
|
*
|
|
* Usage:
|
|
* pm2 start ecosystem.config.cjs
|
|
* pm2 stop claude-mem-worker
|
|
* pm2 restart claude-mem-worker
|
|
* pm2 logs claude-mem-worker
|
|
* pm2 status
|
|
*/
|
|
|
|
module.exports = {
|
|
apps: [{
|
|
name: 'claude-mem-worker',
|
|
script: './plugin/scripts/worker-service.cjs',
|
|
error_file: '/dev/null',
|
|
out_file: '/dev/null'
|
|
}]
|
|
};
|