@aouda/client 0.1.15 → 0.1.16
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/README.md +1 -1
- package/dist/cli/index.cjs +46 -17
- package/dist/cli/index.cjs.map +1 -1
- package/dist/cli/index.d.cts +1 -1
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +46 -17
- package/dist/cli/index.js.map +1 -1
- package/dist/{client-CXfjcF61.d.cts → client-CsE8Vd6m.d.cts} +70 -4
- package/dist/{client-CXfjcF61.d.ts → client-CsE8Vd6m.d.ts} +70 -4
- package/dist/index.cjs +46 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +13 -10
- package/dist/index.d.ts +13 -10
- package/dist/index.js +46 -17
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { T as Transport, B as BulkLoadOptions, a as BulkLoadJobHandle, R as ReplicationStatusResponse, b as TopologyResponse, C as CoverageResponse, H as HealthStatus, c as ReadinessResponse, D as DetailedHealthResponse, N as NodeInfoResponse, d as TriggerBackupRequest, e as TriggerBackupResponse, L as ListBackupsResponse, f as RestoreBackupResponse, g as BackupSchedule, J as JoinClusterRequest, h as JoinClusterResponse, i as LeaveClusterResponse, P as PromoteClusterResponse, F as FailoverClusterResponse, j as DrainClusterResponse, k as ClusterConfigResponse, l as ClusterConfigPatchRequest,
|
|
2
|
-
export {
|
|
1
|
+
import { S as StreamAckRowError, T as Transport, B as BulkLoadOptions, a as BulkLoadJobHandle, R as ReplicationStatusResponse, b as TopologyResponse, C as CoverageResponse, H as HealthStatus, c as ReadinessResponse, D as DetailedHealthResponse, N as NodeInfoResponse, d as TriggerBackupRequest, e as TriggerBackupResponse, L as ListBackupsResponse, f as RestoreBackupResponse, g as BackupSchedule, J as JoinClusterRequest, h as JoinClusterResponse, i as LeaveClusterResponse, P as PromoteClusterResponse, F as FailoverClusterResponse, j as DrainClusterResponse, k as ClusterConfigResponse, l as ClusterConfigPatchRequest, m as SchemaLike, n as DefaultSchema, A as AoudaClient } from './client-CsE8Vd6m.cjs';
|
|
2
|
+
export { o as AGGREGATE_FUNCTIONS, p as AOUDA_DATA_TYPES, q as AddColumnRequest, r as AdminApi, s as AdminBackupConfig, t as AdminBackupPatch, u as AdminConfigPatchRequest, v as AdminConfigResponse, w as AdminConfigSchemaResponse, x as AdminLoggingConfig, y as AdminLoggingPatch, z as AdminMemoryConfig, E as AdminMemoryPatch, G as AggregateFunctionName, I as AlterColumnRequest, K as AoudaClientOptions, M as AoudaDataType, O as AppAuthOptions, Q as AuthClient, U as AuthResult, V as AuthUserInfo, W as AuthorizationMode, X as BackupAdminApi, Y as BackupMetrics, Z as BackupSummary, _ as BatchMutationResult, $ as BatchOperationInput, a0 as BloomFilterMetrics, a1 as BranchInfo, a2 as BranchesApi, a3 as BulkLoadForceAbortRequest, a4 as BulkLoadForceAbortResponse, a5 as BulkLoadListResponse, a6 as BulkLoadProgress, a7 as BulkLoadReplicaProgress, a8 as BulkLoadReplicaProgressDto, a9 as BulkLoadStatusResponse, aa as CircuitBreakerPolicy, ab as ClusterAdminApi, ac as ClusterMemberEntry, ad as ClusterThisNodeEntry, ae as ColumnSchema, af as ColumnSummaryForErd, ag as ColumnarResponse, ah as ComponentHealthEntry, ai as ComputedColumnDef, aj as ConfigAdminApi, ak as ConsistencyTokenStore, al as CreateBranchRequest, am as CreateColumnRequest, an as CreateDatabaseOptions, ao as CreatePartitionGrantRequest, ap as CreateRlsResolverRequest, aq as CreateTableRequest, ar as DatabaseAuthInfo, as as DatabaseAuthKeys, at as DatabaseCoverageEntry, au as DatabaseInfo, av as DatabaseMemoryMetrics, aw as DatabaseMemoryUsage, ax as DatabaseMetricsDto, ay as DatabaseOptionsInfo, az as DatabasesApi, aA as DeleteOptions, aB as DiffSummary, aC as FILTER_OPERATORS, aD as FilterOperator, aE as HealthAdminApi, aF as IndexInfo, aG as InsertOptions, aH as InsertResult, aI as IoMetrics, aJ as JobsApi, aK as LatencyPercentiles, aL as MaterializedQueriesApi, aM as MaterializedQueryDefinition, aN as MaterializedQueryExecuteOptions, aO as MaterializedQueryExecuteResult, aP as MaterializedQueryMetrics, aQ as MaterializedQueryRefreshOptions, aR as MaterializedQueryState, aS as MaterializedQueryStateNumber, aT as MaterializedQueryStatus, aU as MaterializedQueryType, aV as MaterializedQueryTypeNumber, aW as MemberInfo, aX as MemoryConsistencyTokenStore, aY as MemoryMetrics, aZ as MergeBranchOptions, a_ as MergeConflict, a$ as MergeExecutionResult, b0 as MergeResult, b1 as MetricsAdminApi, b2 as MetricsHistory, b3 as MetricsHistoryOptions, b4 as MetricsSnapshot, b5 as MetricsSummary, b6 as MutationResult, b7 as NamedArtifactWarning, b8 as NamedMutationDefinition, b9 as NamedMutationResult, ba as NamedMutationsApi, bb as NamedQueriesApi, bc as NamedQueryBatchItem, bd as NamedQueryBatchSlotResult, be as NamedQueryDefinition, bf as NamedQueryExecuteOptions, bg as NamedQueryParamConstraint, bh as NamedQuerySubscribeOptions, bi as NodeAdminApi, bj as NodeLogEntry, bk as NodeLogLevel, bl as NodeLogStreamOptions, bm as NodeLogsQuery, bn as NodeLogsResponse, bo as OpenWriteStreamOptions, bp as PageCacheMetrics, bq as PartitionFunction, br as PartitionGrant, bs as PartitionGrantsListResponse, bt as PartitioningMetrics, bu as PendingJobListResponse, bv as PendingJobResponse, bw as PerDatabaseLagEntry, bx as PerDatabaseMetrics, by as PerDatabaseStatusEntry, bz as PolicyApi, bA as PolicyInspectRequest, bB as PolicyInspectResponse, bC as PolicyInspectTableResult, bD as PolicyInspectTraverseStart, bE as PolicyInspectVectorProbe, bF as QueryMetrics, bG as QueryResult, bH as QueryStats, bI as ReferenceInfo, bJ as RelationshipEndpoint, bK as RelationshipInfo, bL as RenameColumnRequest, bM as RenameTableRequest, bN as ReorderColumnsRequest, bO as ReplicationAdminApi, bP as ReplicationMetrics, bQ as ResidencyConfig, bR as ResultWarning, bS as RetryPolicy, bT as RlsResolver, bU as RlsResolverRule, bV as RlsResolverRuleInput, bW as RlsResolversListResponse, bX as SchemaAggregateColumn, bY as SchemaChange, bZ as SchemaChangeType, b_ as SchemaColumnDefinition, b$ as SchemaComputedOutput, c0 as SchemaComputedOutputType, c1 as SchemaDiffResult, c2 as SchemaDocument, c3 as SchemaFilterCondition, c4 as SchemaFilterPredicate, c5 as SchemaGroupByTerm, c6 as SchemaMaterializedQuery, c7 as SchemaMaterializedStorage, c8 as SchemaPartitionKeyEntry, c9 as SchemaRelationshipsResponse, ca as SchemaSettings, cb as SchemaSettingsDurability, cc as SchemaTableDefinition, cd as SchemaTableDurability, ce as SchemaTablePolicy, cf as SchemaTableTransform, cg as SeedApplyResult, ch as SeedTableApplyResult, ci as ServerAdminApi, cj as ServerAuthOptions, ck as ServerMemoryResponse, cl as ServerMetricsResponse, cm as ServiceInfo, cn as SimdMetrics, co as SingleDatabaseMetricsResponse, cp as SortDirection, cq as StorageMetrics, cr as SubscribeOptions, cs as Subscription, ct as SubscriptionChangeEvent, cu as SubscriptionEvent, cv as SubscriptionInfo, cw as SubscriptionSnapshotEvent, cx as TIME_BUCKET_FUNCTIONS, cy as TableCoverageEntry, cz as TableNameFromSchema, cA as TablePolicy, cB as TableQuery, cC as TableSchema, cD as TableSchemaResponse, cE as TableSummary, cF as TableSummaryForErd, cG as TablesApi, cH as TestIdentity, cI as TestIdentityDocument, cJ as TestIdentityGrant, cK as TimeBucketFunction, cL as TimeSeriesMetrics, cM as TransactionMetrics, cN as TypeGenerationOptions, cO as UpdateOptions, cP as UpdateRlsResolverRequest, cQ as UpdateTableOptionsRequest, cR as UpdateTablePolicyRequest, cS as UserProfile, cT as WalMetrics, cU as WhereGroupBuilder, cV as WhereOperator, cW as WriteStream, cX as coerceColumnarValue, cY as columnarToRows, cZ as compareOrdinal, c_ as createAoudaClient, c$ as maxToken } from './client-CsE8Vd6m.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* @aouda/client error types.
|
|
6
6
|
*/
|
|
7
|
+
|
|
7
8
|
/**
|
|
8
9
|
* Base error class for Aouda client errors.
|
|
9
10
|
*/
|
|
@@ -16,7 +17,8 @@ declare class AoudaError extends Error {
|
|
|
16
17
|
*/
|
|
17
18
|
declare class AoudaConnectionError extends AoudaError {
|
|
18
19
|
readonly cause?: Error | undefined;
|
|
19
|
-
|
|
20
|
+
readonly rowErrors?: readonly StreamAckRowError[] | undefined;
|
|
21
|
+
constructor(message: string, cause?: Error | undefined, rowErrors?: readonly StreamAckRowError[] | undefined);
|
|
20
22
|
}
|
|
21
23
|
/**
|
|
22
24
|
* Error thrown when a request times out.
|
|
@@ -44,37 +46,38 @@ declare class AoudaApiError extends AoudaError {
|
|
|
44
46
|
readonly requestId?: string | undefined;
|
|
45
47
|
readonly retryAfterSeconds?: number | undefined;
|
|
46
48
|
readonly token?: string | undefined;
|
|
47
|
-
|
|
49
|
+
readonly rowErrors?: readonly StreamAckRowError[] | undefined;
|
|
50
|
+
constructor(message: string, code: string, statusCode: number, details?: string | undefined, requestId?: string | undefined, retryAfterSeconds?: number | undefined, token?: string | undefined, rowErrors?: readonly StreamAckRowError[] | undefined);
|
|
48
51
|
}
|
|
49
52
|
/**
|
|
50
53
|
* Thrown for TABLE_NOT_FOUND, COLUMN_NOT_FOUND (404).
|
|
51
54
|
*/
|
|
52
55
|
declare class AoudaNotFoundError extends AoudaApiError {
|
|
53
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
56
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
54
57
|
}
|
|
55
58
|
/**
|
|
56
59
|
* Thrown for TABLE_EXISTS, COLUMN_EXISTS (409).
|
|
57
60
|
*/
|
|
58
61
|
declare class AoudaConflictError extends AoudaApiError {
|
|
59
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
62
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
60
63
|
}
|
|
61
64
|
/**
|
|
62
65
|
* Thrown for INVALID_REQUEST, INVALID_OPERATOR, etc. (400).
|
|
63
66
|
*/
|
|
64
67
|
declare class AoudaValidationError extends AoudaApiError {
|
|
65
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
68
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
66
69
|
}
|
|
67
70
|
/**
|
|
68
71
|
* Thrown for INTERNAL_ERROR, SERVICE_UNAVAILABLE, etc. (5xx).
|
|
69
72
|
*/
|
|
70
73
|
declare class AoudaServerError extends AoudaApiError {
|
|
71
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
74
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
72
75
|
}
|
|
73
76
|
/**
|
|
74
77
|
* Thrown for 401 authentication errors (AUTH_TOKEN_EXPIRED, AUTH_TOKEN_INVALID, etc.).
|
|
75
78
|
*/
|
|
76
79
|
declare class AoudaAuthenticationError extends AoudaApiError {
|
|
77
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
80
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
78
81
|
}
|
|
79
82
|
/**
|
|
80
83
|
* Thrown when the circuit breaker is open and requests are rejected immediately.
|
|
@@ -226,4 +229,4 @@ declare function createAoudaClusterMcpToolSet<S extends SchemaLike = DefaultSche
|
|
|
226
229
|
*/
|
|
227
230
|
declare const version: string;
|
|
228
231
|
|
|
229
|
-
export { AoudaApiError, AoudaAuthenticationError, AoudaCircuitBreakerOpenError, AoudaClient, type AoudaClusterMcpToolSet, AoudaClusterMcpTools, AoudaConflictError, AoudaConnectionError, AoudaError, AoudaNotFoundError, AoudaResponseError, AoudaServerError, AoudaTimeoutError, AoudaValidationError, type BackupRestoreToolInput, BackupSchedule, type BackupSetScheduleToolInput, type BackupTriggerToolInput, BulkLoadCoordinator, BulkLoadJobHandle, BulkLoadOptions, ClusterConfigPatchRequest, ClusterConfigResponse, type ClusterDrainToolInput, type ClusterHealthToolInput, type ClusterHealthToolOutput, type ClusterPatchConfigToolInput, type ClusterStatusToolInput, type ClusterStatusToolOutput, CoverageResponse, DefaultSchema, DetailedHealthResponse, DrainClusterResponse, FailoverClusterResponse, HealthStatus, JoinClusterRequest, JoinClusterResponse, LeaveClusterResponse, ListBackupsResponse, type LocalNetworkRequestInit, type McpToolDefinition, type McpToolSchema, NodeInfoResponse, PromoteClusterResponse, ReadinessResponse, ReplicationStatusResponse, RestoreBackupResponse, SchemaLike, type TargetAddressSpace, TopologyResponse, TriggerBackupRequest, TriggerBackupResponse, applyLocalNetworkAccess, createAoudaClusterMcpToolSet, installLocalNetworkFetch, localNetworkFetch, resolveTargetAddressSpace, version };
|
|
232
|
+
export { AoudaApiError, AoudaAuthenticationError, AoudaCircuitBreakerOpenError, AoudaClient, type AoudaClusterMcpToolSet, AoudaClusterMcpTools, AoudaConflictError, AoudaConnectionError, AoudaError, AoudaNotFoundError, AoudaResponseError, AoudaServerError, AoudaTimeoutError, AoudaValidationError, type BackupRestoreToolInput, BackupSchedule, type BackupSetScheduleToolInput, type BackupTriggerToolInput, BulkLoadCoordinator, BulkLoadJobHandle, BulkLoadOptions, ClusterConfigPatchRequest, ClusterConfigResponse, type ClusterDrainToolInput, type ClusterHealthToolInput, type ClusterHealthToolOutput, type ClusterPatchConfigToolInput, type ClusterStatusToolInput, type ClusterStatusToolOutput, CoverageResponse, DefaultSchema, DetailedHealthResponse, DrainClusterResponse, FailoverClusterResponse, HealthStatus, JoinClusterRequest, JoinClusterResponse, LeaveClusterResponse, ListBackupsResponse, type LocalNetworkRequestInit, type McpToolDefinition, type McpToolSchema, NodeInfoResponse, PromoteClusterResponse, ReadinessResponse, ReplicationStatusResponse, RestoreBackupResponse, SchemaLike, StreamAckRowError, type TargetAddressSpace, TopologyResponse, TriggerBackupRequest, TriggerBackupResponse, applyLocalNetworkAccess, createAoudaClusterMcpToolSet, installLocalNetworkFetch, localNetworkFetch, resolveTargetAddressSpace, version };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { T as Transport, B as BulkLoadOptions, a as BulkLoadJobHandle, R as ReplicationStatusResponse, b as TopologyResponse, C as CoverageResponse, H as HealthStatus, c as ReadinessResponse, D as DetailedHealthResponse, N as NodeInfoResponse, d as TriggerBackupRequest, e as TriggerBackupResponse, L as ListBackupsResponse, f as RestoreBackupResponse, g as BackupSchedule, J as JoinClusterRequest, h as JoinClusterResponse, i as LeaveClusterResponse, P as PromoteClusterResponse, F as FailoverClusterResponse, j as DrainClusterResponse, k as ClusterConfigResponse, l as ClusterConfigPatchRequest,
|
|
2
|
-
export {
|
|
1
|
+
import { S as StreamAckRowError, T as Transport, B as BulkLoadOptions, a as BulkLoadJobHandle, R as ReplicationStatusResponse, b as TopologyResponse, C as CoverageResponse, H as HealthStatus, c as ReadinessResponse, D as DetailedHealthResponse, N as NodeInfoResponse, d as TriggerBackupRequest, e as TriggerBackupResponse, L as ListBackupsResponse, f as RestoreBackupResponse, g as BackupSchedule, J as JoinClusterRequest, h as JoinClusterResponse, i as LeaveClusterResponse, P as PromoteClusterResponse, F as FailoverClusterResponse, j as DrainClusterResponse, k as ClusterConfigResponse, l as ClusterConfigPatchRequest, m as SchemaLike, n as DefaultSchema, A as AoudaClient } from './client-CsE8Vd6m.js';
|
|
2
|
+
export { o as AGGREGATE_FUNCTIONS, p as AOUDA_DATA_TYPES, q as AddColumnRequest, r as AdminApi, s as AdminBackupConfig, t as AdminBackupPatch, u as AdminConfigPatchRequest, v as AdminConfigResponse, w as AdminConfigSchemaResponse, x as AdminLoggingConfig, y as AdminLoggingPatch, z as AdminMemoryConfig, E as AdminMemoryPatch, G as AggregateFunctionName, I as AlterColumnRequest, K as AoudaClientOptions, M as AoudaDataType, O as AppAuthOptions, Q as AuthClient, U as AuthResult, V as AuthUserInfo, W as AuthorizationMode, X as BackupAdminApi, Y as BackupMetrics, Z as BackupSummary, _ as BatchMutationResult, $ as BatchOperationInput, a0 as BloomFilterMetrics, a1 as BranchInfo, a2 as BranchesApi, a3 as BulkLoadForceAbortRequest, a4 as BulkLoadForceAbortResponse, a5 as BulkLoadListResponse, a6 as BulkLoadProgress, a7 as BulkLoadReplicaProgress, a8 as BulkLoadReplicaProgressDto, a9 as BulkLoadStatusResponse, aa as CircuitBreakerPolicy, ab as ClusterAdminApi, ac as ClusterMemberEntry, ad as ClusterThisNodeEntry, ae as ColumnSchema, af as ColumnSummaryForErd, ag as ColumnarResponse, ah as ComponentHealthEntry, ai as ComputedColumnDef, aj as ConfigAdminApi, ak as ConsistencyTokenStore, al as CreateBranchRequest, am as CreateColumnRequest, an as CreateDatabaseOptions, ao as CreatePartitionGrantRequest, ap as CreateRlsResolverRequest, aq as CreateTableRequest, ar as DatabaseAuthInfo, as as DatabaseAuthKeys, at as DatabaseCoverageEntry, au as DatabaseInfo, av as DatabaseMemoryMetrics, aw as DatabaseMemoryUsage, ax as DatabaseMetricsDto, ay as DatabaseOptionsInfo, az as DatabasesApi, aA as DeleteOptions, aB as DiffSummary, aC as FILTER_OPERATORS, aD as FilterOperator, aE as HealthAdminApi, aF as IndexInfo, aG as InsertOptions, aH as InsertResult, aI as IoMetrics, aJ as JobsApi, aK as LatencyPercentiles, aL as MaterializedQueriesApi, aM as MaterializedQueryDefinition, aN as MaterializedQueryExecuteOptions, aO as MaterializedQueryExecuteResult, aP as MaterializedQueryMetrics, aQ as MaterializedQueryRefreshOptions, aR as MaterializedQueryState, aS as MaterializedQueryStateNumber, aT as MaterializedQueryStatus, aU as MaterializedQueryType, aV as MaterializedQueryTypeNumber, aW as MemberInfo, aX as MemoryConsistencyTokenStore, aY as MemoryMetrics, aZ as MergeBranchOptions, a_ as MergeConflict, a$ as MergeExecutionResult, b0 as MergeResult, b1 as MetricsAdminApi, b2 as MetricsHistory, b3 as MetricsHistoryOptions, b4 as MetricsSnapshot, b5 as MetricsSummary, b6 as MutationResult, b7 as NamedArtifactWarning, b8 as NamedMutationDefinition, b9 as NamedMutationResult, ba as NamedMutationsApi, bb as NamedQueriesApi, bc as NamedQueryBatchItem, bd as NamedQueryBatchSlotResult, be as NamedQueryDefinition, bf as NamedQueryExecuteOptions, bg as NamedQueryParamConstraint, bh as NamedQuerySubscribeOptions, bi as NodeAdminApi, bj as NodeLogEntry, bk as NodeLogLevel, bl as NodeLogStreamOptions, bm as NodeLogsQuery, bn as NodeLogsResponse, bo as OpenWriteStreamOptions, bp as PageCacheMetrics, bq as PartitionFunction, br as PartitionGrant, bs as PartitionGrantsListResponse, bt as PartitioningMetrics, bu as PendingJobListResponse, bv as PendingJobResponse, bw as PerDatabaseLagEntry, bx as PerDatabaseMetrics, by as PerDatabaseStatusEntry, bz as PolicyApi, bA as PolicyInspectRequest, bB as PolicyInspectResponse, bC as PolicyInspectTableResult, bD as PolicyInspectTraverseStart, bE as PolicyInspectVectorProbe, bF as QueryMetrics, bG as QueryResult, bH as QueryStats, bI as ReferenceInfo, bJ as RelationshipEndpoint, bK as RelationshipInfo, bL as RenameColumnRequest, bM as RenameTableRequest, bN as ReorderColumnsRequest, bO as ReplicationAdminApi, bP as ReplicationMetrics, bQ as ResidencyConfig, bR as ResultWarning, bS as RetryPolicy, bT as RlsResolver, bU as RlsResolverRule, bV as RlsResolverRuleInput, bW as RlsResolversListResponse, bX as SchemaAggregateColumn, bY as SchemaChange, bZ as SchemaChangeType, b_ as SchemaColumnDefinition, b$ as SchemaComputedOutput, c0 as SchemaComputedOutputType, c1 as SchemaDiffResult, c2 as SchemaDocument, c3 as SchemaFilterCondition, c4 as SchemaFilterPredicate, c5 as SchemaGroupByTerm, c6 as SchemaMaterializedQuery, c7 as SchemaMaterializedStorage, c8 as SchemaPartitionKeyEntry, c9 as SchemaRelationshipsResponse, ca as SchemaSettings, cb as SchemaSettingsDurability, cc as SchemaTableDefinition, cd as SchemaTableDurability, ce as SchemaTablePolicy, cf as SchemaTableTransform, cg as SeedApplyResult, ch as SeedTableApplyResult, ci as ServerAdminApi, cj as ServerAuthOptions, ck as ServerMemoryResponse, cl as ServerMetricsResponse, cm as ServiceInfo, cn as SimdMetrics, co as SingleDatabaseMetricsResponse, cp as SortDirection, cq as StorageMetrics, cr as SubscribeOptions, cs as Subscription, ct as SubscriptionChangeEvent, cu as SubscriptionEvent, cv as SubscriptionInfo, cw as SubscriptionSnapshotEvent, cx as TIME_BUCKET_FUNCTIONS, cy as TableCoverageEntry, cz as TableNameFromSchema, cA as TablePolicy, cB as TableQuery, cC as TableSchema, cD as TableSchemaResponse, cE as TableSummary, cF as TableSummaryForErd, cG as TablesApi, cH as TestIdentity, cI as TestIdentityDocument, cJ as TestIdentityGrant, cK as TimeBucketFunction, cL as TimeSeriesMetrics, cM as TransactionMetrics, cN as TypeGenerationOptions, cO as UpdateOptions, cP as UpdateRlsResolverRequest, cQ as UpdateTableOptionsRequest, cR as UpdateTablePolicyRequest, cS as UserProfile, cT as WalMetrics, cU as WhereGroupBuilder, cV as WhereOperator, cW as WriteStream, cX as coerceColumnarValue, cY as columnarToRows, cZ as compareOrdinal, c_ as createAoudaClient, c$ as maxToken } from './client-CsE8Vd6m.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* @aouda/client error types.
|
|
6
6
|
*/
|
|
7
|
+
|
|
7
8
|
/**
|
|
8
9
|
* Base error class for Aouda client errors.
|
|
9
10
|
*/
|
|
@@ -16,7 +17,8 @@ declare class AoudaError extends Error {
|
|
|
16
17
|
*/
|
|
17
18
|
declare class AoudaConnectionError extends AoudaError {
|
|
18
19
|
readonly cause?: Error | undefined;
|
|
19
|
-
|
|
20
|
+
readonly rowErrors?: readonly StreamAckRowError[] | undefined;
|
|
21
|
+
constructor(message: string, cause?: Error | undefined, rowErrors?: readonly StreamAckRowError[] | undefined);
|
|
20
22
|
}
|
|
21
23
|
/**
|
|
22
24
|
* Error thrown when a request times out.
|
|
@@ -44,37 +46,38 @@ declare class AoudaApiError extends AoudaError {
|
|
|
44
46
|
readonly requestId?: string | undefined;
|
|
45
47
|
readonly retryAfterSeconds?: number | undefined;
|
|
46
48
|
readonly token?: string | undefined;
|
|
47
|
-
|
|
49
|
+
readonly rowErrors?: readonly StreamAckRowError[] | undefined;
|
|
50
|
+
constructor(message: string, code: string, statusCode: number, details?: string | undefined, requestId?: string | undefined, retryAfterSeconds?: number | undefined, token?: string | undefined, rowErrors?: readonly StreamAckRowError[] | undefined);
|
|
48
51
|
}
|
|
49
52
|
/**
|
|
50
53
|
* Thrown for TABLE_NOT_FOUND, COLUMN_NOT_FOUND (404).
|
|
51
54
|
*/
|
|
52
55
|
declare class AoudaNotFoundError extends AoudaApiError {
|
|
53
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
56
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
54
57
|
}
|
|
55
58
|
/**
|
|
56
59
|
* Thrown for TABLE_EXISTS, COLUMN_EXISTS (409).
|
|
57
60
|
*/
|
|
58
61
|
declare class AoudaConflictError extends AoudaApiError {
|
|
59
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
62
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
60
63
|
}
|
|
61
64
|
/**
|
|
62
65
|
* Thrown for INVALID_REQUEST, INVALID_OPERATOR, etc. (400).
|
|
63
66
|
*/
|
|
64
67
|
declare class AoudaValidationError extends AoudaApiError {
|
|
65
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
68
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
66
69
|
}
|
|
67
70
|
/**
|
|
68
71
|
* Thrown for INTERNAL_ERROR, SERVICE_UNAVAILABLE, etc. (5xx).
|
|
69
72
|
*/
|
|
70
73
|
declare class AoudaServerError extends AoudaApiError {
|
|
71
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
74
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
72
75
|
}
|
|
73
76
|
/**
|
|
74
77
|
* Thrown for 401 authentication errors (AUTH_TOKEN_EXPIRED, AUTH_TOKEN_INVALID, etc.).
|
|
75
78
|
*/
|
|
76
79
|
declare class AoudaAuthenticationError extends AoudaApiError {
|
|
77
|
-
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string);
|
|
80
|
+
constructor(message: string, code: string, statusCode: number, details?: string, requestId?: string, retryAfterSeconds?: number, token?: string, rowErrors?: readonly StreamAckRowError[]);
|
|
78
81
|
}
|
|
79
82
|
/**
|
|
80
83
|
* Thrown when the circuit breaker is open and requests are rejected immediately.
|
|
@@ -226,4 +229,4 @@ declare function createAoudaClusterMcpToolSet<S extends SchemaLike = DefaultSche
|
|
|
226
229
|
*/
|
|
227
230
|
declare const version: string;
|
|
228
231
|
|
|
229
|
-
export { AoudaApiError, AoudaAuthenticationError, AoudaCircuitBreakerOpenError, AoudaClient, type AoudaClusterMcpToolSet, AoudaClusterMcpTools, AoudaConflictError, AoudaConnectionError, AoudaError, AoudaNotFoundError, AoudaResponseError, AoudaServerError, AoudaTimeoutError, AoudaValidationError, type BackupRestoreToolInput, BackupSchedule, type BackupSetScheduleToolInput, type BackupTriggerToolInput, BulkLoadCoordinator, BulkLoadJobHandle, BulkLoadOptions, ClusterConfigPatchRequest, ClusterConfigResponse, type ClusterDrainToolInput, type ClusterHealthToolInput, type ClusterHealthToolOutput, type ClusterPatchConfigToolInput, type ClusterStatusToolInput, type ClusterStatusToolOutput, CoverageResponse, DefaultSchema, DetailedHealthResponse, DrainClusterResponse, FailoverClusterResponse, HealthStatus, JoinClusterRequest, JoinClusterResponse, LeaveClusterResponse, ListBackupsResponse, type LocalNetworkRequestInit, type McpToolDefinition, type McpToolSchema, NodeInfoResponse, PromoteClusterResponse, ReadinessResponse, ReplicationStatusResponse, RestoreBackupResponse, SchemaLike, type TargetAddressSpace, TopologyResponse, TriggerBackupRequest, TriggerBackupResponse, applyLocalNetworkAccess, createAoudaClusterMcpToolSet, installLocalNetworkFetch, localNetworkFetch, resolveTargetAddressSpace, version };
|
|
232
|
+
export { AoudaApiError, AoudaAuthenticationError, AoudaCircuitBreakerOpenError, AoudaClient, type AoudaClusterMcpToolSet, AoudaClusterMcpTools, AoudaConflictError, AoudaConnectionError, AoudaError, AoudaNotFoundError, AoudaResponseError, AoudaServerError, AoudaTimeoutError, AoudaValidationError, type BackupRestoreToolInput, BackupSchedule, type BackupSetScheduleToolInput, type BackupTriggerToolInput, BulkLoadCoordinator, BulkLoadJobHandle, BulkLoadOptions, ClusterConfigPatchRequest, ClusterConfigResponse, type ClusterDrainToolInput, type ClusterHealthToolInput, type ClusterHealthToolOutput, type ClusterPatchConfigToolInput, type ClusterStatusToolInput, type ClusterStatusToolOutput, CoverageResponse, DefaultSchema, DetailedHealthResponse, DrainClusterResponse, FailoverClusterResponse, HealthStatus, JoinClusterRequest, JoinClusterResponse, LeaveClusterResponse, ListBackupsResponse, type LocalNetworkRequestInit, type McpToolDefinition, type McpToolSchema, NodeInfoResponse, PromoteClusterResponse, ReadinessResponse, ReplicationStatusResponse, RestoreBackupResponse, SchemaLike, StreamAckRowError, type TargetAddressSpace, TopologyResponse, TriggerBackupRequest, TriggerBackupResponse, applyLocalNetworkAccess, createAoudaClusterMcpToolSet, installLocalNetworkFetch, localNetworkFetch, resolveTargetAddressSpace, version };
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// package.json
|
|
2
2
|
var package_default = {
|
|
3
3
|
name: "@aouda/client",
|
|
4
|
-
version: "0.1.
|
|
4
|
+
version: "0.1.16",
|
|
5
5
|
description: "Official TypeScript/JavaScript client library for Aouda",
|
|
6
6
|
type: "module",
|
|
7
7
|
main: "./dist/index.cjs",
|
|
@@ -111,9 +111,10 @@ var AoudaError = class extends Error {
|
|
|
111
111
|
}
|
|
112
112
|
};
|
|
113
113
|
var AoudaConnectionError = class extends AoudaError {
|
|
114
|
-
constructor(message, cause) {
|
|
114
|
+
constructor(message, cause, rowErrors) {
|
|
115
115
|
super(message);
|
|
116
116
|
this.cause = cause;
|
|
117
|
+
this.rowErrors = rowErrors;
|
|
117
118
|
this.name = "AoudaConnectionError";
|
|
118
119
|
}
|
|
119
120
|
};
|
|
@@ -133,7 +134,7 @@ var AoudaResponseError = class extends AoudaError {
|
|
|
133
134
|
}
|
|
134
135
|
};
|
|
135
136
|
var AoudaApiError = class extends AoudaError {
|
|
136
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
137
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
137
138
|
super(message);
|
|
138
139
|
this.code = code;
|
|
139
140
|
this.statusCode = statusCode;
|
|
@@ -141,36 +142,37 @@ var AoudaApiError = class extends AoudaError {
|
|
|
141
142
|
this.requestId = requestId;
|
|
142
143
|
this.retryAfterSeconds = retryAfterSeconds;
|
|
143
144
|
this.token = token;
|
|
145
|
+
this.rowErrors = rowErrors;
|
|
144
146
|
this.name = "AoudaApiError";
|
|
145
147
|
}
|
|
146
148
|
};
|
|
147
149
|
var AoudaNotFoundError = class extends AoudaApiError {
|
|
148
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
149
|
-
super(message, code, statusCode, details, requestId, retryAfterSeconds, token);
|
|
150
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
151
|
+
super(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors);
|
|
150
152
|
this.name = "AoudaNotFoundError";
|
|
151
153
|
}
|
|
152
154
|
};
|
|
153
155
|
var AoudaConflictError = class extends AoudaApiError {
|
|
154
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
155
|
-
super(message, code, statusCode, details, requestId, retryAfterSeconds, token);
|
|
156
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
157
|
+
super(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors);
|
|
156
158
|
this.name = "AoudaConflictError";
|
|
157
159
|
}
|
|
158
160
|
};
|
|
159
161
|
var AoudaValidationError = class extends AoudaApiError {
|
|
160
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
161
|
-
super(message, code, statusCode, details, requestId, retryAfterSeconds, token);
|
|
162
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
163
|
+
super(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors);
|
|
162
164
|
this.name = "AoudaValidationError";
|
|
163
165
|
}
|
|
164
166
|
};
|
|
165
167
|
var AoudaServerError = class extends AoudaApiError {
|
|
166
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
167
|
-
super(message, code, statusCode, details, requestId, retryAfterSeconds, token);
|
|
168
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
169
|
+
super(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors);
|
|
168
170
|
this.name = "AoudaServerError";
|
|
169
171
|
}
|
|
170
172
|
};
|
|
171
173
|
var AoudaAuthenticationError = class extends AoudaApiError {
|
|
172
|
-
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token) {
|
|
173
|
-
super(message, code, statusCode, details, requestId, retryAfterSeconds, token);
|
|
174
|
+
constructor(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors) {
|
|
175
|
+
super(message, code, statusCode, details, requestId, retryAfterSeconds, token, rowErrors);
|
|
174
176
|
this.name = "AoudaAuthenticationError";
|
|
175
177
|
}
|
|
176
178
|
};
|
|
@@ -1123,6 +1125,10 @@ var ERROR_CODE_MAP = {
|
|
|
1123
1125
|
INVALID_OPERATOR: AoudaValidationError,
|
|
1124
1126
|
INVALID_COLUMN: AoudaValidationError,
|
|
1125
1127
|
INVALID_VALUE: AoudaValidationError,
|
|
1128
|
+
CONSTRAINT_CHECK_VIOLATION: AoudaValidationError,
|
|
1129
|
+
TRANSFORM_DERIVED_READONLY: AoudaValidationError,
|
|
1130
|
+
TRANSFORM_ROUTE_UNMATCHED: AoudaValidationError,
|
|
1131
|
+
TRANSFORM_ROUTE_AMBIGUOUS: AoudaValidationError,
|
|
1126
1132
|
UNSUPPORTED_VERSION: AoudaValidationError,
|
|
1127
1133
|
MALFORMED_REQUEST: AoudaValidationError,
|
|
1128
1134
|
INTERNAL_ERROR: AoudaServerError,
|
|
@@ -1183,6 +1189,9 @@ function parseRetryAfterSeconds(header) {
|
|
|
1183
1189
|
if (!Number.isFinite(n) || n < 0) return void 0;
|
|
1184
1190
|
return n;
|
|
1185
1191
|
}
|
|
1192
|
+
function nonEmptyRowErrors(rowErrors) {
|
|
1193
|
+
return Array.isArray(rowErrors) && rowErrors.length > 0 ? rowErrors : void 0;
|
|
1194
|
+
}
|
|
1186
1195
|
function createApiError(statusCode, statusText, body, retryAfterHeader) {
|
|
1187
1196
|
const message = body.error ?? `${statusCode} ${statusText}`;
|
|
1188
1197
|
const code = body.code ?? "UNKNOWN";
|
|
@@ -1190,7 +1199,16 @@ function createApiError(statusCode, statusText, body, retryAfterHeader) {
|
|
|
1190
1199
|
const requestId = body.requestId;
|
|
1191
1200
|
const retryAfterSeconds = parseRetryAfterSeconds(retryAfterHeader ?? null);
|
|
1192
1201
|
const Ctor = ERROR_CODE_MAP[code] ?? AoudaApiError;
|
|
1193
|
-
return new Ctor(
|
|
1202
|
+
return new Ctor(
|
|
1203
|
+
message,
|
|
1204
|
+
code,
|
|
1205
|
+
statusCode,
|
|
1206
|
+
details,
|
|
1207
|
+
requestId,
|
|
1208
|
+
retryAfterSeconds,
|
|
1209
|
+
body.token,
|
|
1210
|
+
nonEmptyRowErrors(body.rowErrors)
|
|
1211
|
+
);
|
|
1194
1212
|
}
|
|
1195
1213
|
var HttpTransport = class {
|
|
1196
1214
|
constructor(options) {
|
|
@@ -1304,7 +1322,8 @@ var HttpTransport = class {
|
|
|
1304
1322
|
errorBody?.details,
|
|
1305
1323
|
errorBody?.requestId,
|
|
1306
1324
|
void 0,
|
|
1307
|
-
errorBody?.token
|
|
1325
|
+
errorBody?.token,
|
|
1326
|
+
nonEmptyRowErrors(errorBody?.rowErrors)
|
|
1308
1327
|
);
|
|
1309
1328
|
}
|
|
1310
1329
|
if (errorBody?.code != null) {
|
|
@@ -1423,7 +1442,8 @@ var HttpTransport = class {
|
|
|
1423
1442
|
errorBody?.details,
|
|
1424
1443
|
errorBody?.requestId,
|
|
1425
1444
|
void 0,
|
|
1426
|
-
errorBody?.token
|
|
1445
|
+
errorBody?.token,
|
|
1446
|
+
nonEmptyRowErrors(errorBody?.rowErrors)
|
|
1427
1447
|
);
|
|
1428
1448
|
}
|
|
1429
1449
|
if (errorBody?.code != null) {
|
|
@@ -2513,8 +2533,11 @@ var TableWriteStream = class {
|
|
|
2513
2533
|
resolve?.();
|
|
2514
2534
|
}
|
|
2515
2535
|
_handleServerError(message) {
|
|
2536
|
+
const rowErrors = Array.isArray(message.errors) && message.errors.length > 0 ? message.errors : void 0;
|
|
2516
2537
|
const error = new AoudaConnectionError(
|
|
2517
|
-
`Write stream error (${message.code}): ${message.message}
|
|
2538
|
+
`Write stream error (${message.code}): ${message.message}`,
|
|
2539
|
+
void 0,
|
|
2540
|
+
rowErrors
|
|
2518
2541
|
);
|
|
2519
2542
|
const openReject = this._openReject;
|
|
2520
2543
|
this._openResolve = null;
|
|
@@ -2966,6 +2989,12 @@ var TableQuery = class _TableQuery {
|
|
|
2966
2989
|
* evaluated per row on the server. Computed columns are appended after any physical-column
|
|
2967
2990
|
* `select()` projection.
|
|
2968
2991
|
*
|
|
2992
|
+
* Result types are inferred by the server where the expression permits
|
|
2993
|
+
* (e.g. Int32 → `number`). Uninferable expressions use wire `"Unknown"` /
|
|
2994
|
+
* codegen `unknown`. Computed columns are always nullable. Named-query
|
|
2995
|
+
* `*Row` properties pick this up when regenerated against a post-S08 server.
|
|
2996
|
+
* See aouda-docs/guides/browser-tier-read-limits.md#selectexpr-result-types
|
|
2997
|
+
*
|
|
2969
2998
|
* @param projections - One or more `{ alias, expr }` pairs.
|
|
2970
2999
|
* @returns A new TableQuery with computed columns set.
|
|
2971
3000
|
*
|