@rivetkit/rivetkit-napi 2.3.30 → 3.0.0-preview.1
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/index.d.ts +25 -2
- package/index.js +2 -1
- package/package.json +8 -9
package/index.d.ts
CHANGED
|
@@ -88,7 +88,8 @@ export interface JsInspectorTabEntry {
|
|
|
88
88
|
* surface is subject to change without notice.
|
|
89
89
|
*/
|
|
90
90
|
export interface JsSqliteProfilingConfig {
|
|
91
|
-
|
|
91
|
+
queries?: Array<string>
|
|
92
|
+
fingerprints?: Array<string>
|
|
92
93
|
maxTrackedStatementFingerprints?: number
|
|
93
94
|
maxTrackedTransactionFingerprints?: number
|
|
94
95
|
maxPrometheusSeries?: number
|
|
@@ -229,6 +230,7 @@ export interface JsServeConfig {
|
|
|
229
230
|
engineBinaryPath?: string
|
|
230
231
|
startServices?: boolean
|
|
231
232
|
servicesBinaryPath?: string
|
|
233
|
+
engineSpawn?: boolean
|
|
232
234
|
engineHost?: string
|
|
233
235
|
enginePort?: number
|
|
234
236
|
handleInspectorHttpInRuntime?: boolean
|
|
@@ -440,7 +442,28 @@ export declare class CancellationToken {
|
|
|
440
442
|
constructor()
|
|
441
443
|
aborted(): boolean
|
|
442
444
|
cancel(): void
|
|
443
|
-
|
|
445
|
+
/**
|
|
446
|
+
* Calls `callback` once when the token is cancelled.
|
|
447
|
+
*
|
|
448
|
+
* The returned listener must be released when the caller stops caring
|
|
449
|
+
* about cancellation. Releasing ends the waiting task and frees the
|
|
450
|
+
* threadsafe function, which otherwise stays alive (with its libuv handle
|
|
451
|
+
* and JS closure) until the token is cancelled.
|
|
452
|
+
*/
|
|
453
|
+
onCancelled(callback: (...args: any[]) => any): CancellationListener
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* Registration returned by `CancellationToken.onCancelled`.
|
|
457
|
+
*
|
|
458
|
+
* Dropping the JS object does not release the listener, because the callback
|
|
459
|
+
* must still fire if the caller keeps no reference to the registration.
|
|
460
|
+
*/
|
|
461
|
+
export declare class CancellationListener {
|
|
462
|
+
/**
|
|
463
|
+
* Stops waiting for cancellation without calling the callback.
|
|
464
|
+
* Idempotent, and a no-op after the callback has fired.
|
|
465
|
+
*/
|
|
466
|
+
release(): void
|
|
444
467
|
}
|
|
445
468
|
export declare class ConnHandle {
|
|
446
469
|
id(): string
|
package/index.js
CHANGED
|
@@ -310,7 +310,7 @@ if (!nativeBinding) {
|
|
|
310
310
|
throw new Error(`Failed to load native binding`)
|
|
311
311
|
}
|
|
312
312
|
|
|
313
|
-
const { ActorContext, decodeInspectorRequest, encodeInspectorResponse, OutboundCall, WorkflowSpan, WorkflowStepSpan, NapiActorFactory, CancellationToken, ConnHandle, JsNativeDatabase, JsSqliteTransaction, JsActorStateTransaction, HttpResponseBodyStream, HttpRequestBodyStream, Kv, Queue, QueueMessage, CoreRegistry, Schedule, WebSocket, setTelemetryLogSink, shutdownTelemetry } = nativeBinding
|
|
313
|
+
const { ActorContext, decodeInspectorRequest, encodeInspectorResponse, OutboundCall, WorkflowSpan, WorkflowStepSpan, NapiActorFactory, CancellationToken, CancellationListener, ConnHandle, JsNativeDatabase, JsSqliteTransaction, JsActorStateTransaction, HttpResponseBodyStream, HttpRequestBodyStream, Kv, Queue, QueueMessage, CoreRegistry, Schedule, WebSocket, setTelemetryLogSink, shutdownTelemetry } = nativeBinding
|
|
314
314
|
|
|
315
315
|
module.exports.ActorContext = ActorContext
|
|
316
316
|
module.exports.decodeInspectorRequest = decodeInspectorRequest
|
|
@@ -320,6 +320,7 @@ module.exports.WorkflowSpan = WorkflowSpan
|
|
|
320
320
|
module.exports.WorkflowStepSpan = WorkflowStepSpan
|
|
321
321
|
module.exports.NapiActorFactory = NapiActorFactory
|
|
322
322
|
module.exports.CancellationToken = CancellationToken
|
|
323
|
+
module.exports.CancellationListener = CancellationListener
|
|
323
324
|
module.exports.ConnHandle = ConnHandle
|
|
324
325
|
module.exports.JsNativeDatabase = JsNativeDatabase
|
|
325
326
|
module.exports.JsSqliteTransaction = JsSqliteTransaction
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rivetkit/rivetkit-napi",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0-preview.1",
|
|
4
4
|
"description": "Native N-API addon for RivetKit providing envoy client and SQLite access",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "index.js",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"build:embed": "node scripts/build.mjs"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@rivetkit/engine-envoy-protocol": "
|
|
46
|
+
"@rivetkit/engine-envoy-protocol": "3.0.0-preview.1"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@napi-rs/cli": "^2.18.4"
|
|
@@ -54,12 +54,11 @@
|
|
|
54
54
|
"directory": "rivetkit-typescript/packages/rivetkit-napi"
|
|
55
55
|
},
|
|
56
56
|
"optionalDependencies": {
|
|
57
|
-
"@rivetkit/rivetkit-napi-darwin-arm64": "
|
|
58
|
-
"@rivetkit/rivetkit-napi-darwin-x64": "
|
|
59
|
-
"@rivetkit/rivetkit-napi-linux-arm64-gnu": "
|
|
60
|
-
"@rivetkit/rivetkit-napi-linux-arm64-musl": "
|
|
61
|
-
"@rivetkit/rivetkit-napi-linux-x64-gnu": "
|
|
62
|
-
"@rivetkit/rivetkit-napi-linux-x64-musl": "
|
|
63
|
-
"@rivetkit/rivetkit-napi-win32-x64-msvc": "2.3.30"
|
|
57
|
+
"@rivetkit/rivetkit-napi-darwin-arm64": "3.0.0-preview.1",
|
|
58
|
+
"@rivetkit/rivetkit-napi-darwin-x64": "3.0.0-preview.1",
|
|
59
|
+
"@rivetkit/rivetkit-napi-linux-arm64-gnu": "3.0.0-preview.1",
|
|
60
|
+
"@rivetkit/rivetkit-napi-linux-arm64-musl": "3.0.0-preview.1",
|
|
61
|
+
"@rivetkit/rivetkit-napi-linux-x64-gnu": "3.0.0-preview.1",
|
|
62
|
+
"@rivetkit/rivetkit-napi-linux-x64-musl": "3.0.0-preview.1"
|
|
64
63
|
}
|
|
65
64
|
}
|