@dpuse/dpuse-shared 1.0.159 → 1.0.161
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.
|
@@ -3,7 +3,7 @@ import { Component } from '../..';
|
|
|
3
3
|
import { EngineConnectorActionOptions } from '../engine';
|
|
4
4
|
import { LocalisedConfig } from '../../../locale';
|
|
5
5
|
import { ToolConfig } from '../tool';
|
|
6
|
-
import { ConnectionDescriptionConfig, ConnectionNodeConfig, ObjectColumnConfig } from '../../connection';
|
|
6
|
+
import { ConnectionConfig, ConnectionDescriptionConfig, ConnectionNodeConfig, ObjectColumnConfig } from '../../connection';
|
|
7
7
|
import { connectorActionNameSchema, connectorCategoryConfigSchema, connectorConfigSchema, connectorItemTypeConfigSchema, connectorItemTypeIdSchema, connectorUsageConfigSchema, connectorUsageIdSchema } from './connectorConfig.schema';
|
|
8
8
|
import { ContentAuditConfig, DataFormatId, InferenceRecord, InferenceSummary, ParsingRecord, PreviewConfig, ValueDelimiterId } from '../../dataView';
|
|
9
9
|
export { connectorConfigSchema } from './connectorConfig.schema';
|
|
@@ -29,7 +29,8 @@ export interface ConnectorInterface extends Component {
|
|
|
29
29
|
queryRecords?(options: QueryRecordsOptions): Promise<QueryRecordsResult>;
|
|
30
30
|
removeRecords?(options: RemoveRecordsOptions): Promise<void>;
|
|
31
31
|
retrieveChunks?(options: RetrieveChunksOptions, chunk: (data: Uint8Array) => void, complete: () => void): Promise<void>;
|
|
32
|
-
retrieveRecords?(options: RetrieveRecordsOptions, chunk: (typeId: RecordRetrievalTypeId, records: Record<string, unknown>[] | ParsingRecord[]) => void
|
|
32
|
+
retrieveRecords?(options: RetrieveRecordsOptions, chunk: (typeId: RecordRetrievalTypeId, records: Record<string, unknown>[] | ParsingRecord[]) => void | Promise<void>, // A returned promise holds the read back until it settles.
|
|
33
|
+
complete: (result: RetrieveRecordsSummary) => void): Promise<void>;
|
|
33
34
|
upsertRecords?(options: UpsertRecordsOptions): Promise<void>;
|
|
34
35
|
}
|
|
35
36
|
export type ConnectorActionName = InferOutput<typeof connectorActionNameSchema>;
|
|
@@ -117,6 +118,11 @@ export interface LoadObjectRecordsOptions extends EngineConnectorActionOptions {
|
|
|
117
118
|
export interface LoadObjectRecordsResult {
|
|
118
119
|
recordCount: number;
|
|
119
120
|
}
|
|
121
|
+
export interface EngineLoadObjectRecordsOptions extends LoadObjectRecordsOptions {
|
|
122
|
+
hasHeaders: boolean;
|
|
123
|
+
sourceConnectionConfig: ConnectionConfig | LocalisedConfig<ConnectionConfig>;
|
|
124
|
+
sourceOptions: RetrieveRecordsOptions;
|
|
125
|
+
}
|
|
120
126
|
export type StoreRecord = StoreValue[];
|
|
121
127
|
export type StoreValue = bigint | boolean | Date | number | string | null;
|
|
122
128
|
export type OpenStoreOptions = EngineConnectorActionOptions;
|
|
@@ -20,7 +20,7 @@ export declare function buildPreviewConfig(input: {
|
|
|
20
20
|
toolConfigs: ToolConfig[];
|
|
21
21
|
}): Promise<PreviewConfig>;
|
|
22
22
|
export declare function retrieveRecordsWithParser(input: {
|
|
23
|
-
chunk: (typeId: RecordRetrievalTypeId, records: ParsingRecord[]) => void
|
|
23
|
+
chunk: (typeId: RecordRetrievalTypeId, records: ParsingRecord[]) => void | Promise<void>;
|
|
24
24
|
options: RetrieveRecordsOptions;
|
|
25
25
|
signal: AbortSignal;
|
|
26
26
|
stream: ReadableStream<Uint8Array>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dpuse/dpuse-shared",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.161",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Common constants, types and utilities used across DPUse projects.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -60,13 +60,13 @@
|
|
|
60
60
|
"check:browsers": "node scripts/checkBrowserDecoding.ts"
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"file-type": "^22.
|
|
63
|
+
"file-type": "^22.3.0",
|
|
64
64
|
"valibot": "^1.5.0"
|
|
65
65
|
},
|
|
66
66
|
"devDependencies": {
|
|
67
|
-
"@dpuse/dpuse-development": "^1.0.
|
|
67
|
+
"@dpuse/dpuse-development": "^1.0.141",
|
|
68
68
|
"@dpuse/eslint-config-dpuse": "^1.0.145",
|
|
69
|
-
"@types/node": "^26.6.
|
|
69
|
+
"@types/node": "^26.6.6",
|
|
70
70
|
"@vitest/coverage-v8": "^5.0.5",
|
|
71
71
|
"eslint": "^10.13.0",
|
|
72
72
|
"fallow": "^3.37.0",
|