@milaboratories/pl-model-middle-layer 1.29.2 → 1.30.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/dist/block_meta/block_description.d.ts +128 -128
- package/dist/block_meta/block_id.d.ts +4 -4
- package/dist/block_meta/block_manifest.d.ts +336 -336
- package/dist/block_meta/block_meta.d.ts +72 -72
- package/dist/block_meta/content_types.d.ts +8 -8
- package/dist/block_registry/block_pack_spec.d.ts +16 -16
- package/dist/block_registry/overview.d.ts +1524 -1524
- package/dist/pframe/internal_api/api_factory.cjs.map +1 -1
- package/dist/pframe/internal_api/api_factory.d.ts +43 -20
- package/dist/pframe/internal_api/api_factory.d.ts.map +1 -1
- package/dist/pframe/internal_api/api_factory.js.map +1 -1
- package/dist/pframe/internal_api/index.d.ts +3 -3
- package/dist/pframe/internal_api/pframe.d.ts +9 -9
- package/dist/pframe/internal_api/pframe.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/pframe/internal_api/api_factory.ts +45 -20
- package/src/pframe/internal_api/pframe.ts +8 -8
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api_factory.cjs","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"sourcesContent":["import type {\n AxisValueType,\n BinaryPartitionedDataInfo,\n Branded,\n ColumnValueType,\n JsonDataInfo,\n JsonPartitionedDataInfo,\n ParquetChunk,\n ParquetPartitionedDataInfo,\n PObjectId,\n} from \"@milaboratories/pl-model-common\";\nimport type { HttpServerInfo } from \"./http_helpers\";\n\n/** PColumn spec file extension */\nexport const SpecExtension = \".spec\" as const;\n\n/** PColumn data info file extension */\nexport const DataInfoExtension = \".datainfo\" as const;\n\n/** Abstract identifier of a data blob that can be requested from the storage backend */\nexport type PFrameBlobId = Branded<string, \"PFrameInternal.PFrameBlobId\">;\n\n/** Path of the file containing requested data (blob). This path is returned by\n * {@link BlobPathResolver} as soon as blob materialized in the file system. */\nexport type FilePath = string;\n\n/** Data source allows PFrame to retrieve the data blobs for columns with assigned data info. */\nexport interface PFrameDataSourceV2 {\n /**\n * PFrame may notify storage backend about its plans to use particular blobs in the future.\n * Storage backend will do its best to preload specified blob so the subsequent\n * {@link resolveBlob} will quickly return preloaded file path.\n */\n preloadBlob(blobIds: PFrameBlobId[]): Promise<void>;\n\n /** Returns raw blob data given the blob id from {@link DataInfo}. */\n resolveBlobContent(blobId: PFrameBlobId): Promise<Uint8Array>;\n\n /**\n * Parquet HTTP(S) server connection settings, {@link HttpHelpers.createHttpServer}\n * When not provided, parquet BlobIds would be treated as local file paths.\n */\n parquetServer?: HttpServerInfo;\n}\n\n/**\n * Union type representing all possible data storage formats for PColumn data.\n * The specific format used depends on data size, access patterns, and performance requirements.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfo<Blob>
|
|
1
|
+
{"version":3,"file":"api_factory.cjs","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"sourcesContent":["import type {\n AxisValueType,\n BinaryPartitionedDataInfo,\n Branded,\n ColumnValueType,\n JsonDataInfo,\n JsonPartitionedDataInfo,\n ParquetChunk,\n ParquetPartitionedDataInfo,\n PObjectId,\n} from \"@milaboratories/pl-model-common\";\nimport type { HttpServerInfo } from \"./http_helpers\";\n\n/** PColumn spec file extension */\nexport const SpecExtension = \".spec\" as const;\n\n/** PColumn data info file extension */\nexport const DataInfoExtension = \".datainfo\" as const;\n\n/** Abstract identifier of a data blob that can be requested from the storage backend */\nexport type PFrameBlobId = Branded<string, \"PFrameInternal.PFrameBlobId\">;\n\n/** Path of the file containing requested data (blob). This path is returned by\n * {@link BlobPathResolver} as soon as blob materialized in the file system. */\nexport type FilePath = string;\n\n/** Data source allows PFrame to retrieve the data blobs for columns with assigned data info. */\nexport interface PFrameDataSourceV2 {\n /**\n * PFrame may notify storage backend about its plans to use particular blobs in the future.\n * Storage backend will do its best to preload specified blob so the subsequent\n * {@link resolveBlob} will quickly return preloaded file path.\n */\n preloadBlob(blobIds: PFrameBlobId[]): Promise<void>;\n\n /** Returns raw blob data given the blob id from {@link DataInfo}. */\n resolveBlobContent(blobId: PFrameBlobId): Promise<Uint8Array>;\n\n /**\n * Parquet HTTP(S) server connection settings, {@link HttpHelpers.createHttpServer}\n * When not provided, parquet BlobIds would be treated as local file paths.\n */\n parquetServer?: HttpServerInfo;\n}\n\n/**\n * Structural type information for a single PColumn needed by the data side:\n * the axis value types (in canonical order) and the column value type. Mirrors\n * the on-disk `typeSpec` shape (`{ axes, column }`).\n */\nexport type PColumnValueTypeSpec = {\n readonly axes: AxisValueType[];\n readonly column: ColumnValueType;\n};\n\n/**\n * Union type representing all possible data storage formats for PColumn data.\n * The specific format used depends on data size, access patterns, and performance requirements.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfo<Blob> = (\n | JsonDataInfo\n | JsonPartitionedDataInfo<Blob>\n | BinaryPartitionedDataInfo<Blob>\n | ParquetPartitionedDataInfo<ParquetChunk<Blob>>\n) & {\n /**\n * Self-contained structural type info. Present in data info produced by the\n * new converter, absent in data info produced by the old one.\n */\n readonly typeSpec?: PColumnValueTypeSpec;\n};\n\n/**\n * Self-contained data info: {@link DataInfo} with a required\n * {@link PColumnValueTypeSpec}, so the data layer can interpret the values\n * without a separate spec. This is the on-disk `.datainfo` shape and the\n * payload accepted by {@link PFrameFactoryAPIV6.addColumns}.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfoV2<Blob> = DataInfo<Blob> & {\n readonly typeSpec: PColumnValueTypeSpec;\n};\n\n/**\n * Single column entry for {@link PFrameFactoryAPIV6.addColumns}. The structural\n * type info is carried inside {@link DataInfoV2.typeSpec} rather than as a\n * separate field, so `data` is self-describing.\n */\nexport interface AddColumnEntryV2 {\n /** Unique column identifier within the PFrame. */\n readonly id: PObjectId;\n /** Self-contained data info (carries its own `typeSpec`). */\n readonly data: DataInfoV2<PFrameBlobId>;\n}\n\n/**\n * API for populating a PFrame with columns and a data source. Each column's\n * structural type info is embedded in its self-contained\n * {@link AddColumnEntryV2.data} instead of a separate field.\n */\nexport interface PFrameFactoryAPIV6 extends Disposable {\n /** Associates data source with this PFrame. */\n setDataSource(dataSource: PFrameDataSourceV2): void;\n\n /**\n * Registers all PColumns at once: data info (self-contained, carrying its own\n * `typeSpec`) is attached atomically. For parquet data info, schema resolution\n * via network is performed during this call.\n */\n addColumns(\n columns: AddColumnEntryV2[],\n options?: {\n signal?: AbortSignal;\n },\n ): Promise<void>;\n\n /** Releases all the data previously added to PFrame using methods above,\n * any interactions with disposed PFrame will result in exception */\n dispose(): void;\n}\n"],"mappings":";;AAcA,MAAa,gBAAgB;;AAG7B,MAAa,oBAAoB"}
|
|
@@ -27,41 +27,64 @@ interface PFrameDataSourceV2 {
|
|
|
27
27
|
*/
|
|
28
28
|
parquetServer?: HttpServerInfo;
|
|
29
29
|
}
|
|
30
|
+
/**
|
|
31
|
+
* Structural type information for a single PColumn needed by the data side:
|
|
32
|
+
* the axis value types (in canonical order) and the column value type. Mirrors
|
|
33
|
+
* the on-disk `typeSpec` shape (`{ axes, column }`).
|
|
34
|
+
*/
|
|
35
|
+
type PColumnValueTypeSpec = {
|
|
36
|
+
readonly axes: AxisValueType[];
|
|
37
|
+
readonly column: ColumnValueType;
|
|
38
|
+
};
|
|
30
39
|
/**
|
|
31
40
|
* Union type representing all possible data storage formats for PColumn data.
|
|
32
41
|
* The specific format used depends on data size, access patterns, and performance requirements.
|
|
33
42
|
*
|
|
34
43
|
* @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)
|
|
35
44
|
*/
|
|
36
|
-
type DataInfo<Blob> = JsonDataInfo | JsonPartitionedDataInfo<Blob> | BinaryPartitionedDataInfo<Blob> | ParquetPartitionedDataInfo<ParquetChunk<Blob
|
|
45
|
+
type DataInfo<Blob> = (JsonDataInfo | JsonPartitionedDataInfo<Blob> | BinaryPartitionedDataInfo<Blob> | ParquetPartitionedDataInfo<ParquetChunk<Blob>>) & {
|
|
46
|
+
/**
|
|
47
|
+
* Self-contained structural type info. Present in data info produced by the
|
|
48
|
+
* new converter, absent in data info produced by the old one.
|
|
49
|
+
*/
|
|
50
|
+
readonly typeSpec?: PColumnValueTypeSpec;
|
|
51
|
+
};
|
|
37
52
|
/**
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
* the
|
|
53
|
+
* Self-contained data info: {@link DataInfo} with a required
|
|
54
|
+
* {@link PColumnValueTypeSpec}, so the data layer can interpret the values
|
|
55
|
+
* without a separate spec. This is the on-disk `.datainfo` shape and the
|
|
56
|
+
* payload accepted by {@link PFrameFactoryAPIV6.addColumns}.
|
|
57
|
+
*
|
|
58
|
+
* @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)
|
|
41
59
|
*/
|
|
42
|
-
|
|
43
|
-
readonly
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
60
|
+
type DataInfoV2<Blob> = DataInfo<Blob> & {
|
|
61
|
+
readonly typeSpec: PColumnValueTypeSpec;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* Single column entry for {@link PFrameFactoryAPIV6.addColumns}. The structural
|
|
65
|
+
* type info is carried inside {@link DataInfoV2.typeSpec} rather than as a
|
|
66
|
+
* separate field, so `data` is self-describing.
|
|
67
|
+
*/
|
|
68
|
+
interface AddColumnEntryV2 {
|
|
48
69
|
/** Unique column identifier within the PFrame. */
|
|
49
70
|
readonly id: PObjectId;
|
|
50
|
-
/**
|
|
51
|
-
readonly
|
|
52
|
-
/** Data info for the column. */
|
|
53
|
-
readonly data: DataInfo<PFrameBlobId>;
|
|
71
|
+
/** Self-contained data info (carries its own `typeSpec`). */
|
|
72
|
+
readonly data: DataInfoV2<PFrameBlobId>;
|
|
54
73
|
}
|
|
55
|
-
/**
|
|
56
|
-
|
|
74
|
+
/**
|
|
75
|
+
* API for populating a PFrame with columns and a data source. Each column's
|
|
76
|
+
* structural type info is embedded in its self-contained
|
|
77
|
+
* {@link AddColumnEntryV2.data} instead of a separate field.
|
|
78
|
+
*/
|
|
79
|
+
interface PFrameFactoryAPIV6 extends Disposable {
|
|
57
80
|
/** Associates data source with this PFrame. */
|
|
58
81
|
setDataSource(dataSource: PFrameDataSourceV2): void;
|
|
59
82
|
/**
|
|
60
|
-
* Registers all PColumns at once:
|
|
61
|
-
* is attached atomically. For parquet data info, schema resolution
|
|
83
|
+
* Registers all PColumns at once: data info (self-contained, carrying its own
|
|
84
|
+
* `typeSpec`) is attached atomically. For parquet data info, schema resolution
|
|
62
85
|
* via network is performed during this call.
|
|
63
86
|
*/
|
|
64
|
-
addColumns(columns:
|
|
87
|
+
addColumns(columns: AddColumnEntryV2[], options?: {
|
|
65
88
|
signal?: AbortSignal;
|
|
66
89
|
}): Promise<void>;
|
|
67
90
|
/** Releases all the data previously added to PFrame using methods above,
|
|
@@ -69,5 +92,5 @@ interface PFrameFactoryAPIV5 extends Disposable {
|
|
|
69
92
|
dispose(): void;
|
|
70
93
|
}
|
|
71
94
|
//#endregion
|
|
72
|
-
export {
|
|
95
|
+
export { AddColumnEntryV2, DataInfo, DataInfoExtension, DataInfoV2, FilePath, PColumnValueTypeSpec, PFrameBlobId, PFrameDataSourceV2, PFrameFactoryAPIV6, SpecExtension };
|
|
73
96
|
//# sourceMappingURL=api_factory.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api_factory.d.ts","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"mappings":";;;;;cAca,aAAA;AAAb;AAAA,cAGa,iBAAA;;KAGD,YAAA,GAAe,OAAA;;AAH3B;KAOY,QAAA;;UAGK,kBAAA;EAVoC;AAGrD;;;;EAaE,WAAA,CAAY,OAAA,EAAS,YAAA,KAAiB,OAAA;EAT5B;EAYV,kBAAA,CAAmB,MAAA,EAAQ,YAAA,GAAe,OAAA,CAAQ,UAAA;;;;AATpD;EAeE,aAAA,GAAgB,cAAA;AAAA;;;;;;;
|
|
1
|
+
{"version":3,"file":"api_factory.d.ts","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"mappings":";;;;;cAca,aAAA;AAAb;AAAA,cAGa,iBAAA;;KAGD,YAAA,GAAe,OAAA;;AAH3B;KAOY,QAAA;;UAGK,kBAAA;EAVoC;AAGrD;;;;EAaE,WAAA,CAAY,OAAA,EAAS,YAAA,KAAiB,OAAA;EAT5B;EAYV,kBAAA,CAAmB,MAAA,EAAQ,YAAA,GAAe,OAAA,CAAQ,UAAA;;;;AATpD;EAeE,aAAA,GAAgB,cAAA;AAAA;;;;;;KAQN,oBAAA;EAAA,SACD,IAAA,EAAM,aAAA;EAAA,SACN,MAAA,EAAQ,eAAA;AAAA;;;;;;;KASP,QAAA,UACR,YAAA,GACA,uBAAA,CAAwB,IAAA,IACxB,yBAAA,CAA0B,IAAA,IAC1B,0BAAA,CAA2B,YAAA,CAAa,IAAA;EA7BQ;;;;EAAA,SAmCzC,QAAA,GAAW,oBAAA;AAAA;;;;;;;;;KAWV,UAAA,SAAmB,QAAA,CAAS,IAAA;EAAA,SAC7B,QAAA,EAAU,oBAAA;AAAA;;;;;;UAQJ,gBAAA;EA1B2B;EAAA,SA4BjC,EAAA,EAAI,SAAA;EA5BX;EAAA,SA8BO,IAAA,EAAM,UAAA,CAAW,YAAA;AAAA;;;;;;UAQX,kBAAA,SAA2B,UAAA;EAvCd;EAyC5B,aAAA,CAAc,UAAA,EAAY,kBAAA;EAxCG;;;;;EA+C7B,UAAA,CACE,OAAA,EAAS,gBAAA,IACT,OAAA;IACE,MAAA,GAAS,WAAA;EAAA,IAEV,OAAA;EAnCiB;;EAuCpB,OAAA;AAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api_factory.js","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"sourcesContent":["import type {\n AxisValueType,\n BinaryPartitionedDataInfo,\n Branded,\n ColumnValueType,\n JsonDataInfo,\n JsonPartitionedDataInfo,\n ParquetChunk,\n ParquetPartitionedDataInfo,\n PObjectId,\n} from \"@milaboratories/pl-model-common\";\nimport type { HttpServerInfo } from \"./http_helpers\";\n\n/** PColumn spec file extension */\nexport const SpecExtension = \".spec\" as const;\n\n/** PColumn data info file extension */\nexport const DataInfoExtension = \".datainfo\" as const;\n\n/** Abstract identifier of a data blob that can be requested from the storage backend */\nexport type PFrameBlobId = Branded<string, \"PFrameInternal.PFrameBlobId\">;\n\n/** Path of the file containing requested data (blob). This path is returned by\n * {@link BlobPathResolver} as soon as blob materialized in the file system. */\nexport type FilePath = string;\n\n/** Data source allows PFrame to retrieve the data blobs for columns with assigned data info. */\nexport interface PFrameDataSourceV2 {\n /**\n * PFrame may notify storage backend about its plans to use particular blobs in the future.\n * Storage backend will do its best to preload specified blob so the subsequent\n * {@link resolveBlob} will quickly return preloaded file path.\n */\n preloadBlob(blobIds: PFrameBlobId[]): Promise<void>;\n\n /** Returns raw blob data given the blob id from {@link DataInfo}. */\n resolveBlobContent(blobId: PFrameBlobId): Promise<Uint8Array>;\n\n /**\n * Parquet HTTP(S) server connection settings, {@link HttpHelpers.createHttpServer}\n * When not provided, parquet BlobIds would be treated as local file paths.\n */\n parquetServer?: HttpServerInfo;\n}\n\n/**\n * Union type representing all possible data storage formats for PColumn data.\n * The specific format used depends on data size, access patterns, and performance requirements.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfo<Blob>
|
|
1
|
+
{"version":3,"file":"api_factory.js","names":[],"sources":["../../../src/pframe/internal_api/api_factory.ts"],"sourcesContent":["import type {\n AxisValueType,\n BinaryPartitionedDataInfo,\n Branded,\n ColumnValueType,\n JsonDataInfo,\n JsonPartitionedDataInfo,\n ParquetChunk,\n ParquetPartitionedDataInfo,\n PObjectId,\n} from \"@milaboratories/pl-model-common\";\nimport type { HttpServerInfo } from \"./http_helpers\";\n\n/** PColumn spec file extension */\nexport const SpecExtension = \".spec\" as const;\n\n/** PColumn data info file extension */\nexport const DataInfoExtension = \".datainfo\" as const;\n\n/** Abstract identifier of a data blob that can be requested from the storage backend */\nexport type PFrameBlobId = Branded<string, \"PFrameInternal.PFrameBlobId\">;\n\n/** Path of the file containing requested data (blob). This path is returned by\n * {@link BlobPathResolver} as soon as blob materialized in the file system. */\nexport type FilePath = string;\n\n/** Data source allows PFrame to retrieve the data blobs for columns with assigned data info. */\nexport interface PFrameDataSourceV2 {\n /**\n * PFrame may notify storage backend about its plans to use particular blobs in the future.\n * Storage backend will do its best to preload specified blob so the subsequent\n * {@link resolveBlob} will quickly return preloaded file path.\n */\n preloadBlob(blobIds: PFrameBlobId[]): Promise<void>;\n\n /** Returns raw blob data given the blob id from {@link DataInfo}. */\n resolveBlobContent(blobId: PFrameBlobId): Promise<Uint8Array>;\n\n /**\n * Parquet HTTP(S) server connection settings, {@link HttpHelpers.createHttpServer}\n * When not provided, parquet BlobIds would be treated as local file paths.\n */\n parquetServer?: HttpServerInfo;\n}\n\n/**\n * Structural type information for a single PColumn needed by the data side:\n * the axis value types (in canonical order) and the column value type. Mirrors\n * the on-disk `typeSpec` shape (`{ axes, column }`).\n */\nexport type PColumnValueTypeSpec = {\n readonly axes: AxisValueType[];\n readonly column: ColumnValueType;\n};\n\n/**\n * Union type representing all possible data storage formats for PColumn data.\n * The specific format used depends on data size, access patterns, and performance requirements.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfo<Blob> = (\n | JsonDataInfo\n | JsonPartitionedDataInfo<Blob>\n | BinaryPartitionedDataInfo<Blob>\n | ParquetPartitionedDataInfo<ParquetChunk<Blob>>\n) & {\n /**\n * Self-contained structural type info. Present in data info produced by the\n * new converter, absent in data info produced by the old one.\n */\n readonly typeSpec?: PColumnValueTypeSpec;\n};\n\n/**\n * Self-contained data info: {@link DataInfo} with a required\n * {@link PColumnValueTypeSpec}, so the data layer can interpret the values\n * without a separate spec. This is the on-disk `.datainfo` shape and the\n * payload accepted by {@link PFrameFactoryAPIV6.addColumns}.\n *\n * @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)\n */\nexport type DataInfoV2<Blob> = DataInfo<Blob> & {\n readonly typeSpec: PColumnValueTypeSpec;\n};\n\n/**\n * Single column entry for {@link PFrameFactoryAPIV6.addColumns}. The structural\n * type info is carried inside {@link DataInfoV2.typeSpec} rather than as a\n * separate field, so `data` is self-describing.\n */\nexport interface AddColumnEntryV2 {\n /** Unique column identifier within the PFrame. */\n readonly id: PObjectId;\n /** Self-contained data info (carries its own `typeSpec`). */\n readonly data: DataInfoV2<PFrameBlobId>;\n}\n\n/**\n * API for populating a PFrame with columns and a data source. Each column's\n * structural type info is embedded in its self-contained\n * {@link AddColumnEntryV2.data} instead of a separate field.\n */\nexport interface PFrameFactoryAPIV6 extends Disposable {\n /** Associates data source with this PFrame. */\n setDataSource(dataSource: PFrameDataSourceV2): void;\n\n /**\n * Registers all PColumns at once: data info (self-contained, carrying its own\n * `typeSpec`) is attached atomically. For parquet data info, schema resolution\n * via network is performed during this call.\n */\n addColumns(\n columns: AddColumnEntryV2[],\n options?: {\n signal?: AbortSignal;\n },\n ): Promise<void>;\n\n /** Releases all the data previously added to PFrame using methods above,\n * any interactions with disposed PFrame will result in exception */\n dispose(): void;\n}\n"],"mappings":";;AAcA,MAAa,gBAAgB;;AAG7B,MAAa,oBAAoB"}
|
|
@@ -2,18 +2,18 @@ import { PTableV11 } from "./table.js";
|
|
|
2
2
|
import { AxisQualification, ColumnAxesWithQualifications, ConstantAxisFilter, Logger, PFrameId, PTableId } from "./common.js";
|
|
3
3
|
import { PFrameReadAPIV14, UniqueValuesRequestV2 } from "./api_read.js";
|
|
4
4
|
import { BaseObjectStore, FileRange, FsStoreOptions, HttpAuthorizationToken, HttpHelpers, HttpMethod, HttpRange, HttpServer, HttpServerInfo, HttpServerOptions, ObjectStore, ObjectStoreOptions, ObjectStoreResponse, ObjectStoreUrl, ParquetExtension, ParquetFileName, PemCertificate, RequestHandlerOptions } from "./http_helpers.js";
|
|
5
|
-
import {
|
|
5
|
+
import { AddColumnEntryV2, DataInfo, DataInfoExtension, DataInfoV2, FilePath, PColumnValueTypeSpec, PFrameBlobId, PFrameDataSourceV2, PFrameFactoryAPIV6, SpecExtension } from "./api_factory.js";
|
|
6
6
|
import { DeleteColumnFromColumnsRequest, DeleteColumnFromColumnsResponse } from "./delete_column.js";
|
|
7
7
|
import { DiscoverColumnsConstraints, DiscoverColumnsMappingVariant, DiscoverColumnsRequestV2, DiscoverColumnsResponse, DiscoverColumnsResponseHit, DiscoverColumnsResponseQualifications, DiscoverColumnsStepInfo, MatcherMap, MultiAxisSelector, MultiColumnSelector, StringMatcher } from "./discover_columns.js";
|
|
8
8
|
import { FindColumnResponseQualifications, FindColumnsMappingVariant, FindColumnsRequest, FindColumnsResponse, FindColumnsResponseHit } from "./find_columns.js";
|
|
9
9
|
import { EvaluateQueryResponse, LegacyQuery, PFrameWasmAPIV2, PFrameWasmAPIV3, PFrameWasmAPIV4, PFrameWasmV2, PFrameWasmV3 } from "./api_wasm.js";
|
|
10
10
|
import { ArtificialColumnJoinEntry, ColumnJoinEntry, CreateTableRequestV4, FullJoinV4, InlineColumnJoinEntry, InnerJoinV4, JoinEntryV4, OuterJoinV4, SlicedColumnJoinEntry } from "./create_table.js";
|
|
11
|
-
import {
|
|
11
|
+
import { PFrameFactoryV8, PFrameOptionsV2, PFrameV17 } from "./pframe.js";
|
|
12
12
|
import { SingleAxisSelector as SingleAxisSelector$1 } from "@milaboratories/pl-model-common";
|
|
13
13
|
|
|
14
14
|
//#region src/pframe/internal_api/index.d.ts
|
|
15
15
|
declare namespace index_d_exports {
|
|
16
|
-
export {
|
|
16
|
+
export { AddColumnEntryV2, ArtificialColumnJoinEntry, AxisQualification, BaseObjectStore, ColumnAxesWithQualifications, ColumnJoinEntry, ConstantAxisFilter, CreateTableRequestV4, DataInfo, DataInfoExtension, DataInfoV2, DeleteColumnFromColumnsRequest, DeleteColumnFromColumnsResponse, DiscoverColumnsConstraints, DiscoverColumnsMappingVariant, DiscoverColumnsRequestV2, DiscoverColumnsResponse, DiscoverColumnsResponseHit, DiscoverColumnsResponseQualifications, DiscoverColumnsStepInfo, EvaluateQueryResponse, FilePath, FileRange, FindColumnResponseQualifications, FindColumnsMappingVariant, FindColumnsRequest, FindColumnsResponse, FindColumnsResponseHit, FsStoreOptions, FullJoinV4, HttpAuthorizationToken, HttpHelpers, HttpMethod, HttpRange, HttpServer, HttpServerInfo, HttpServerOptions, InlineColumnJoinEntry, InnerJoinV4, JoinEntryV4, LegacyQuery, Logger, MatcherMap, MultiAxisSelector, MultiColumnSelector, ObjectStore, ObjectStoreOptions, ObjectStoreResponse, ObjectStoreUrl, OuterJoinV4, PColumnValueTypeSpec, PFrameBlobId, PFrameDataSourceV2, PFrameFactoryAPIV6, PFrameFactoryV8, PFrameId, PFrameOptionsV2, PFrameReadAPIV14, PFrameV17, PFrameWasmAPIV2, PFrameWasmAPIV3, PFrameWasmAPIV4, PFrameWasmV2, PFrameWasmV3, PTableId, PTableV11, ParquetExtension, ParquetFileName, PemCertificate, RequestHandlerOptions, SingleAxisSelector$1 as SingleAxisSelector, SlicedColumnJoinEntry, SpecExtension, StringMatcher, UniqueValuesRequestV2 };
|
|
17
17
|
}
|
|
18
18
|
//#endregion
|
|
19
19
|
export { index_d_exports };
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { Logger, PFrameId } from "./common.js";
|
|
2
2
|
import { PFrameReadAPIV14 } from "./api_read.js";
|
|
3
|
-
import {
|
|
3
|
+
import { PFrameFactoryAPIV6 } from "./api_factory.js";
|
|
4
4
|
|
|
5
5
|
//#region src/pframe/internal_api/pframe.d.ts
|
|
6
6
|
/**
|
|
7
7
|
* Full PFrame surface — factory operations plus data-side reads. Exposes
|
|
8
|
-
* {@link
|
|
9
|
-
*
|
|
8
|
+
* the self-contained {@link PFrameFactoryAPIV6} (column `typeSpec` embedded in
|
|
9
|
+
* `data`) plus {@link PFrameReadAPIV14}, whose tables' `export` takes a
|
|
10
|
+
* column-index → header map.
|
|
10
11
|
*/
|
|
11
|
-
interface
|
|
12
|
+
interface PFrameV17 extends PFrameFactoryAPIV6, PFrameReadAPIV14 {}
|
|
12
13
|
type PFrameOptionsV2 = {
|
|
13
14
|
/** PFrame ID for logging purposes */frameId: PFrameId; /** Path to directory where PFrame can create temporary files */
|
|
14
15
|
spillPath: string; /** Logger instance, no logging is performed when not provided */
|
|
@@ -16,15 +17,14 @@ type PFrameOptionsV2 = {
|
|
|
16
17
|
};
|
|
17
18
|
/**
|
|
18
19
|
* PFrame management functions exposed by the PFrame module. Creates
|
|
19
|
-
* {@link
|
|
20
|
-
* column-index → header map.
|
|
20
|
+
* {@link PFrameV17} instances (self-contained column data info).
|
|
21
21
|
*/
|
|
22
|
-
interface
|
|
22
|
+
interface PFrameFactoryV8 {
|
|
23
23
|
/**
|
|
24
24
|
* Create a new PFrame instance.
|
|
25
25
|
* @warning Use concurrency limiting to avoid OOM crashes when multiple instances are simultaneously in use.
|
|
26
26
|
*/
|
|
27
|
-
createPFrame(options: PFrameOptionsV2):
|
|
27
|
+
createPFrame(options: PFrameOptionsV2): PFrameV17;
|
|
28
28
|
/**
|
|
29
29
|
* Dump active allocations from all PFrames instances in pprof format.
|
|
30
30
|
* The result of this function should be saved as `profile.pb.gz`.
|
|
@@ -35,5 +35,5 @@ interface PFrameFactoryV7 {
|
|
|
35
35
|
pprofDump: () => Promise<Uint8Array>;
|
|
36
36
|
}
|
|
37
37
|
//#endregion
|
|
38
|
-
export {
|
|
38
|
+
export { PFrameFactoryV8, PFrameOptionsV2, PFrameV17 };
|
|
39
39
|
//# sourceMappingURL=pframe.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pframe.d.ts","names":[],"sources":["../../../src/pframe/internal_api/pframe.ts"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"pframe.d.ts","names":[],"sources":["../../../src/pframe/internal_api/pframe.ts"],"mappings":";;;;;;AAWA;;;;;UAAiB,SAAA,SAAkB,kBAAA,EAAoB,gBAAA;AAAA,KAE3C,eAAA;EAMK,qCAJf,OAAA,EAAS,QAAA,EAAA;EAET,SAAA,UAEA;EAAA,MAAA,GAAS,MAAA;AAAA;;AAOX;;;UAAiB,eAAA;EAKyB;;;;EAAxC,YAAA,CAAa,OAAA,EAAS,eAAA,GAAkB,SAAA;EAAxC;;;;;;;EASA,SAAA,QAAiB,OAAA,CAAQ,UAAA;AAAA"}
|
package/package.json
CHANGED
|
@@ -43,50 +43,75 @@ export interface PFrameDataSourceV2 {
|
|
|
43
43
|
parquetServer?: HttpServerInfo;
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
+
/**
|
|
47
|
+
* Structural type information for a single PColumn needed by the data side:
|
|
48
|
+
* the axis value types (in canonical order) and the column value type. Mirrors
|
|
49
|
+
* the on-disk `typeSpec` shape (`{ axes, column }`).
|
|
50
|
+
*/
|
|
51
|
+
export type PColumnValueTypeSpec = {
|
|
52
|
+
readonly axes: AxisValueType[];
|
|
53
|
+
readonly column: ColumnValueType;
|
|
54
|
+
};
|
|
55
|
+
|
|
46
56
|
/**
|
|
47
57
|
* Union type representing all possible data storage formats for PColumn data.
|
|
48
58
|
* The specific format used depends on data size, access patterns, and performance requirements.
|
|
49
59
|
*
|
|
50
60
|
* @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)
|
|
51
61
|
*/
|
|
52
|
-
export type DataInfo<Blob> =
|
|
62
|
+
export type DataInfo<Blob> = (
|
|
53
63
|
| JsonDataInfo
|
|
54
64
|
| JsonPartitionedDataInfo<Blob>
|
|
55
65
|
| BinaryPartitionedDataInfo<Blob>
|
|
56
|
-
| ParquetPartitionedDataInfo<ParquetChunk<Blob
|
|
66
|
+
| ParquetPartitionedDataInfo<ParquetChunk<Blob>>
|
|
67
|
+
) & {
|
|
68
|
+
/**
|
|
69
|
+
* Self-contained structural type info. Present in data info produced by the
|
|
70
|
+
* new converter, absent in data info produced by the old one.
|
|
71
|
+
*/
|
|
72
|
+
readonly typeSpec?: PColumnValueTypeSpec;
|
|
73
|
+
};
|
|
57
74
|
|
|
58
75
|
/**
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
* the
|
|
76
|
+
* Self-contained data info: {@link DataInfo} with a required
|
|
77
|
+
* {@link PColumnValueTypeSpec}, so the data layer can interpret the values
|
|
78
|
+
* without a separate spec. This is the on-disk `.datainfo` shape and the
|
|
79
|
+
* payload accepted by {@link PFrameFactoryAPIV6.addColumns}.
|
|
80
|
+
*
|
|
81
|
+
* @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)
|
|
62
82
|
*/
|
|
63
|
-
export
|
|
64
|
-
readonly
|
|
65
|
-
|
|
66
|
-
}
|
|
83
|
+
export type DataInfoV2<Blob> = DataInfo<Blob> & {
|
|
84
|
+
readonly typeSpec: PColumnValueTypeSpec;
|
|
85
|
+
};
|
|
67
86
|
|
|
68
|
-
/**
|
|
69
|
-
|
|
87
|
+
/**
|
|
88
|
+
* Single column entry for {@link PFrameFactoryAPIV6.addColumns}. The structural
|
|
89
|
+
* type info is carried inside {@link DataInfoV2.typeSpec} rather than as a
|
|
90
|
+
* separate field, so `data` is self-describing.
|
|
91
|
+
*/
|
|
92
|
+
export interface AddColumnEntryV2 {
|
|
70
93
|
/** Unique column identifier within the PFrame. */
|
|
71
94
|
readonly id: PObjectId;
|
|
72
|
-
/**
|
|
73
|
-
readonly
|
|
74
|
-
/** Data info for the column. */
|
|
75
|
-
readonly data: DataInfo<PFrameBlobId>;
|
|
95
|
+
/** Self-contained data info (carries its own `typeSpec`). */
|
|
96
|
+
readonly data: DataInfoV2<PFrameBlobId>;
|
|
76
97
|
}
|
|
77
98
|
|
|
78
|
-
/**
|
|
79
|
-
|
|
99
|
+
/**
|
|
100
|
+
* API for populating a PFrame with columns and a data source. Each column's
|
|
101
|
+
* structural type info is embedded in its self-contained
|
|
102
|
+
* {@link AddColumnEntryV2.data} instead of a separate field.
|
|
103
|
+
*/
|
|
104
|
+
export interface PFrameFactoryAPIV6 extends Disposable {
|
|
80
105
|
/** Associates data source with this PFrame. */
|
|
81
106
|
setDataSource(dataSource: PFrameDataSourceV2): void;
|
|
82
107
|
|
|
83
108
|
/**
|
|
84
|
-
* Registers all PColumns at once:
|
|
85
|
-
* is attached atomically. For parquet data info, schema resolution
|
|
109
|
+
* Registers all PColumns at once: data info (self-contained, carrying its own
|
|
110
|
+
* `typeSpec`) is attached atomically. For parquet data info, schema resolution
|
|
86
111
|
* via network is performed during this call.
|
|
87
112
|
*/
|
|
88
113
|
addColumns(
|
|
89
|
-
columns:
|
|
114
|
+
columns: AddColumnEntryV2[],
|
|
90
115
|
options?: {
|
|
91
116
|
signal?: AbortSignal;
|
|
92
117
|
},
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { PFrameFactoryAPIV6 } from "./api_factory";
|
|
2
2
|
import type { PFrameReadAPIV14 } from "./api_read";
|
|
3
3
|
import type { Logger } from "./common";
|
|
4
4
|
import type { PFrameId } from "./common";
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Full PFrame surface — factory operations plus data-side reads. Exposes
|
|
8
|
-
* {@link
|
|
9
|
-
*
|
|
8
|
+
* the self-contained {@link PFrameFactoryAPIV6} (column `typeSpec` embedded in
|
|
9
|
+
* `data`) plus {@link PFrameReadAPIV14}, whose tables' `export` takes a
|
|
10
|
+
* column-index → header map.
|
|
10
11
|
*/
|
|
11
|
-
export interface
|
|
12
|
+
export interface PFrameV17 extends PFrameFactoryAPIV6, PFrameReadAPIV14 {}
|
|
12
13
|
|
|
13
14
|
export type PFrameOptionsV2 = {
|
|
14
15
|
/** PFrame ID for logging purposes */
|
|
@@ -21,15 +22,14 @@ export type PFrameOptionsV2 = {
|
|
|
21
22
|
|
|
22
23
|
/**
|
|
23
24
|
* PFrame management functions exposed by the PFrame module. Creates
|
|
24
|
-
* {@link
|
|
25
|
-
* column-index → header map.
|
|
25
|
+
* {@link PFrameV17} instances (self-contained column data info).
|
|
26
26
|
*/
|
|
27
|
-
export interface
|
|
27
|
+
export interface PFrameFactoryV8 {
|
|
28
28
|
/**
|
|
29
29
|
* Create a new PFrame instance.
|
|
30
30
|
* @warning Use concurrency limiting to avoid OOM crashes when multiple instances are simultaneously in use.
|
|
31
31
|
*/
|
|
32
|
-
createPFrame(options: PFrameOptionsV2):
|
|
32
|
+
createPFrame(options: PFrameOptionsV2): PFrameV17;
|
|
33
33
|
|
|
34
34
|
/**
|
|
35
35
|
* Dump active allocations from all PFrames instances in pprof format.
|