billion-context-omp 0.2.0 → 0.2.2
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.
- package/dist/index.js +72 -15
- package/dist/index.js.map +1 -1
- package/dist/instance-guard.d.ts +13 -0
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface InstanceMarker {
|
|
2
|
+
path: string;
|
|
3
|
+
version: string | null;
|
|
4
|
+
pid: number;
|
|
5
|
+
ts: number;
|
|
6
|
+
}
|
|
7
|
+
/** Returns the conflicting instance's marker when a dual load is detected. */
|
|
8
|
+
export declare function detectDualInstance(selfPath: string, now?: number): InstanceMarker | undefined;
|
|
9
|
+
export declare function stampInstance(selfPath: string, version: string | null, pid?: number, now?: number): void;
|
|
10
|
+
/** Stamp ourselves; report a conflicting live marker if one exists. Stamp
|
|
11
|
+
* order matters: the OTHER instance's stamp may be from this same process
|
|
12
|
+
* (both loaded), so we overwrite only after reading the conflict. */
|
|
13
|
+
export declare function stampAndDetect(selfPath: string, version: string | null, now?: number): InstanceMarker | undefined;
|
package/package.json
CHANGED