@tinyshed/tinystore 0.1.0-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.
Files changed (100) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +262 -0
  3. package/bin/tinystore.js +50 -0
  4. package/dist/background.d.ts +30 -0
  5. package/dist/background.js +93 -0
  6. package/dist/blobs.d.ts +98 -0
  7. package/dist/blobs.js +299 -0
  8. package/dist/cancel.d.ts +14 -0
  9. package/dist/cancel.js +22 -0
  10. package/dist/clock.d.ts +21 -0
  11. package/dist/clock.js +35 -0
  12. package/dist/config.d.ts +60 -0
  13. package/dist/config.js +417 -0
  14. package/dist/connection.d.ts +78 -0
  15. package/dist/connection.js +405 -0
  16. package/dist/console.d.ts +48 -0
  17. package/dist/console.js +195 -0
  18. package/dist/errors.d.ts +103 -0
  19. package/dist/errors.js +158 -0
  20. package/dist/handles.d.ts +28 -0
  21. package/dist/handles.js +37 -0
  22. package/dist/index.d.ts +21 -0
  23. package/dist/index.js +7 -0
  24. package/dist/jobs.d.ts +304 -0
  25. package/dist/jobs.js +684 -0
  26. package/dist/kv.d.ts +283 -0
  27. package/dist/kv.js +815 -0
  28. package/dist/limiter.d.ts +45 -0
  29. package/dist/limiter.js +68 -0
  30. package/dist/logger.d.ts +96 -0
  31. package/dist/logger.js +243 -0
  32. package/dist/metrics.d.ts +249 -0
  33. package/dist/metrics.js +610 -0
  34. package/dist/once.d.ts +31 -0
  35. package/dist/once.js +116 -0
  36. package/dist/quota.d.ts +44 -0
  37. package/dist/quota.js +98 -0
  38. package/dist/records.d.ts +182 -0
  39. package/dist/records.js +346 -0
  40. package/dist/runtime/bun.d.ts +2 -0
  41. package/dist/runtime/bun.js +164 -0
  42. package/dist/runtime/node.d.ts +2 -0
  43. package/dist/runtime/node.js +157 -0
  44. package/dist/runtime/shared.d.ts +25 -0
  45. package/dist/runtime/shared.js +45 -0
  46. package/dist/runtime.d.ts +48 -0
  47. package/dist/runtime.js +4 -0
  48. package/dist/schema.d.ts +39 -0
  49. package/dist/schema.js +21 -0
  50. package/dist/session.d.ts +120 -0
  51. package/dist/session.js +546 -0
  52. package/dist/sql.d.ts +121 -0
  53. package/dist/sql.js +342 -0
  54. package/dist/store.d.ts +103 -0
  55. package/dist/store.js +153 -0
  56. package/dist/time.d.ts +35 -0
  57. package/dist/time.js +44 -0
  58. package/dist/trace.d.ts +18 -0
  59. package/dist/trace.js +22 -0
  60. package/dist/wire/codec.d.ts +90 -0
  61. package/dist/wire/codec.js +383 -0
  62. package/dist/wire/frame.d.ts +41 -0
  63. package/dist/wire/frame.js +102 -0
  64. package/dist/wire/messages.d.ts +1403 -0
  65. package/dist/wire/messages.js +472 -0
  66. package/dist/wire/msgpack.d.ts +93 -0
  67. package/dist/wire/msgpack.js +680 -0
  68. package/package.json +40 -0
  69. package/src/background.ts +108 -0
  70. package/src/blobs.ts +437 -0
  71. package/src/cancel.ts +26 -0
  72. package/src/clock.ts +45 -0
  73. package/src/config.ts +501 -0
  74. package/src/connection.ts +512 -0
  75. package/src/console.ts +228 -0
  76. package/src/errors.ts +211 -0
  77. package/src/handles.ts +68 -0
  78. package/src/index.ts +92 -0
  79. package/src/jobs.ts +963 -0
  80. package/src/kv.ts +1093 -0
  81. package/src/limiter.ts +99 -0
  82. package/src/logger.ts +326 -0
  83. package/src/metrics.ts +896 -0
  84. package/src/once.ts +142 -0
  85. package/src/quota.ts +137 -0
  86. package/src/records.ts +537 -0
  87. package/src/runtime/bun.ts +190 -0
  88. package/src/runtime/node.ts +177 -0
  89. package/src/runtime/shared.ts +61 -0
  90. package/src/runtime.ts +57 -0
  91. package/src/schema.ts +69 -0
  92. package/src/session.ts +665 -0
  93. package/src/sql.ts +478 -0
  94. package/src/store.ts +219 -0
  95. package/src/time.ts +87 -0
  96. package/src/trace.ts +32 -0
  97. package/src/wire/codec.ts +445 -0
  98. package/src/wire/frame.ts +139 -0
  99. package/src/wire/messages.ts +562 -0
  100. package/src/wire/msgpack.ts +712 -0
@@ -0,0 +1,562 @@
1
+ // Every message of docs/wire.md, by the names its tables give each field.
2
+ // messages.json holds a vector of each, which test/wire.test.ts reads through
3
+ // these declarations.
4
+
5
+ import {
6
+ bin,
7
+ bool,
8
+ floats,
9
+ int,
10
+ int64,
11
+ ints,
12
+ key,
13
+ kvValue,
14
+ list,
15
+ message,
16
+ names,
17
+ nullable,
18
+ sqlValue,
19
+ str,
20
+ text,
21
+ uint,
22
+ } from './codec.ts'
23
+
24
+ export const methods = {
25
+ 'server.stop': 0x0001,
26
+ 'server.clock': 0x0002,
27
+ 'server.backup': 0x0003,
28
+ 'kv.open': 0x0101,
29
+ 'kv.get': 0x0102,
30
+ 'kv.has': 0x0103,
31
+ 'kv.set': 0x0104,
32
+ 'kv.delete': 0x0105,
33
+ 'kv.take': 0x0106,
34
+ 'kv.touch': 0x0107,
35
+ 'kv.add': 0x0108,
36
+ 'kv.max': 0x0109,
37
+ 'kv.clear': 0x010a,
38
+ 'kv.batch': 0x010b,
39
+ 'kv.view': 0x010c,
40
+ 'kv.scan': 0x010d,
41
+ 'kv.allow': 0x010e,
42
+ 'kv.configure': 0x010f,
43
+ 'kv.watch': 0x0110,
44
+ 'kv.run': 0x0111,
45
+ 'kv.usage': 0x0112,
46
+ 'kv.refund': 0x0113,
47
+ 'jobs.open': 0x0201,
48
+ 'jobs.enqueue': 0x0202,
49
+ 'jobs.update': 0x0203,
50
+ 'jobs.cancel': 0x0204,
51
+ 'jobs.get': 0x0205,
52
+ 'jobs.claim': 0x0206,
53
+ 'jobs.settle': 0x0207,
54
+ 'jobs.scan': 0x0208,
55
+ 'jobs.work': 0x0209,
56
+ 'jobs.watch': 0x020a,
57
+ 'jobs.step': 0x020b,
58
+ 'jobs.keep': 0x020c,
59
+ 'blobs.open': 0x0301,
60
+ 'blobs.stat': 0x0302,
61
+ 'blobs.delete': 0x0303,
62
+ 'blobs.copy': 0x0304,
63
+ 'blobs.move': 0x0305,
64
+ 'blobs.usage': 0x0306,
65
+ 'blobs.clear': 0x0307,
66
+ 'blobs.scan': 0x0308,
67
+ 'blobs.put': 0x0309,
68
+ 'blobs.get': 0x030a,
69
+ 'sql.open': 0x0401,
70
+ 'sql.exec': 0x0402,
71
+ 'sql.query': 0x0403,
72
+ 'sql.batch': 0x0404,
73
+ 'records.append': 0x0501,
74
+ 'records.read': 0x0502,
75
+ 'records.follow': 0x0503,
76
+ 'records.lines': 0x0504,
77
+ 'records.damaged': 0x0505,
78
+ 'records.drop': 0x0506,
79
+ 'metrics.ingest': 0x0601,
80
+ 'metrics.read': 0x0602,
81
+ 'metrics.aggregate': 0x0603,
82
+ 'metrics.drop': 0x0604,
83
+ 'metrics.explain': 0x0605,
84
+ } as const
85
+
86
+ export type Method = keyof typeof methods
87
+
88
+ export const Hello = message('hello', {
89
+ protocol: [1, uint],
90
+ client: [2, str],
91
+ token: [3, str],
92
+ maxBody: [4, uint],
93
+ streamCredit: [5, uint],
94
+ challenge: [6, bin],
95
+ })
96
+
97
+ export const Welcome = message('welcome', {
98
+ protocol: [1, uint],
99
+ server: [2, str],
100
+ instance: [3, bin],
101
+ capability: [4, str],
102
+ maxBody: [5, uint],
103
+ inFlight: [6, uint],
104
+ connectionCredit: [7, uint],
105
+ streamCredit: [8, uint],
106
+ engines: [9, list(str)],
107
+ now: [10, int],
108
+ proof: [11, bin],
109
+ })
110
+
111
+ export const GoAway = message('goaway', { code: [1, str], message: [2, str] })
112
+
113
+ export const Failure = message('error', {
114
+ code: [1, str],
115
+ message: [2, str],
116
+ what: [3, names(text)],
117
+ })
118
+
119
+ export const Handle = message('handle', { handle: [1, uint] })
120
+
121
+ export const Empty = message('empty', {})
122
+
123
+ export const Clock = message('clock', { at: [1, int], advance: [2, uint] })
124
+
125
+ export const KvWindow = message('kv.window', { name: [1, str], limit: [2, uint], per: [3, uint] })
126
+
127
+ export const KvBucket = message('kv.bucket', {
128
+ name: [1, str],
129
+ counters: [2, bool],
130
+ defaultTtl: [3, uint],
131
+ sliding: [4, uint],
132
+ loseAtMost: [5, uint],
133
+ config: [6, bool],
134
+ rate: [7, uint],
135
+ per: [8, uint],
136
+ burst: [9, uint],
137
+ once: [10, bool],
138
+ windows: [11, list(KvWindow)],
139
+ })
140
+
141
+ const kvCall = {
142
+ handle: [1, uint],
143
+ owners: [2, list(key)],
144
+ key: [3, key],
145
+ value: [4, kvValue],
146
+ ttl: [5, uint],
147
+ expireAt: [6, int],
148
+ ifVersion: [7, bin],
149
+ ifAbsent: [8, bool],
150
+ n: [9, int64],
151
+ after: [10, key],
152
+ limit: [11, uint],
153
+ } as const
154
+
155
+ export const KvCall = message('kv.call', kvCall)
156
+
157
+ export const KvOperation = message('kv.operation', { method: [0, uint], ...kvCall })
158
+
159
+ export const KvCalls = message('kv.calls', { calls: [1, list(KvOperation)] })
160
+
161
+ export const KvEntry = message('kv.entry', {
162
+ found: [1, bool],
163
+ value: [2, kvValue],
164
+ version: [3, bin],
165
+ expires: [4, int],
166
+ key: [5, key],
167
+ })
168
+
169
+ export const KvResults = message('kv.results', { entries: [1, list(KvEntry)] })
170
+
171
+ export const KvPage = message('kv.page', { more: [1, bool], after: [2, key] })
172
+
173
+ export const KvWindowUsage = message('kv.window usage', {
174
+ name: [1, str],
175
+ used: [2, uint],
176
+ limit: [3, uint],
177
+ left: [4, uint],
178
+ resetAt: [5, int],
179
+ })
180
+
181
+ export const KvAllowance = message('kv.allowance', {
182
+ ok: [1, bool],
183
+ left: [2, uint],
184
+ retryAfter: [3, uint],
185
+ windows: [4, list(KvWindowUsage)],
186
+ })
187
+
188
+ export const KvConfigure = message('kv.configure', {
189
+ handle: [1, uint],
190
+ set: [2, list(str)],
191
+ reset: [3, list(str)],
192
+ })
193
+
194
+ export const KvKept = message('kv.kept', { changes: [1, uint], fields: [2, list(str)] })
195
+
196
+ export const JobsRepeat = message('jobs.repeat', {
197
+ cron: [1, str],
198
+ zone: [2, str],
199
+ every: [3, uint],
200
+ })
201
+
202
+ export const JobsQueue = message('jobs.queue', {
203
+ name: [1, str],
204
+ lease: [2, uint],
205
+ maxAttempts: [3, uint],
206
+ backoffFirst: [4, uint],
207
+ backoffMost: [5, uint],
208
+ maxWaiting: [6, uint],
209
+ keepFailed: [7, uint],
210
+ keepDone: [8, uint],
211
+ schedule: [9, JobsRepeat],
212
+ maxRunning: [10, uint],
213
+ in: [11, str],
214
+ })
215
+
216
+ const jobsJob = {
217
+ value: [1, str],
218
+ key: [2, str],
219
+ at: [3, int],
220
+ after: [4, uint],
221
+ repeat: [5, JobsRepeat],
222
+ } as const
223
+
224
+ export const JobsJob = message('jobs.job', jobsJob)
225
+
226
+ export const JobsBatch = message('jobs.batch', { handle: [1, uint], jobs: [2, list(JobsJob)] })
227
+
228
+ export const JobsChange = message('jobs.change', { ...jobsJob, handle: [6, uint] })
229
+
230
+ export const JobsKey = message('jobs.key', { handle: [1, uint], key: [2, str] })
231
+
232
+ export const JobsAnswer = message('jobs.answer', {
233
+ job: [1, uint],
234
+ name: [2, str],
235
+ answer: [3, str],
236
+ })
237
+
238
+ export const JobsKept = message('jobs.kept', { found: [1, bool], answer: [2, str] })
239
+
240
+ export const JobsEntry = message('jobs.entry', {
241
+ found: [1, bool],
242
+ key: [2, str],
243
+ value: [3, str],
244
+ at: [4, int],
245
+ attempt: [5, uint],
246
+ state: [6, uint],
247
+ err: [7, str],
248
+ repeat: [8, str],
249
+ ahead: [9, uint],
250
+ progress: [10, str],
251
+ ran: [11, int],
252
+ took: [12, uint],
253
+ })
254
+
255
+ export const JobsLease = message('jobs.lease', { handle: [1, uint], lease: [2, uint] })
256
+
257
+ export const JobsHeld = message('jobs.held', {
258
+ found: [1, bool],
259
+ job: [2, uint],
260
+ key: [3, str],
261
+ value: [4, str],
262
+ at: [5, int],
263
+ attempt: [6, uint],
264
+ cancelled: [7, bool],
265
+ })
266
+
267
+ export const JobsOutcome = message('jobs.outcome', {
268
+ job: [1, uint],
269
+ how: [2, uint],
270
+ err: [3, str],
271
+ at: [4, int],
272
+ after: [5, uint],
273
+ progress: [6, str],
274
+ })
275
+
276
+ export const JobsOutcomes = message('jobs.outcomes', { outcomes: [1, list(JobsOutcome)] })
277
+
278
+ export const JobsSettled = message('jobs.settled', { settled: [1, list(nullable(Failure))] })
279
+
280
+ export const JobsQuery = message('jobs.query', {
281
+ handle: [1, uint],
282
+ prefix: [2, str],
283
+ state: [3, uint],
284
+ after: [4, str],
285
+ limit: [5, uint],
286
+ })
287
+
288
+ export const JobsPage = message('jobs.page', { more: [1, bool], after: [2, str] })
289
+
290
+ export const JobsWorkers = message('jobs.workers', {
291
+ handle: [1, uint],
292
+ workers: [2, uint],
293
+ timeout: [3, uint],
294
+ untilIdle: [4, bool],
295
+ cancels: [5, bool],
296
+ })
297
+
298
+ export const BlobsBucket = message('blobs.bucket', {
299
+ name: [1, str],
300
+ defaultTtl: [2, uint],
301
+ maxSize: [3, uint],
302
+ })
303
+
304
+ export const BlobsCall = message('blobs.call', {
305
+ handle: [1, uint],
306
+ owners: [2, list(key)],
307
+ key: [3, str],
308
+ to: [4, str],
309
+ contentType: [5, str],
310
+ meta: [6, names(text)],
311
+ ttl: [7, uint],
312
+ expireAt: [8, int],
313
+ size: [9, uint],
314
+ ifMatch: [10, str],
315
+ ifNoneMatch: [11, bool],
316
+ prefix: [12, str],
317
+ after: [13, str],
318
+ limit: [14, uint],
319
+ offset: [15, uint],
320
+ length: [16, uint],
321
+ })
322
+
323
+ export const BlobsObject = message('blobs.object', {
324
+ found: [1, bool],
325
+ key: [2, str],
326
+ size: [3, uint],
327
+ etag: [4, str],
328
+ contentType: [5, str],
329
+ modified: [6, int],
330
+ expires: [7, int],
331
+ meta: [8, names(text)],
332
+ })
333
+
334
+ export const BlobsTotal = message('blobs.total', { objects: [1, int], bytes: [2, int] })
335
+
336
+ export const BlobsPage = message('blobs.page', { more: [1, bool], after: [2, str] })
337
+
338
+ export const SqlMigration = message('sql.migration', { name: [1, str], text: [2, str] })
339
+
340
+ export const SqlDatabase = message('sql.database', {
341
+ name: [1, str],
342
+ migrations: [2, list(SqlMigration)],
343
+ })
344
+
345
+ export const SqlStatement = message('sql.statement', {
346
+ handle: [1, uint],
347
+ sql: [2, str],
348
+ args: [3, list(sqlValue)],
349
+ named: [4, names(sqlValue)],
350
+ write: [5, bool],
351
+ rows: [6, bool],
352
+ })
353
+
354
+ export const SqlStatements = message('sql.statements', {
355
+ handle: [1, uint],
356
+ statements: [2, list(SqlStatement)],
357
+ read: [3, bool],
358
+ jobs: [4, list(JobsBatch)],
359
+ })
360
+
361
+ export const SqlDone = message('sql.done', { changes: [1, int], lastId: [2, int] })
362
+
363
+ export const SqlColumns = message('sql.columns', { columns: [1, list(str)] })
364
+
365
+ export const SqlRow = message('sql.row', { values: [1, list(sqlValue)] })
366
+
367
+ export const SqlResult = message('sql.result', {
368
+ changes: [1, int],
369
+ lastId: [2, int],
370
+ columns: [3, list(str)],
371
+ rows: [4, list(list(sqlValue))],
372
+ })
373
+
374
+ export const SqlResults = message('sql.results', { results: [1, list(SqlResult)] })
375
+
376
+ export const RecordsRecord = message('records.record', {
377
+ at: [1, int64],
378
+ stream: [2, text],
379
+ name: [3, text],
380
+ level: [4, int],
381
+ body: [5, text],
382
+ traceId: [6, bin],
383
+ spanId: [7, bin],
384
+ context: [8, list(text)],
385
+ attrs: [9, list(text)],
386
+ })
387
+
388
+ export const RecordsBatch = message('records.batch', { records: [1, list(RecordsRecord)] })
389
+
390
+ export const RecordsQuery = message('records.query', {
391
+ from: [1, int64],
392
+ to: [2, int64],
393
+ streams: [3, list(text)],
394
+ names: [4, list(text)],
395
+ minLevel: [5, int],
396
+ traceId: [6, bin],
397
+ attrs: [7, list(text)],
398
+ context: [8, list(text)],
399
+ newest: [9, bool],
400
+ limit: [10, uint],
401
+ budgetBlocks: [11, uint],
402
+ budgetBytes: [12, uint],
403
+ budgetRecords: [13, uint],
404
+ search: [14, str],
405
+ })
406
+
407
+ export const RecordsPage = message('records.page', {
408
+ more: [1, bool],
409
+ from: [2, int64],
410
+ to: [3, int64],
411
+ })
412
+
413
+ export const RecordsCursor = message('records.cursor', {
414
+ segment: [1, int],
415
+ row: [2, int],
416
+ limit: [3, uint],
417
+ expired: [4, uint],
418
+ })
419
+
420
+ export const RecordsStream = message('records.stream', { stream: [1, text] })
421
+
422
+ export const RecordsDamage = message('records.damage', {
423
+ stream: [1, text],
424
+ segment: [2, int],
425
+ headRow: [3, int],
426
+ from: [4, int64],
427
+ to: [5, int64],
428
+ reason: [6, str],
429
+ })
430
+
431
+ export const RecordsDamages = message('records.damages', { damages: [1, list(RecordsDamage)] })
432
+
433
+ export const MetricsSeries = message('metrics.series', {
434
+ labels: [1, names(str)],
435
+ kind: [2, str],
436
+ times: [3, ints],
437
+ values: [4, floats],
438
+ })
439
+
440
+ export const MetricsBatch = message('metrics.batch', { series: [1, list(MetricsSeries)] })
441
+
442
+ export const MetricsPlan = message('metrics.plan', {
443
+ series: [1, uint],
444
+ blocks: [2, uint],
445
+ summarized: [3, uint],
446
+ bytes: [4, uint],
447
+ decoded: [5, uint],
448
+ limitSeries: [6, uint],
449
+ limitBlocks: [7, uint],
450
+ limitBytes: [8, uint],
451
+ limitDecoded: [9, uint],
452
+ limitAnswered: [10, uint],
453
+ stops: [11, nullable(Failure)],
454
+ })
455
+
456
+ export const MetricsCondition = message('metrics.condition', {
457
+ label: [1, str],
458
+ kind: [2, str],
459
+ values: [3, list(str)],
460
+ })
461
+
462
+ export const MetricsRange = message('metrics.range', {
463
+ matchers: [1, names(str)],
464
+ from: [2, int64],
465
+ to: [3, int64],
466
+ limitSeries: [4, uint],
467
+ limitBlocks: [5, uint],
468
+ limitBytes: [6, uint],
469
+ limitDecoded: [7, uint],
470
+ limitAnswered: [8, uint],
471
+ width: [9, uint],
472
+ op: [10, str],
473
+ where: [11, list(MetricsCondition)],
474
+ by: [12, list(str)],
475
+ without: [13, list(str)],
476
+ })
477
+
478
+ export const MetricsBuckets = message('metrics.buckets', {
479
+ labels: [1, names(str)],
480
+ kind: [2, str],
481
+ from: [3, ints],
482
+ to: [4, ints],
483
+ count: [5, ints],
484
+ resets: [6, ints],
485
+ values: [7, floats],
486
+ flags: [8, bin],
487
+ })
488
+
489
+ export const MetricsLabels = message('metrics.labels', { labels: [1, names(str)] })
490
+
491
+ export const MetricsDropped = message('metrics.dropped', {
492
+ found: [1, bool],
493
+ unreadableGroups: [2, uint],
494
+ })
495
+
496
+ /** Every message by the name messages.json gives it. */
497
+ export const messages = {
498
+ hello: Hello,
499
+ welcome: Welcome,
500
+ goaway: GoAway,
501
+ error: Failure,
502
+ handle: Handle,
503
+ empty: Empty,
504
+ clock: Clock,
505
+ 'kv.bucket': KvBucket,
506
+ 'kv.call': KvCall,
507
+ 'kv.operation': KvOperation,
508
+ 'kv.calls': KvCalls,
509
+ 'kv.entry': KvEntry,
510
+ 'kv.results': KvResults,
511
+ 'kv.page': KvPage,
512
+ 'kv.allowance': KvAllowance,
513
+ 'kv.configure': KvConfigure,
514
+ 'kv.kept': KvKept,
515
+ 'jobs.queue': JobsQueue,
516
+ 'jobs.repeat': JobsRepeat,
517
+ 'jobs.job': JobsJob,
518
+ 'jobs.batch': JobsBatch,
519
+ 'jobs.change': JobsChange,
520
+ 'jobs.key': JobsKey,
521
+ 'jobs.answer': JobsAnswer,
522
+ 'jobs.kept': JobsKept,
523
+ 'jobs.entry': JobsEntry,
524
+ 'jobs.lease': JobsLease,
525
+ 'jobs.held': JobsHeld,
526
+ 'jobs.outcome': JobsOutcome,
527
+ 'jobs.outcomes': JobsOutcomes,
528
+ 'jobs.settled': JobsSettled,
529
+ 'jobs.query': JobsQuery,
530
+ 'jobs.page': JobsPage,
531
+ 'jobs.workers': JobsWorkers,
532
+ 'blobs.bucket': BlobsBucket,
533
+ 'blobs.call': BlobsCall,
534
+ 'blobs.object': BlobsObject,
535
+ 'blobs.total': BlobsTotal,
536
+ 'blobs.page': BlobsPage,
537
+ 'sql.database': SqlDatabase,
538
+ 'sql.migration': SqlMigration,
539
+ 'sql.statement': SqlStatement,
540
+ 'sql.statements': SqlStatements,
541
+ 'sql.done': SqlDone,
542
+ 'sql.columns': SqlColumns,
543
+ 'sql.row': SqlRow,
544
+ 'sql.result': SqlResult,
545
+ 'sql.results': SqlResults,
546
+ 'records.record': RecordsRecord,
547
+ 'records.batch': RecordsBatch,
548
+ 'records.query': RecordsQuery,
549
+ 'records.page': RecordsPage,
550
+ 'records.cursor': RecordsCursor,
551
+ 'records.stream': RecordsStream,
552
+ 'records.damage': RecordsDamage,
553
+ 'records.damages': RecordsDamages,
554
+ 'metrics.series': MetricsSeries,
555
+ 'metrics.batch': MetricsBatch,
556
+ 'metrics.range': MetricsRange,
557
+ 'metrics.condition': MetricsCondition,
558
+ 'metrics.plan': MetricsPlan,
559
+ 'metrics.buckets': MetricsBuckets,
560
+ 'metrics.labels': MetricsLabels,
561
+ 'metrics.dropped': MetricsDropped,
562
+ } as const