Skip to content

Commit b7f71e7

Browse files
committed
chore: add node exit logs
1 parent 5c9b285 commit b7f71e7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src-node/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ function resetOrphanExitTimer() {
158158
// in debug mode, we wait for more minutes to not exit node if phcode doesn't send heartbeats on break point debug
159159
clearTimeout(orphanExitTimer);
160160
orphanExitTimer = setTimeout(()=>{
161+
console.error(`Node did not receive heartbeat for ${timeout/1000}S, existing as orphan node process detected.`);
161162
process.exit(1);
162163
}, timeout);
163164
}
@@ -170,6 +171,7 @@ function processCommand(line) {
170171
lmdb.dumpDBToFileAndCloseDB()
171172
.catch(console.error)
172173
.finally(()=>{
174+
console.log("Node terminated by phcode.");
173175
process.exit(0);
174176
});
175177
return;

0 commit comments

Comments
 (0)