@rivetkit/rivetkit-napi 2.3.9 → 2.3.11-rc.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 +6 -20
- package/index.js +1 -3
- package/package.json +9 -9
package/index.d.ts
CHANGED
|
@@ -44,6 +44,11 @@ export interface JsInspectorSnapshot {
|
|
|
44
44
|
export interface JsActorRuntimeSocketEndpointInfo {
|
|
45
45
|
path: string
|
|
46
46
|
}
|
|
47
|
+
export interface JsHttpResponse {
|
|
48
|
+
status?: number
|
|
49
|
+
headers?: Record<string, string>
|
|
50
|
+
body?: Buffer
|
|
51
|
+
}
|
|
47
52
|
export interface JsQueueSendResult {
|
|
48
53
|
status: string
|
|
49
54
|
response?: Buffer
|
|
@@ -141,12 +146,6 @@ export interface JsSqliteVfsMetrics {
|
|
|
141
146
|
writeBufferDirtyPages: number
|
|
142
147
|
dbSizePages: number
|
|
143
148
|
}
|
|
144
|
-
export interface JsHttpResponse {
|
|
145
|
-
status?: number
|
|
146
|
-
headers?: Record<string, string>
|
|
147
|
-
body?: Buffer
|
|
148
|
-
stream?: boolean
|
|
149
|
-
}
|
|
150
149
|
export interface JsQueueNextOptions {
|
|
151
150
|
names?: Array<string>
|
|
152
151
|
timeoutMs?: number
|
|
@@ -224,8 +223,7 @@ export interface JsServerlessResponseHead {
|
|
|
224
223
|
export interface JsApplicationResponse {
|
|
225
224
|
status: number
|
|
226
225
|
headers: Record<string, string>
|
|
227
|
-
body
|
|
228
|
-
stream?: boolean
|
|
226
|
+
body: Buffer
|
|
229
227
|
}
|
|
230
228
|
export interface JsRegistryRouteResponse {
|
|
231
229
|
status: number
|
|
@@ -368,18 +366,6 @@ export declare class JsSqliteTransaction {
|
|
|
368
366
|
commit(): Promise<void>
|
|
369
367
|
rollback(): Promise<void>
|
|
370
368
|
}
|
|
371
|
-
/** JavaScript-facing writer for a streaming actor HTTP response. */
|
|
372
|
-
export declare class HttpResponseBodyStream {
|
|
373
|
-
cancelled(): Promise<void>
|
|
374
|
-
write(chunk: Buffer): Promise<void>
|
|
375
|
-
end(): Promise<void>
|
|
376
|
-
error(message: string): Promise<void>
|
|
377
|
-
}
|
|
378
|
-
/** JavaScript-facing reader for a streaming actor HTTP request. */
|
|
379
|
-
export declare class HttpRequestBodyStream {
|
|
380
|
-
read(): Promise<Buffer | null>
|
|
381
|
-
cancel(): Promise<void>
|
|
382
|
-
}
|
|
383
369
|
export declare class Kv {
|
|
384
370
|
get(key: Buffer): Promise<Buffer | null>
|
|
385
371
|
put(key: Buffer, value: Buffer): Promise<void>
|
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, NapiActorFactory, CancellationToken, ConnHandle, JsNativeDatabase, JsSqliteTransaction,
|
|
313
|
+
const { ActorContext, decodeInspectorRequest, encodeInspectorResponse, NapiActorFactory, CancellationToken, ConnHandle, JsNativeDatabase, JsSqliteTransaction, Kv, Queue, QueueMessage, CoreRegistry, Schedule, WebSocket } = nativeBinding
|
|
314
314
|
|
|
315
315
|
module.exports.ActorContext = ActorContext
|
|
316
316
|
module.exports.decodeInspectorRequest = decodeInspectorRequest
|
|
@@ -320,8 +320,6 @@ module.exports.CancellationToken = CancellationToken
|
|
|
320
320
|
module.exports.ConnHandle = ConnHandle
|
|
321
321
|
module.exports.JsNativeDatabase = JsNativeDatabase
|
|
322
322
|
module.exports.JsSqliteTransaction = JsSqliteTransaction
|
|
323
|
-
module.exports.HttpResponseBodyStream = HttpResponseBodyStream
|
|
324
|
-
module.exports.HttpRequestBodyStream = HttpRequestBodyStream
|
|
325
323
|
module.exports.Kv = Kv
|
|
326
324
|
module.exports.Queue = Queue
|
|
327
325
|
module.exports.QueueMessage = QueueMessage
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rivetkit/rivetkit-napi",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.11-rc.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",
|
|
@@ -44,15 +44,15 @@
|
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
46
|
"@napi-rs/cli": "^2.18.4",
|
|
47
|
-
"@rivetkit/engine-envoy-protocol": "2.3.
|
|
47
|
+
"@rivetkit/engine-envoy-protocol": "2.3.11-rc.1"
|
|
48
48
|
},
|
|
49
49
|
"optionalDependencies": {
|
|
50
|
-
"@rivetkit/rivetkit-napi-darwin-arm64": "2.3.
|
|
51
|
-
"@rivetkit/rivetkit-napi-darwin-x64": "2.3.
|
|
52
|
-
"@rivetkit/rivetkit-napi-linux-arm64-gnu": "2.3.
|
|
53
|
-
"@rivetkit/rivetkit-napi-linux-arm64-musl": "2.3.
|
|
54
|
-
"@rivetkit/rivetkit-napi-linux-x64-gnu": "2.3.
|
|
55
|
-
"@rivetkit/rivetkit-napi-linux-x64-musl": "2.3.
|
|
56
|
-
"@rivetkit/rivetkit-napi-win32-x64-msvc": "2.3.
|
|
50
|
+
"@rivetkit/rivetkit-napi-darwin-arm64": "2.3.11-rc.1",
|
|
51
|
+
"@rivetkit/rivetkit-napi-darwin-x64": "2.3.11-rc.1",
|
|
52
|
+
"@rivetkit/rivetkit-napi-linux-arm64-gnu": "2.3.11-rc.1",
|
|
53
|
+
"@rivetkit/rivetkit-napi-linux-arm64-musl": "2.3.11-rc.1",
|
|
54
|
+
"@rivetkit/rivetkit-napi-linux-x64-gnu": "2.3.11-rc.1",
|
|
55
|
+
"@rivetkit/rivetkit-napi-linux-x64-musl": "2.3.11-rc.1",
|
|
56
|
+
"@rivetkit/rivetkit-napi-win32-x64-msvc": "2.3.11-rc.1"
|
|
57
57
|
}
|
|
58
58
|
}
|