Skip to content

Commit 14723c0

Browse files
authored
Implement periodic garbage collection (#84)
* Implement periodic garbage collection Added a periodic garbage collection call every 100 seconds. * Bump version from 4.52.0 to 4.53.0
1 parent 490d9f5 commit 14723c0

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "uncivserver.xyz",
3-
"version": "4.52.0",
3+
"version": "4.53.0",
44
"description": "An Open Source, Free to Play, Unciv Multiplayer Server written in Javascript",
55
"author": "Md. Touhidur Rahman",
66
"license": "BSD-3-Clause",

src/index.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,3 +84,7 @@ export const app = new Elysia({
8484
if (unix) chmod(unix, 0o666);
8585
console.log(`Server started at ${server.url}`);
8686
});
87+
88+
// periodically run gc
89+
setInterval(Bun.gc, 100_000);
90+

0 commit comments

Comments
 (0)