@jeffusion/bungee 5.6.1 → 5.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +8 -5
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -3397,7 +3397,7 @@ import { createInterface } from "node:readline";
3397
3397
  // package.json
3398
3398
  var package_default = {
3399
3399
  name: "@jeffusion/bungee",
3400
- version: "5.6.1",
3400
+ version: "5.7.0",
3401
3401
  description: "High-performance reverse proxy server CLI",
3402
3402
  type: "module",
3403
3403
  bin: {
@@ -5033,7 +5033,7 @@ class DaemonManager {
5033
5033
  forceStop;
5034
5034
  rpcTimeoutMs;
5035
5035
  forceWaitMs;
5036
- startTimeoutMs = 30000;
5036
+ startTimeoutMs;
5037
5037
  stopTimeoutMs = 30000;
5038
5038
  constructor(spawnDaemon = spawn2, processControl = { kill: (pid, signal) => process.kill(pid, signal) }, dependencies = {}) {
5039
5039
  this.spawnDaemon = spawnDaemon;
@@ -5075,6 +5075,9 @@ class DaemonManager {
5075
5075
  this.injectedLaunch = dependencies.directLaunch ?? dependencies.launchDescriptor;
5076
5076
  this.writePidMirror = dependencies.writePidMirror ?? writeLegacyPidMirror;
5077
5077
  this.httpRequest = dependencies.httpRequest ?? ((url, init) => fetch(url, init));
5078
+ this.startTimeoutMs = dependencies.startupTimeoutMs ?? 30000;
5079
+ if (!Number.isSafeInteger(this.startTimeoutMs) || this.startTimeoutMs <= 0)
5080
+ throw new Error("daemon startup timing is invalid");
5078
5081
  this.rpcTimeoutMs = dependencies.rpcTimeoutMs ?? 3000;
5079
5082
  this.forceWaitMs = dependencies.forceWaitMs ?? 1500;
5080
5083
  this.forceStop = dependencies.forceStop ?? ((metadata) => forceStopDaemon(metadata, {
@@ -5091,9 +5094,9 @@ class DaemonManager {
5091
5094
  throw new Error("daemon stop timing is invalid");
5092
5095
  if (dependencies.gracefulDeadlineMs !== undefined)
5093
5096
  this.stopTimeoutMs = dependencies.gracefulDeadlineMs;
5094
- ConfigPaths.ensureConfigDir();
5095
- ConfigPaths.ensureDataDir();
5096
- ConfigPaths.ensureLogsDir();
5097
+ fs2.mkdirSync(this.configDir, { recursive: true });
5098
+ fs2.mkdirSync(this.dataDirectory, { recursive: true });
5099
+ fs2.mkdirSync(this.logsDirectory, { recursive: true });
5097
5100
  }
5098
5101
  fileOptions() {
5099
5102
  return { runtimeDirectory: this.runtimeDirectory, platform: this.filePlatform, windowsAcl: this.windowsAcl };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jeffusion/bungee",
3
- "version": "5.6.1",
3
+ "version": "5.7.0",
4
4
  "description": "High-performance reverse proxy server CLI",
5
5
  "type": "module",
6
6
  "bin": {
@@ -13,8 +13,8 @@
13
13
  "test": "bun test"
14
14
  },
15
15
  "dependencies": {
16
- "@jeffusion/bungee-core": "^5.6.1",
17
- "@jeffusion/bungee-types": "^5.6.1",
16
+ "@jeffusion/bungee-core": "^5.7.0",
17
+ "@jeffusion/bungee-types": "^5.7.0",
18
18
  "cli-progress": "^3.12.0",
19
19
  "commander": "^14.0.1"
20
20
  },