From 6c7ad2bfb7a5517fe6d3b8475f6586a5fc65d05b Mon Sep 17 00:00:00 2001 From: Alexey Timin Date: Fri, 8 May 2026 12:33:55 +0200 Subject: [PATCH 01/14] document lifecycle policy --- docs/cli/attachment/index.mdx | 8 +-- docs/cli/bucket/index.mdx | 10 +-- docs/cli/cp/index.mdx | 4 +- docs/cli/index.mdx | 20 +++--- docs/cli/replica/index.mdx | 18 ++--- docs/cli/rm/index.mdx | 2 +- docs/cli/token/index.mdx | 8 +-- docs/configuration/provisioning.mdx | 31 +++++++++ docs/configuration/settings.mdx | 5 +- docs/glossary.mdx | 6 ++ docs/guides/data-management.mdx | 9 +++ docs/reduct-bridge/index.mdx | 4 ++ docs/sdk/js/api/classes/APIError.md | 10 +-- docs/sdk/js/api/classes/Batch.md | 22 +++--- docs/sdk/js/api/classes/Bucket.md | 60 ++++++++-------- docs/sdk/js/api/classes/BucketInfo.md | 18 ++--- docs/sdk/js/api/classes/BucketSettings.md | 14 ++-- docs/sdk/js/api/classes/Client.md | 40 +++++------ docs/sdk/js/api/classes/EntryInfo.md | 18 ++--- .../sdk/js/api/classes/FullReplicationInfo.md | 10 +-- docs/sdk/js/api/classes/LicenseInfo.md | 18 ++--- docs/sdk/js/api/classes/QueryOptions.md | 24 +++---- docs/sdk/js/api/classes/RecordBatch.md | 22 +++--- docs/sdk/js/api/classes/ReplicationInfo.md | 14 ++-- .../sdk/js/api/classes/ReplicationSettings.md | 20 +++--- docs/sdk/js/api/classes/ServerInfo.md | 20 +++--- docs/sdk/js/api/classes/Token.md | 22 +++--- docs/sdk/js/api/classes/TokenCreateRequest.md | 12 ++-- docs/sdk/js/api/classes/TokenPermissions.md | 12 ++-- docs/sdk/js/api/enumerations/QuotaType.md | 8 +-- .../js/api/enumerations/RecordBatchType.md | 8 +-- docs/sdk/js/api/enumerations/Status.md | 6 +- docs/sdk/js/api/interfaces/WriteOptions.md | 8 +-- .../ReplicationMode/variables/DISABLED.md | 2 +- .../ReplicationMode/variables/ENABLED.md | 2 +- .../ReplicationMode/variables/PAUSED.md | 2 +- .../js/api/type-aliases/ReplicationMode.md | 2 +- docs/sdk/js/batch/index.mdx | 22 +++--- docs/sdk/js/bucket/index.mdx | 68 ++++++++++--------- docs/sdk/js/client/index.mdx | 40 +++++------ docs/sdk/js/error/index.mdx | 10 +-- docs/sdk/js/msg/bucket-info/index.mdx | 18 ++--- docs/sdk/js/msg/bucket-settings/index.mdx | 22 +++--- docs/sdk/js/msg/entry-info/index.mdx | 18 ++--- docs/sdk/js/msg/query-entry/index.mdx | 24 +++---- docs/sdk/js/msg/replication-info/index.mdx | 24 +++---- .../sdk/js/msg/replication-settings/index.mdx | 20 +++--- docs/sdk/js/msg/server-info/index.mdx | 38 +++++------ docs/sdk/js/msg/status/index.mdx | 6 +- docs/sdk/js/msg/token/index.mdx | 46 ++++++------- docs/sdk/js/record-batch/index.mdx | 30 ++++---- docs/sdk/py/bucket/index.mdx | 4 +- sidebars.json | 1 + 53 files changed, 488 insertions(+), 422 deletions(-) diff --git a/docs/cli/attachment/index.mdx b/docs/cli/attachment/index.mdx index fa186796..961c65e3 100644 --- a/docs/cli/attachment/index.mdx +++ b/docs/cli/attachment/index.mdx @@ -49,7 +49,7 @@ List attachment keys of an entry #### Arguments -- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) +- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) #### Options @@ -83,7 +83,7 @@ Read attachments of an entry #### Arguments -- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) +- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) - `[KEY]...`: Attachment keys to read #### Options @@ -119,7 +119,7 @@ Remove attachments from an entry #### Arguments -- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) +- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) - `[KEY]...`: Attachment keys to remove #### Options @@ -157,7 +157,7 @@ Write an attachment to an entry #### Arguments -- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) +- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) - ``: Attachment key - ``: Attachment value in JSON format diff --git a/docs/cli/bucket/index.mdx b/docs/cli/bucket/index.mdx index 82c1383b..ffec1b3a 100644 --- a/docs/cli/bucket/index.mdx +++ b/docs/cli/bucket/index.mdx @@ -87,7 +87,7 @@ Show bucket information #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -123,7 +123,7 @@ Create a bucket #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -165,7 +165,7 @@ Update bucket settings #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -207,7 +207,7 @@ Rename a bucket or an entry #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) - ``: New name for the bucket or entry #### Options @@ -245,7 +245,7 @@ Remove a bucket #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options diff --git a/docs/cli/cp/index.mdx b/docs/cli/cp/index.mdx index dc6d4575..627c4418 100644 --- a/docs/cli/cp/index.mdx +++ b/docs/cli/cp/index.mdx @@ -13,8 +13,8 @@ Copy data between instances or between an instance and the local filesystem ## Arguments -- ``: Source bucket or folder (e.g. SERVER_ALIAS/BUCKET, SERVER_ALIAS/\*, SERVER_ALIAS/test-\*, or ./folder) -- ``: Destination bucket, instance, or folder (e.g. SERVER_ALIAS/BUCKET, SERVER_ALIAS, or ./folder) +- ``: Source bucket or folder (e.g. SERVER\_ALIAS/BUCKET, SERVER\_ALIAS/\*, SERVER\_ALIAS/test-\*, or ./folder) +- ``: Destination bucket, instance, or folder (e.g. SERVER\_ALIAS/BUCKET, SERVER\_ALIAS, or ./folder) ## Options diff --git a/docs/cli/index.mdx b/docs/cli/index.mdx index 9afa5a27..4f5da300 100644 --- a/docs/cli/index.mdx +++ b/docs/cli/index.mdx @@ -12,16 +12,17 @@ sidebar_position: 0 [![GitHub all releases](https://img.shields.io/github/downloads/reductstore/reduct-cli/total)](https://github.com/reductstore/reduct-cli/releases/latest) [![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/reductstore/reduct-cli/ci.yml?branch=main)](https://github.com/reductstore/reduct-cli/actions) + The ReductStore CLI is a command line client for [ReductStore](https://www.reduct.store), a time series database for blob data. ## Features -- Support for ReductStore API v1.18 -- Easy management of buckets, tokens and replications -- Ability to check the status of a storage engine -- Aliases for storing server credentials -- Export and mirror data +* Support for ReductStore API v1.18 +* Easy management of buckets, tokens and replications +* Ability to check the status of a storage engine +* Aliases for storing server credentials +* Export and mirror data ## Installing @@ -74,13 +75,14 @@ reduct-cli cp play/* backup For more examples, see the [Guides](https://www.reduct.store/docs/guides) section in the ReductStore documentation. + ## Links -- [Project Homepage](https://www.reduct.store) -- [ReductStore Client SDK for Rust](https://github.com/reductstore/reduct-rs) -- [ReductStore](https://github.com/reductstore/reductstore) +* [Project Homepage](https://www.reduct.store) +* [ReductStore Client SDK for Rust](https://github.com/reductstore/reduct-rs) +* [ReductStore](https://github.com/reductstore/reductstore) -import DocCardList from "@theme/DocCardList"; +import DocCardList from '@theme/DocCardList'; ## Commands diff --git a/docs/cli/replica/index.mdx b/docs/cli/replica/index.mdx index 7704da52..d29bc041 100644 --- a/docs/cli/replica/index.mdx +++ b/docs/cli/replica/index.mdx @@ -53,9 +53,9 @@ Create a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) - ``: Source bucket on the replicated instance -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -103,8 +103,8 @@ Update a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -189,7 +189,7 @@ Show details about a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -223,7 +223,7 @@ Enable a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -257,7 +257,7 @@ Disable a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -291,7 +291,7 @@ Pause a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -325,7 +325,7 @@ Remove a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options diff --git a/docs/cli/rm/index.mdx b/docs/cli/rm/index.mdx index 37cae79e..56c2d52b 100644 --- a/docs/cli/rm/index.mdx +++ b/docs/cli/rm/index.mdx @@ -17,7 +17,7 @@ Remove data from a bucket ## Options -- `-b, --start `: Remove records with timestamps older than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will start from the first record in an entry. +- `-b, --start `: Remove records with timestamps older than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will start from the first record in an entry. - `-i, --ignore-ssl`: Ignore SSL certificate verification - `--ca-cert `: Path to a custom CA certificate bundle/file - `-e, --stop `: Remove records with timestamps newer than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will end at the last record in an entry. diff --git a/docs/cli/token/index.mdx b/docs/cli/token/index.mdx index 23f3be3b..242cb031 100644 --- a/docs/cli/token/index.mdx +++ b/docs/cli/token/index.mdx @@ -50,7 +50,7 @@ Create an access token #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -134,7 +134,7 @@ Rotate an access token value #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -168,7 +168,7 @@ Show token details #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options @@ -202,7 +202,7 @@ Remove an access token #### Arguments -- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) #### Options diff --git a/docs/configuration/provisioning.mdx b/docs/configuration/provisioning.mdx index ee6a5d5b..13fc2be2 100644 --- a/docs/configuration/provisioning.mdx +++ b/docs/configuration/provisioning.mdx @@ -81,3 +81,34 @@ For more information about the replication settings, see the **[Data Replication TLS verification for replication destinations is configured globally for the source instance with `RS_REPLICATION_VERIFY_SSL` and `RS_REPLICATION_CA_PATH`. These settings apply to all replication tasks created through provisioning, the HTTP API, SDKs, CLI, or the Web Console. + +## Lifecycle Provisioning + +You can provision lifecycle policies by setting environment variables. Lifecycle policies run in the background and currently support deleting old records from a bucket. + +| Name | Default | Description | +| ---------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------- | +| `RS_LIFECYCLE__NAME` | | Provisioned lifecycle policy name (required) | +| `RS_LIFECYCLE__TYPE` | delete | Lifecycle action type. Currently only `delete` is supported. | +| `RS_LIFECYCLE__BUCKET` | | Bucket to apply the lifecycle policy to (required) | +| `RS_LIFECYCLE__MAX_AGE` | | Maximum record age before deletion, for example `30d`, `24h`, or `3600s` (required) | +| `RS_LIFECYCLE__INTERVAL` | - | Interval between lifecycle runs, for example `10m`, `1h`, or `3600s` | +| `RS_LIFECYCLE__ENTRIES` | | Comma-separated list of entries to clean. If empty, all entries are matched. Prefix wildcards are supported. | +| `RS_LIFECYCLE__WHEN` | | JSON condition for records to delete. Uses the same condition syntax as queries, but `#ext` is not supported. | +| `RS_LIFECYCLE__MODE` | enabled | Policy mode: `enabled` or `disabled`. | + +Example: + +```env +RS_LIFECYCLE_A_NAME=purge-sensors-30d +RS_LIFECYCLE_A_TYPE=delete +RS_LIFECYCLE_A_BUCKET=telemetry +RS_LIFECYCLE_A_ENTRIES=sensors/*,env/temp,env/humidity +RS_LIFECYCLE_A_MAX_AGE=30d +RS_LIFECYCLE_A_INTERVAL=10m +RS_LIFECYCLE_A_WHEN={"$eq":["&label","true"]} +``` + +Provisioned lifecycle policies cannot be updated or removed through the API. Change their environment variables and restart ReductStore to update them. + +For more information about lifecycle policies, see the **[Lifecycle Policies Guide](../guides/lifecycle-policies.mdx)**. diff --git a/docs/configuration/settings.mdx b/docs/configuration/settings.mdx index 28b5bd59..ae2e6c80 100644 --- a/docs/configuration/settings.mdx +++ b/docs/configuration/settings.mdx @@ -177,7 +177,10 @@ ReductStore can persist aggregated API interactions in the `$audit` system bucke Notes: -- If `RS_AUDIT_ENABLED` is unset, audit defaults to `true` when `RS_API_TOKEN` is set, otherwise `false`. +- If `RS_AUDIT_ENABLED` is unset, audit defaults to `true` when `RS_API_TOKEN` is set or lifecycle policies are configured, otherwise `false`. - `RS_AUDIT_ENABLED` explicitly overrides the token-based default. - `RS_AUDIT_QUOTA_SIZE` is applied only when audit is enabled. - If `RS_AUDIT_QUOTA_SIZE` is unset, `$audit` capacity is unlimited. +- Audit records are stored as structured events with common fields: `type`, `timestamp`, `instance`, `entry_name`, `status`, `message`, and `payload`. +- API audit events use `type: "api_call"` and keep request details (`token_name`, `method`, `path`, `client_ip`, `call_count`, and `duration`) in `payload`. +- Lifecycle audit events use `type: "lifecycle_run"` and keep run details (`policy_name`, `action_type`, `bucket`, `duration`, `processed_records`, `error_code`, and `error_message`) in `payload`. diff --git a/docs/glossary.mdx b/docs/glossary.mdx index 1cf33ead..ce2fa6a3 100644 --- a/docs/glossary.mdx +++ b/docs/glossary.mdx @@ -124,3 +124,9 @@ A special instruction in a conditional query that modifies how the query engine ## query link A secure way to share data from ReductStore without using access tokens. Query links can be created with a specific query and expiration time, allowing controlled access to data. + +## lifecycle policy + +A background task that periodically applies an action (such as deleting old records) to a bucket. Lifecycle policies can be scoped to specific entries and filtered with a conditional query. + +_Related entries:_ bucket, record, conditional query diff --git a/docs/guides/data-management.mdx b/docs/guides/data-management.mdx index 5ba8db43..97d4f342 100644 --- a/docs/guides/data-management.mdx +++ b/docs/guides/data-management.mdx @@ -128,6 +128,15 @@ Attachment keys starting with `$` are reserved for official ReductStore plugins The ReductStore API allows you to delete specific records from an entry, an entire entry, or an entire **[bucket](../glossary#bucket)**. You can do this using the Client SDKs, the Reduct CLI, or the HTTP API. +### Automatic Deletion With Lifecycle Policies + +For automatic cleanup, use lifecycle policies. A delete lifecycle policy periodically +removes records older than `max_age` from a bucket. You can limit cleanup to selected +entries with `entries` and to matching records with a `when` condition. + +For a full explanation and provisioning examples, see the +**[Lifecycle Policies](lifecycle-policies.mdx)** guide. + ### Deleting Entry or Bucket The following examples show how to delete the entire entry or the entire bucket: diff --git a/docs/reduct-bridge/index.mdx b/docs/reduct-bridge/index.mdx index e908a1d3..f64d696a 100644 --- a/docs/reduct-bridge/index.mdx +++ b/docs/reduct-bridge/index.mdx @@ -22,6 +22,7 @@ An `input` is a data source. It reads data from a system and produces records fo Supported input types include: - **[Metrics](./input/metrics/index.mdx)** - collect host CPU, memory, and disk metrics as JSON records. +- **[MQTT](./input/mqtt/index.mdx)** - subscribe to MQTT v3/v5 topics over `mqtt://` or `mqtts://` and store raw payloads with optional payload/property label mapping. - **[Shell](./input/shell/index.mdx)** - run shell commands on a fixed interval and store output lines as records. - **[ROS1](./input/ros1/index.mdx)** - subscribe to ROS1 topics and store ROS messages as records. - **[ROS2](./input/ros2/index.mdx)** - subscribe to ROS2 topics and store serialized CDR payloads as records. @@ -90,6 +91,8 @@ cargo install reduct-bridge ``` `cargo install reduct-bridge` builds the default feature set, which includes only the `shell` input. +For MQTT-specific build and runtime guidance, see **[MQTT input documentation](./input/mqtt/index.mdx)**. +The MQTT input is grouped under the `iot` Cargo feature alongside future IoT protocols. For metrics-specific build and runtime guidance, see **[Metrics input documentation](./input/metrics/index.mdx)**. For ROS2-specific build and runtime guidance, see **[ROS2 input documentation](./input/ros2/index.mdx)**. @@ -97,6 +100,7 @@ To build additional inputs explicitly from source: ```bash cargo build --no-default-features --features ros1 +cargo build --no-default-features --features shell,metrics,iot cargo build --no-default-features --features all-inputs ``` diff --git a/docs/sdk/js/api/classes/APIError.md b/docs/sdk/js/api/classes/APIError.md index f7c6ce2e..94299621 100644 --- a/docs/sdk/js/api/classes/APIError.md +++ b/docs/sdk/js/api/classes/APIError.md @@ -9,7 +9,7 @@ description: "API reference for APIError in the ReductStore Client SDK for JavaS # APIError -Defined in: [APIError.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L4) +Defined in: [APIError.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L4) Represents HTTP Error @@ -19,7 +19,7 @@ Represents HTTP Error > **new APIError**(`message`, `status?`, `original?`): `APIError` -Defined in: [APIError.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L23) +Defined in: [APIError.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L23) Create an error from HTTP status and message @@ -47,7 +47,7 @@ Create an error from HTTP status and message > `optional` **message**: `string` -Defined in: [APIError.ts:13](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L13) +Defined in: [APIError.ts:13](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L13) Parsed message from the storage engine @@ -57,7 +57,7 @@ Parsed message from the storage engine > `optional` **original**: `unknown` -Defined in: [APIError.ts:18](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L18) +Defined in: [APIError.ts:18](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L18) Original error from HTTP client with the full information @@ -67,6 +67,6 @@ Original error from HTTP client with the full information > `optional` **status**: `number` -Defined in: [APIError.ts:8](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L8) +Defined in: [APIError.ts:8](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L8) HTTP status of error. If it is empty, it means communication problem diff --git a/docs/sdk/js/api/classes/Batch.md b/docs/sdk/js/api/classes/Batch.md index 3b2b8c9f..d8ea4a76 100644 --- a/docs/sdk/js/api/classes/Batch.md +++ b/docs/sdk/js/api/classes/Batch.md @@ -9,7 +9,7 @@ description: "API reference for Batch in the ReductStore Client SDK for JavaScri # Batch -Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L15) +Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L15) ## Constructors @@ -17,7 +17,7 @@ Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718 > **new Batch**(`bucketName`, `entryName`, `httpClient`, `type`): `Batch` -Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L33) +Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L33) #### Parameters @@ -47,7 +47,7 @@ Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718 > **add**(`ts`, `data`, `contentType?`, `labels?`): `void` -Defined in: [Batch.ts:55](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L55) +Defined in: [Batch.ts:55](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L55) Add record to batch @@ -87,7 +87,7 @@ default: {} > **addOnlyLabels**(`ts`, `labels`): `void` -Defined in: [Batch.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L82) +Defined in: [Batch.ts:82](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L82) Add only labels to batch Use for updating labels @@ -114,7 +114,7 @@ timestamp of record as a UNIX timestamp in microseconds > **addOnlyTimestamp**(`ts`): `void` -Defined in: [Batch.ts:95](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L95) +Defined in: [Batch.ts:95](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L95) Add only timestamp to batch Use for removing records @@ -137,7 +137,7 @@ timestamp of record as a UNIX timestamp in microseconds > **clear**(): `void` -Defined in: [Batch.ts:218](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L218) +Defined in: [Batch.ts:218](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L218) Clear batch @@ -151,7 +151,7 @@ Clear batch > **items**(): `IterableIterator`\<\[`bigint`, \{ `contentType`: `string`; `data`: `Buffer`; `labels`: `LabelMap`; \}\]\> -Defined in: [Batch.ts:184](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L184) +Defined in: [Batch.ts:184](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L184) Get records in batch sorted by timestamp @@ -165,7 +165,7 @@ Get records in batch sorted by timestamp > **lastAccessTime**(): `number` -Defined in: [Batch.ts:204](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L204) +Defined in: [Batch.ts:204](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L204) Get last access time of batch @@ -179,7 +179,7 @@ Get last access time of batch > **recordCount**(): `number` -Defined in: [Batch.ts:211](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L211) +Defined in: [Batch.ts:211](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L211) Get number of records in batch @@ -193,7 +193,7 @@ Get number of records in batch > **size**(): `bigint` -Defined in: [Batch.ts:197](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L197) +Defined in: [Batch.ts:197](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L197) Get total size of batch @@ -207,7 +207,7 @@ Get total size of batch > **write**(): `Promise`\<`Map`\<`bigint`, [`APIError`](APIError.md)\>\> -Defined in: [Batch.ts:107](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L107) +Defined in: [Batch.ts:107](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L107) Write batch to entry diff --git a/docs/sdk/js/api/classes/Bucket.md b/docs/sdk/js/api/classes/Bucket.md index 290ebc44..52abad20 100644 --- a/docs/sdk/js/api/classes/Bucket.md +++ b/docs/sdk/js/api/classes/Bucket.md @@ -9,7 +9,7 @@ description: "API reference for Bucket in the ReductStore Client SDK for JavaScr # Bucket -Defined in: [Bucket.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L27) +Defined in: [Bucket.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L28) Represents a bucket in ReductStore @@ -19,7 +19,7 @@ Represents a bucket in ReductStore > **new Bucket**(`name`, `httpClient`): `Bucket` -Defined in: [Bucket.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L38) +Defined in: [Bucket.ts:39](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L39) Create a bucket. Use Client.creatBucket or Client.getBucket instead it @@ -45,7 +45,7 @@ Create a bucket. Use Client.creatBucket or Client.getBucket instead it > **beginRead**(`entry`, `ts?`, `head?`): `Promise`\<`ReadableRecord`\> -Defined in: [Bucket.ts:233](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L233) +Defined in: [Bucket.ts:234](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L234) Start reading a record from an entry @@ -81,7 +81,7 @@ Promise<ReadableRecord> > **beginRemoveBatch**(`entry`): `Promise`\<[`Batch`](Batch.md)\> -Defined in: [Bucket.ts:121](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L121) +Defined in: [Bucket.ts:122](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L122) Remove a batch of records @@ -103,7 +103,7 @@ Remove a batch of records > **beginRemoveRecordBatch**(): [`RecordBatch`](RecordBatch.md) -Defined in: [Bucket.ts:478](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L478) +Defined in: [Bucket.ts:479](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L479) Create a new batch for removing records across multiple entries. @@ -117,7 +117,7 @@ Create a new batch for removing records across multiple entries. > **beginUpdateBatch**(`entry`): `Promise`\<[`Batch`](Batch.md)\> -Defined in: [Bucket.ts:459](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L459) +Defined in: [Bucket.ts:460](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L460) Create a new batch for updating records in the database. @@ -137,7 +137,7 @@ Create a new batch for updating records in the database. > **beginUpdateRecordBatch**(): [`RecordBatch`](RecordBatch.md) -Defined in: [Bucket.ts:471](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L471) +Defined in: [Bucket.ts:472](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L472) Create a new batch for updating records across multiple entries. @@ -160,7 +160,7 @@ await batch.send(); > **beginWrite**(`entry`, `options?`): `Promise`\<`WritableRecord`\> -Defined in: [Bucket.ts:184](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L184) +Defined in: [Bucket.ts:185](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L185) Start writing a record into an entry @@ -201,7 +201,7 @@ await record.write("Hello!"); > **beginWriteBatch**(`entry`): `Promise`\<[`Batch`](Batch.md)\> -Defined in: [Bucket.ts:439](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L439) +Defined in: [Bucket.ts:440](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L440) Create a new batch for writing records to the database. @@ -221,7 +221,7 @@ Create a new batch for writing records to the database. > **beginWriteRecordBatch**(): [`RecordBatch`](RecordBatch.md) -Defined in: [Bucket.ts:451](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L451) +Defined in: [Bucket.ts:452](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L452) Create a new batch for writing records to multiple entries. @@ -244,7 +244,7 @@ await batch.send(); > **createQueryLink**(`entry`, `start?`, `stop?`, `query?`, `record?`, `expireAt?`, `fileName?`, `baseUrl?`): `Promise`\<`string`\> -Defined in: [Bucket.ts:495](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L495) +Defined in: [Bucket.ts:496](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L496) Create a query link for downloading records @@ -310,7 +310,7 @@ base url for link generation. If not set, the server's base url will be used > **getEntryList**(): `Promise`\<[`EntryInfo`](EntryInfo.md)[]\> -Defined in: [Bucket.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L82) +Defined in: [Bucket.ts:83](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L83) Get entry list @@ -326,7 +326,7 @@ Get entry list > **getInfo**(): `Promise`\<[`BucketInfo`](BucketInfo.md)\> -Defined in: [Bucket.ts:72](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L72) +Defined in: [Bucket.ts:73](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L73) Get information about a bucket @@ -342,7 +342,7 @@ Get information about a bucket > **getName**(): `string` -Defined in: [Bucket.ts:350](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L350) +Defined in: [Bucket.ts:351](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L351) #### Returns @@ -354,7 +354,7 @@ Defined in: [Bucket.ts:350](https://github.com/reductstore/reduct-js/blob/e2b7a7 > **getSettings**(): `Promise`\<[`BucketSettings`](BucketSettings.md)\> -Defined in: [Bucket.ts:50](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L50) +Defined in: [Bucket.ts:51](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L51) Get bucket settings @@ -370,7 +370,7 @@ Get bucket settings > **query**(`entry`, `start?`, `stop?`, `options?`): `AsyncGenerator`\<`ReadableRecord`\> -Defined in: [Bucket.ts:295](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L295) +Defined in: [Bucket.ts:296](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L296) Query records for a time interval as generator @@ -423,7 +423,7 @@ for await (const record in bucket.query("entry-1", start, stop)) { > **readAttachments**(`entry`): `Promise`\<`Record`\<`string`, `unknown`\>\> -Defined in: [Bucket.ts:616](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L616) +Defined in: [Bucket.ts:617](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L617) Read attachments from an entry. @@ -447,7 +447,7 @@ map of attachment key to decoded JSON value > **remove**(): `Promise`\<`void`\> -Defined in: [Bucket.ts:94](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L94) +Defined in: [Bucket.ts:95](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L95) Remove bucket @@ -463,7 +463,7 @@ Remove bucket > **removeAttachments**(`entry`, `attachmentKeys?`): `Promise`\<`void`\> -Defined in: [Bucket.ts:640](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L640) +Defined in: [Bucket.ts:646](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L646) Remove attachments from an entry. @@ -493,7 +493,7 @@ list of keys to remove > **removeEntry**(`entry`): `Promise`\<`void`\> -Defined in: [Bucket.ts:104](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L104) +Defined in: [Bucket.ts:105](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L105) Remove an entry @@ -517,7 +517,7 @@ Remove an entry > **removeQuery**(`entry`, `start?`, `stop?`, `options?`): `Promise`\<`number`\> -Defined in: [Bucket.ts:132](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L132) +Defined in: [Bucket.ts:133](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L133) Remove records by query @@ -557,7 +557,7 @@ Remove records by query > **removeRecord**(`entry`, `ts`): `Promise`\<`void`\> -Defined in: [Bucket.ts:113](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L113) +Defined in: [Bucket.ts:114](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L114) Remove a record @@ -585,7 +585,7 @@ Remove a record > **rename**(`newName`): `Promise`\<`void`\> -Defined in: [Bucket.ts:266](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L266) +Defined in: [Bucket.ts:267](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L267) Rename a bucket @@ -607,7 +607,7 @@ new name of the bucket > **renameEntry**(`entry`, `newEntry`): `Promise`\<`void`\> -Defined in: [Bucket.ts:250](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L250) +Defined in: [Bucket.ts:251](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L251) Rename an entry @@ -635,7 +635,7 @@ new entry name > **setSettings**(`settings`): `Promise`\<`void`\> -Defined in: [Bucket.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L60) +Defined in: [Bucket.ts:61](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L61) Set bucket settings @@ -659,7 +659,7 @@ Set bucket settings > **update**(`entry`, `ts`, `labels`): `Promise`\<`void`\> -Defined in: [Bucket.ts:212](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L212) +Defined in: [Bucket.ts:213](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L213) Update labels of an existing record @@ -693,9 +693,9 @@ If a label has empty string value, it will be removed. ### writeAttachments() -> **writeAttachments**(`entry`, `attachments`): `Promise`\<`void`\> +> **writeAttachments**(`entry`, `attachments`, `contentType?`): `Promise`\<`void`\> -Defined in: [Bucket.ts:587](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L587) +Defined in: [Bucket.ts:588](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L588) Write attachments to an entry. @@ -715,6 +715,10 @@ name of the source entry map of attachment key to JSON-serializable content +##### contentType? + +`string` + #### Returns `Promise`\<`void`\> diff --git a/docs/sdk/js/api/classes/BucketInfo.md b/docs/sdk/js/api/classes/BucketInfo.md index e1d664ee..6653f7b1 100644 --- a/docs/sdk/js/api/classes/BucketInfo.md +++ b/docs/sdk/js/api/classes/BucketInfo.md @@ -9,7 +9,7 @@ description: "API reference for BucketInfo in the ReductStore Client SDK for Jav # BucketInfo -Defined in: [messages/BucketInfo.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L6) +Defined in: [messages/BucketInfo.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L6) Represents information about a bucket @@ -29,7 +29,7 @@ Represents information about a bucket > `readonly` **entryCount**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L15) +Defined in: [messages/BucketInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L15) Number of entries in the bucket @@ -39,7 +39,7 @@ Number of entries in the bucket > `readonly` `optional` **isProvisioned**: `boolean` = `false` -Defined in: [messages/BucketInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L35) +Defined in: [messages/BucketInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L35) Is the bucket provisioned, and you can't remove it or change its settings @@ -49,7 +49,7 @@ Is the bucket provisioned, and you can't remove it or change its settings > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L30) +Defined in: [messages/BucketInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L30) Unix timestamp of the latest record in microseconds @@ -59,7 +59,7 @@ Unix timestamp of the latest record in microseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/BucketInfo.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L10) +Defined in: [messages/BucketInfo.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L10) Name of the bucket @@ -69,7 +69,7 @@ Name of the bucket > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L25) +Defined in: [messages/BucketInfo.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L25) Unix timestamp of the oldest record in microseconds @@ -79,7 +79,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **size**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L20) +Defined in: [messages/BucketInfo.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L20) Size of stored data in the bucket in bytes @@ -89,7 +89,7 @@ Size of stored data in the bucket in bytes > `readonly` **status**: [`Status`](../enumerations/Status.md) = `Status.READY` -Defined in: [messages/BucketInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L40) +Defined in: [messages/BucketInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L40) Current status of the bucket (READY or DELETING) @@ -99,7 +99,7 @@ Current status of the bucket (READY or DELETING) > `static` **parse**(`bucket`): `BucketInfo` -Defined in: [messages/BucketInfo.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L42) +Defined in: [messages/BucketInfo.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L42) #### Parameters diff --git a/docs/sdk/js/api/classes/BucketSettings.md b/docs/sdk/js/api/classes/BucketSettings.md index ee3d9606..4f1545a7 100644 --- a/docs/sdk/js/api/classes/BucketSettings.md +++ b/docs/sdk/js/api/classes/BucketSettings.md @@ -9,7 +9,7 @@ description: "API reference for BucketSettings in the ReductStore Client SDK for # BucketSettings -Defined in: [messages/BucketSettings.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L10) +Defined in: [messages/BucketSettings.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L10) Represents bucket settings @@ -29,7 +29,7 @@ Represents bucket settings > `readonly` `optional` **maxBlockRecords**: `bigint` -Defined in: [messages/BucketSettings.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L19) +Defined in: [messages/BucketSettings.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L19) Maximum number of records in a block @@ -39,7 +39,7 @@ Maximum number of records in a block > `readonly` `optional` **maxBlockSize**: `bigint` -Defined in: [messages/BucketSettings.ts:14](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L14) +Defined in: [messages/BucketSettings.ts:14](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L14) Maximal block size in a block @@ -49,7 +49,7 @@ Maximal block size in a block > `readonly` `optional` **quotaSize**: `bigint` -Defined in: [messages/BucketSettings.ts:31](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L31) +Defined in: [messages/BucketSettings.ts:31](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L31) Quota size in bytes @@ -59,7 +59,7 @@ Quota size in bytes > `readonly` `optional` **quotaType**: [`QuotaType`](../enumerations/QuotaType.md) -Defined in: [messages/BucketSettings.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L26) +Defined in: [messages/BucketSettings.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L26) Quota type. The storage supports two types: NONE: A bucket will consume the whole free disk space. @@ -71,7 +71,7 @@ Quota type. The storage supports two types: > `static` **parse**(`data`): `BucketSettings` -Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L33) +Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L33) #### Parameters @@ -89,7 +89,7 @@ Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduc > `static` **serialize**(`settings`): `OriginalBucketSettings` -Defined in: [messages/BucketSettings.ts:46](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L46) +Defined in: [messages/BucketSettings.ts:46](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L46) #### Parameters diff --git a/docs/sdk/js/api/classes/Client.md b/docs/sdk/js/api/classes/Client.md index 6354416c..ad00465d 100644 --- a/docs/sdk/js/api/classes/Client.md +++ b/docs/sdk/js/api/classes/Client.md @@ -9,7 +9,7 @@ description: "API reference for Client in the ReductStore Client SDK for JavaScr # Client -Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L43) +Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L43) ## Constructors @@ -17,7 +17,7 @@ Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a71 > **new Client**(`url`, `options`): `Client` -Defined in: [Client.ts:51](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L51) +Defined in: [Client.ts:51](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L51) HTTP Client for ReductStore @@ -43,7 +43,7 @@ URL to the storage > **close**(): `Promise`\<`void`\> -Defined in: [Client.ts:68](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L68) +Defined in: [Client.ts:68](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L68) Close underlying HTTP resources (Node.js only). @@ -57,7 +57,7 @@ Close underlying HTTP resources (Node.js only). > **createBucket**(`name`, `settings?`): `Promise`\<[`Bucket`](Bucket.md)\> -Defined in: [Client.ts:91](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L91) +Defined in: [Client.ts:91](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L91) Create a new bucket @@ -85,7 +85,7 @@ optional settings > **createReplication**(`name`, `settings`): `Promise`\<`void`\> -Defined in: [Client.ts:246](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L246) +Defined in: [Client.ts:246](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L246) Create a new replication @@ -113,7 +113,7 @@ settings of the replication > **createToken**(`name`, `permissionsOrRequest`): `Promise`\<`string`\> -Defined in: [Client.ts:141](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L141) +Defined in: [Client.ts:141](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L141) Create a new access token @@ -150,7 +150,7 @@ const client = new Client("https://play.storage-reduct.dev", {apiToken: token}); > **deleteReplication**(`name`): `Promise`\<`void`\> -Defined in: [Client.ts:287](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L287) +Defined in: [Client.ts:287](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L287) Delete a replication @@ -172,7 +172,7 @@ name of the replication > **deleteToken**(`name`): `Promise`\<`void`\> -Defined in: [Client.ts:202](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L202) +Defined in: [Client.ts:202](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L202) Delete a token by name @@ -194,7 +194,7 @@ name of the token > **getBucket**(`name`): `Promise`\<[`Bucket`](Bucket.md)\> -Defined in: [Client.ts:104](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L104) +Defined in: [Client.ts:104](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L104) Get a bucket by name @@ -216,7 +216,7 @@ name of the bucket > **getBucketList**(): `Promise`\<[`BucketInfo`](BucketInfo.md)[]\> -Defined in: [Client.ts:78](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L78) +Defined in: [Client.ts:78](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L78) Get list of buckets @@ -236,7 +236,7 @@ BucketInfo > **getInfo**(): `Promise`\<[`ServerInfo`](ServerInfo.md)\> -Defined in: [Client.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L60) +Defined in: [Client.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L60) Get server information @@ -254,7 +254,7 @@ the data about the server > **getOrCreateBucket**(`name`, `settings?`): `Promise`\<[`Bucket`](Bucket.md)\> -Defined in: [Client.ts:115](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L115) +Defined in: [Client.ts:115](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L115) Try to create a bucket and get it if it already exists @@ -282,7 +282,7 @@ optional settings > **getReplication**(`name`): `Promise`\<[`FullReplicationInfo`](FullReplicationInfo.md)\> -Defined in: [Client.ts:233](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L233) +Defined in: [Client.ts:233](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L233) Get full information about a replication @@ -306,7 +306,7 @@ the replication > **getReplicationList**(): `Promise`\<[`ReplicationInfo`](ReplicationInfo.md)[]\> -Defined in: [Client.ts:219](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L219) +Defined in: [Client.ts:219](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L219) Get the list of replications @@ -322,7 +322,7 @@ the list of replications > **getToken**(`name`): `Promise`\<[`Token`](Token.md)\> -Defined in: [Client.ts:180](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L180) +Defined in: [Client.ts:180](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L180) Get a token by name @@ -346,7 +346,7 @@ the token > **getTokenList**(): `Promise`\<[`Token`](Token.md)[]\> -Defined in: [Client.ts:191](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L191) +Defined in: [Client.ts:191](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L191) List all tokens @@ -362,7 +362,7 @@ the list of tokens > **me**(): `Promise`\<[`Token`](Token.md)\> -Defined in: [Client.ts:210](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L210) +Defined in: [Client.ts:210](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L210) Get current API token and its permissions @@ -378,7 +378,7 @@ the token > **rotateToken**(`name`): `Promise`\<`string`\> -Defined in: [Client.ts:167](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L167) +Defined in: [Client.ts:167](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L167) Rotate a token by name @@ -402,7 +402,7 @@ new token value > **setReplicationMode**(`name`, `mode`): `Promise`\<`void`\> -Defined in: [Client.ts:278](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L278) +Defined in: [Client.ts:278](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L278) Update replication mode without changing settings @@ -430,7 +430,7 @@ new mode: enabled, paused, or disabled > **updateReplication**(`name`, `settings`): `Promise`\<`void`\> -Defined in: [Client.ts:262](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L262) +Defined in: [Client.ts:262](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L262) Update a replication diff --git a/docs/sdk/js/api/classes/EntryInfo.md b/docs/sdk/js/api/classes/EntryInfo.md index 7caf36fd..5eebea72 100644 --- a/docs/sdk/js/api/classes/EntryInfo.md +++ b/docs/sdk/js/api/classes/EntryInfo.md @@ -9,7 +9,7 @@ description: "API reference for EntryInfo in the ReductStore Client SDK for Java # EntryInfo -Defined in: [messages/EntryInfo.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L6) +Defined in: [messages/EntryInfo.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L6) Information about entry @@ -29,7 +29,7 @@ Information about entry > `readonly` **blockCount**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L15) +Defined in: [messages/EntryInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L15) Number of blocks @@ -39,7 +39,7 @@ Number of blocks > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L35) +Defined in: [messages/EntryInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L35) Unix timestamp of the latest record in microseconds @@ -49,7 +49,7 @@ Unix timestamp of the latest record in microseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/EntryInfo.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L10) +Defined in: [messages/EntryInfo.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L10) Name of the entry @@ -59,7 +59,7 @@ Name of the entry > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L30) +Defined in: [messages/EntryInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L30) Unix timestamp of the oldest record in microseconds @@ -69,7 +69,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **recordCount**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L20) +Defined in: [messages/EntryInfo.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L20) Number of records @@ -79,7 +79,7 @@ Number of records > `readonly` **size**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L25) +Defined in: [messages/EntryInfo.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L25) Size of stored data in the bucket in bytes @@ -89,7 +89,7 @@ Size of stored data in the bucket in bytes > `readonly` **status**: [`Status`](../enumerations/Status.md) = `Status.READY` -Defined in: [messages/EntryInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L40) +Defined in: [messages/EntryInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L40) Current status of the entry (READY or DELETING) @@ -99,7 +99,7 @@ Current status of the entry (READY or DELETING) > `static` **parse**(`bucket`): `EntryInfo` -Defined in: [messages/EntryInfo.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L42) +Defined in: [messages/EntryInfo.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L42) #### Parameters diff --git a/docs/sdk/js/api/classes/FullReplicationInfo.md b/docs/sdk/js/api/classes/FullReplicationInfo.md index d88eadbc..6906a44d 100644 --- a/docs/sdk/js/api/classes/FullReplicationInfo.md +++ b/docs/sdk/js/api/classes/FullReplicationInfo.md @@ -9,7 +9,7 @@ description: "API reference for FullReplicationInfo in the ReductStore Client SD # FullReplicationInfo -Defined in: [messages/ReplicationInfo.ts:66](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L66) +Defined in: [messages/ReplicationInfo.ts:66](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L66) Replication full info @@ -29,7 +29,7 @@ Replication full info > `readonly` **diagnostics**: `Diagnostics` -Defined in: [messages/ReplicationInfo.ts:80](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L80) +Defined in: [messages/ReplicationInfo.ts:80](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L80) Replication statistics @@ -39,7 +39,7 @@ Replication statistics > `readonly` **info**: [`ReplicationInfo`](ReplicationInfo.md) -Defined in: [messages/ReplicationInfo.ts:70](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L70) +Defined in: [messages/ReplicationInfo.ts:70](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L70) Replication info @@ -49,7 +49,7 @@ Replication info > `readonly` **settings**: [`ReplicationSettings`](ReplicationSettings.md) -Defined in: [messages/ReplicationInfo.ts:75](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L75) +Defined in: [messages/ReplicationInfo.ts:75](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L75) Replication settings @@ -59,7 +59,7 @@ Replication settings > `static` **parse**(`data`): `FullReplicationInfo` -Defined in: [messages/ReplicationInfo.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L82) +Defined in: [messages/ReplicationInfo.ts:82](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L82) #### Parameters diff --git a/docs/sdk/js/api/classes/LicenseInfo.md b/docs/sdk/js/api/classes/LicenseInfo.md index ee3f1fcc..c40a955a 100644 --- a/docs/sdk/js/api/classes/LicenseInfo.md +++ b/docs/sdk/js/api/classes/LicenseInfo.md @@ -9,7 +9,7 @@ description: "API reference for LicenseInfo in the ReductStore Client SDK for Ja # LicenseInfo -Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L7) +Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L7) ## Constructors @@ -27,7 +27,7 @@ Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/ > `readonly` **deviceNumber**: `number` = `0` -Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L17) +Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L17) *** @@ -35,7 +35,7 @@ Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js > `readonly` **diskQuota**: `number` = `0` -Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L19) +Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L19) *** @@ -43,7 +43,7 @@ Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js > `readonly` **expiryDate**: `number` = `0` -Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L13) +Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L13) *** @@ -51,7 +51,7 @@ Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js > `readonly` **fingerprint**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L21) +Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L21) *** @@ -59,7 +59,7 @@ Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js > `readonly` **invoice**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L11) +Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L11) *** @@ -67,7 +67,7 @@ Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js > `readonly` **licensee**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L9) +Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L9) *** @@ -75,7 +75,7 @@ Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/ > `readonly` **plan**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L15) +Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L15) ## Methods @@ -83,7 +83,7 @@ Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js > `static` **parse**(`data`): `LicenseInfo` -Defined in: [messages/ServerInfo.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L23) +Defined in: [messages/ServerInfo.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L23) #### Parameters diff --git a/docs/sdk/js/api/classes/QueryOptions.md b/docs/sdk/js/api/classes/QueryOptions.md index 540ace4e..91afd0df 100644 --- a/docs/sdk/js/api/classes/QueryOptions.md +++ b/docs/sdk/js/api/classes/QueryOptions.md @@ -9,7 +9,7 @@ description: "API reference for QueryOptions in the ReductStore Client SDK for J # QueryOptions -Defined in: [messages/QueryEntry.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L38) +Defined in: [messages/QueryEntry.ts:38](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L38) Options for querying records @@ -29,7 +29,7 @@ Options for querying records > `optional` **continuous**: `boolean` -Defined in: [messages/QueryEntry.ts:55](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L55) +Defined in: [messages/QueryEntry.ts:55](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L55) Don't stop query until TTL is reached @@ -39,7 +39,7 @@ Don't stop query until TTL is reached > `optional` **eachN**: `number` -Defined in: [messages/QueryEntry.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L48) +Defined in: [messages/QueryEntry.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L48) Return only one record per N records @deprecated: use $each_n operator in when instead. Will be remove in v1.18.0 @@ -50,7 +50,7 @@ Return only one record per N records > `optional` **eachS**: `number` -Defined in: [messages/QueryEntry.ts:44](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L44) +Defined in: [messages/QueryEntry.ts:44](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L44) Return only one record per S second @deprecated: use $each_t operator in when instead. Will be remove in v1.18.0 @@ -61,7 +61,7 @@ Return only one record per S second > `optional` **ext**: `Record`\<`string`, `any`\> -Defined in: [messages/QueryEntry.ts:65](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L65) +Defined in: [messages/QueryEntry.ts:65](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L65) Additional parameters for extensions @@ -71,7 +71,7 @@ Additional parameters for extensions > `optional` **head**: `boolean` -Defined in: [messages/QueryEntry.ts:59](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L59) +Defined in: [messages/QueryEntry.ts:59](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L59) Return only metadata @@ -81,7 +81,7 @@ Return only metadata > `optional` **limit**: `number` -Defined in: [messages/QueryEntry.ts:52](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L52) +Defined in: [messages/QueryEntry.ts:52](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L52) Limit number of records @deprecated: use $limit operator in when instead. Will be remove in v1.18.0 @@ -92,7 +92,7 @@ Limit number of records > `optional` **pollInterval**: `number` -Defined in: [messages/QueryEntry.ts:57](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L57) +Defined in: [messages/QueryEntry.ts:57](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L57) Poll interval for new records only for continue=true @@ -102,7 +102,7 @@ Poll interval for new records only for continue=true > `optional` **strict**: `boolean` -Defined in: [messages/QueryEntry.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L63) +Defined in: [messages/QueryEntry.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L63) strict conditional query @@ -112,7 +112,7 @@ strict conditional query > `optional` **ttl**: `number` -Defined in: [messages/QueryEntry.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L40) +Defined in: [messages/QueryEntry.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L40) Time to live in seconds @@ -122,7 +122,7 @@ Time to live in seconds > `optional` **when**: `Record`\<`string`, `any`\> -Defined in: [messages/QueryEntry.ts:61](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L61) +Defined in: [messages/QueryEntry.ts:61](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L61) Conditional query @@ -132,7 +132,7 @@ Conditional query > `static` **serialize**(`queryType`, `data`, `start?`, `stop?`, `entries?`): `QueryEntry` -Defined in: [messages/QueryEntry.ts:67](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L67) +Defined in: [messages/QueryEntry.ts:67](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L67) #### Parameters diff --git a/docs/sdk/js/api/classes/RecordBatch.md b/docs/sdk/js/api/classes/RecordBatch.md index 5ed21bbc..354e3f07 100644 --- a/docs/sdk/js/api/classes/RecordBatch.md +++ b/docs/sdk/js/api/classes/RecordBatch.md @@ -9,7 +9,7 @@ description: "API reference for RecordBatch in the ReductStore Client SDK for Ja # RecordBatch -Defined in: [RecordBatch.ts:34](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L34) +Defined in: [RecordBatch.ts:34](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L34) Batch of records to write them in one request (batch protocol v2). @@ -19,7 +19,7 @@ Batch of records to write them in one request (batch protocol v2). > **new RecordBatch**(`bucketName`, `httpClient`, `type`): `RecordBatch` -Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L42) +Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L42) #### Parameters @@ -45,7 +45,7 @@ Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/e2 > **add**(`entry`, `ts`, `data`, `contentType?`, `labels?`): `void` -Defined in: [RecordBatch.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L63) +Defined in: [RecordBatch.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L63) Add record to batch with entry name. @@ -91,7 +91,7 @@ default: {} > **addOnlyLabels**(`entry`, `ts`, `labels`): `void` -Defined in: [RecordBatch.ts:97](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L97) +Defined in: [RecordBatch.ts:97](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L97) Add labels to batch for update. @@ -125,7 +125,7 @@ labels to update > **addOnlyTimestamp**(`entry`, `ts`): `void` -Defined in: [RecordBatch.ts:119](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L119) +Defined in: [RecordBatch.ts:119](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L119) Add timestamps to batch for removal. @@ -153,7 +153,7 @@ timestamp of record as a UNIX timestamp in microseconds > **clear**(): `void` -Defined in: [RecordBatch.ts:259](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L259) +Defined in: [RecordBatch.ts:259](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L259) Clear batch @@ -167,7 +167,7 @@ Clear batch > **items**(): \[\[`string`, `bigint`\], `RecordBatchItem`\][] -Defined in: [RecordBatch.ts:212](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L212) +Defined in: [RecordBatch.ts:212](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L212) Get records in batch sorted by timestamp and entry name. @@ -181,7 +181,7 @@ Get records in batch sorted by timestamp and entry name. > **lastAccessTime**(): `number` -Defined in: [RecordBatch.ts:245](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L245) +Defined in: [RecordBatch.ts:245](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L245) Get last access time of batch @@ -195,7 +195,7 @@ Get last access time of batch > **recordCount**(): `number` -Defined in: [RecordBatch.ts:252](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L252) +Defined in: [RecordBatch.ts:252](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L252) Get number of records in batch @@ -209,7 +209,7 @@ Get number of records in batch > **send**(): `Promise`\<`Map`\<`string`, `Map`\<`bigint`, [`APIError`](APIError.md)\>\>\> -Defined in: [RecordBatch.ts:140](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L140) +Defined in: [RecordBatch.ts:140](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L140) Send batch request (Multi-entry API). @@ -223,7 +223,7 @@ Send batch request (Multi-entry API). > **size**(): `bigint` -Defined in: [RecordBatch.ts:238](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L238) +Defined in: [RecordBatch.ts:238](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L238) Get total size of batch diff --git a/docs/sdk/js/api/classes/ReplicationInfo.md b/docs/sdk/js/api/classes/ReplicationInfo.md index 143d6502..45a65881 100644 --- a/docs/sdk/js/api/classes/ReplicationInfo.md +++ b/docs/sdk/js/api/classes/ReplicationInfo.md @@ -9,7 +9,7 @@ description: "API reference for ReplicationInfo in the ReductStore Client SDK fo # ReplicationInfo -Defined in: [messages/ReplicationInfo.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L26) +Defined in: [messages/ReplicationInfo.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L26) Replication info @@ -29,7 +29,7 @@ Replication info > `readonly` **isActive**: `boolean` = `false` -Defined in: [messages/ReplicationInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L35) +Defined in: [messages/ReplicationInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L35) Remote instance is available and replication is active @@ -39,7 +39,7 @@ Remote instance is available and replication is active > `readonly` **isProvisioned**: `boolean` = `false` -Defined in: [messages/ReplicationInfo.ts:45](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L45) +Defined in: [messages/ReplicationInfo.ts:45](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L45) Replication is provisioned @@ -49,7 +49,7 @@ Replication is provisioned > `readonly` **mode**: [`ReplicationMode`](../type-aliases/ReplicationMode.md) = `DEFAULT_REPLICATION_MODE` -Defined in: [messages/ReplicationInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L40) +Defined in: [messages/ReplicationInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L40) Replication mode @@ -59,7 +59,7 @@ Replication mode > `readonly` **name**: `string` = `""` -Defined in: [messages/ReplicationInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L30) +Defined in: [messages/ReplicationInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L30) Replication name @@ -69,7 +69,7 @@ Replication name > `readonly` **pendingRecords**: `bigint` = `0n` -Defined in: [messages/ReplicationInfo.ts:50](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L50) +Defined in: [messages/ReplicationInfo.ts:50](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L50) Number of records pending replication @@ -79,7 +79,7 @@ Number of records pending replication > `static` **parse**(`data`): `ReplicationInfo` -Defined in: [messages/ReplicationInfo.ts:52](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L52) +Defined in: [messages/ReplicationInfo.ts:52](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L52) #### Parameters diff --git a/docs/sdk/js/api/classes/ReplicationSettings.md b/docs/sdk/js/api/classes/ReplicationSettings.md index f32543ae..388bc7af 100644 --- a/docs/sdk/js/api/classes/ReplicationSettings.md +++ b/docs/sdk/js/api/classes/ReplicationSettings.md @@ -9,7 +9,7 @@ description: "API reference for ReplicationSettings in the ReductStore Client SD # ReplicationSettings -Defined in: [messages/ReplicationSettings.ts:24](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L24) +Defined in: [messages/ReplicationSettings.ts:24](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L24) Replication settings @@ -29,7 +29,7 @@ Replication settings > `readonly` **dstBucket**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L33) +Defined in: [messages/ReplicationSettings.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L33) Destination bucket. Must exist. @@ -39,7 +39,7 @@ Destination bucket. Must exist. > `readonly` **dstHost**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L38) +Defined in: [messages/ReplicationSettings.ts:38](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L38) Destination host. Must exist. @@ -49,7 +49,7 @@ Destination host. Must exist. > `readonly` `optional` **dstToken**: `string` -Defined in: [messages/ReplicationSettings.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L43) +Defined in: [messages/ReplicationSettings.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L43) Destination token. Must have write access to the destination bucket. @@ -59,7 +59,7 @@ Destination token. Must have write access to the destination bucket. > `readonly` **entries**: `string`[] = `[]` -Defined in: [messages/ReplicationSettings.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L48) +Defined in: [messages/ReplicationSettings.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L48) List of entries to replicate. If empty, all entries are replicated. Wildcards are supported. @@ -69,7 +69,7 @@ List of entries to replicate. If empty, all entries are replicated. Wildcards ar > `readonly` `optional` **mode**: [`ReplicationMode`](../type-aliases/ReplicationMode.md) -Defined in: [messages/ReplicationSettings.ts:58](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L58) +Defined in: [messages/ReplicationSettings.ts:58](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L58) Replication mode @@ -79,7 +79,7 @@ Replication mode > `readonly` **srcBucket**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:28](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L28) +Defined in: [messages/ReplicationSettings.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L28) Source bucket. Must exist. @@ -89,7 +89,7 @@ Source bucket. Must exist. > `readonly` `optional` **when**: `any` -Defined in: [messages/ReplicationSettings.ts:53](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L53) +Defined in: [messages/ReplicationSettings.ts:53](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L53) Conditional query @@ -99,7 +99,7 @@ Conditional query > `static` **parse**(`data`): `ReplicationSettings` -Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L60) +Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L60) #### Parameters @@ -117,7 +117,7 @@ Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/ > `static` **serialize**(`data`): `OriginalReplicationSettings` -Defined in: [messages/ReplicationSettings.ts:72](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L72) +Defined in: [messages/ReplicationSettings.ts:72](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L72) #### Parameters diff --git a/docs/sdk/js/api/classes/ServerInfo.md b/docs/sdk/js/api/classes/ServerInfo.md index 0088e136..362d2ed2 100644 --- a/docs/sdk/js/api/classes/ServerInfo.md +++ b/docs/sdk/js/api/classes/ServerInfo.md @@ -9,7 +9,7 @@ description: "API reference for ServerInfo in the ReductStore Client SDK for Jav # ServerInfo -Defined in: [messages/ServerInfo.ts:39](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L39) +Defined in: [messages/ServerInfo.ts:39](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L39) Represents information about storage @@ -29,7 +29,7 @@ Represents information about storage > `readonly` **bucketCount**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L48) +Defined in: [messages/ServerInfo.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L48) Number of buckets @@ -39,7 +39,7 @@ Number of buckets > `readonly` **defaults**: `ServerDefaults` -Defined in: [messages/ServerInfo.ts:78](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L78) +Defined in: [messages/ServerInfo.ts:78](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L78) Default settings @@ -49,7 +49,7 @@ Default settings > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:68](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L68) +Defined in: [messages/ServerInfo.ts:68](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L68) Unix timestamp of the latest record in microseconds @@ -59,7 +59,7 @@ Unix timestamp of the latest record in microseconds > `readonly` `optional` **license**: [`LicenseInfo`](LicenseInfo.md) -Defined in: [messages/ServerInfo.ts:73](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L73) +Defined in: [messages/ServerInfo.ts:73](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L73) License information @@ -69,7 +69,7 @@ License information > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L63) +Defined in: [messages/ServerInfo.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L63) Unix timestamp of the oldest record in microseconds @@ -79,7 +79,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **uptime**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:58](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L58) +Defined in: [messages/ServerInfo.ts:58](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L58) Server uptime in seconds @@ -89,7 +89,7 @@ Server uptime in seconds > `readonly` **usage**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:53](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L53) +Defined in: [messages/ServerInfo.ts:53](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L53) Stored data in bytes @@ -99,7 +99,7 @@ Stored data in bytes > `readonly` **version**: `string` = `""` -Defined in: [messages/ServerInfo.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L43) +Defined in: [messages/ServerInfo.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L43) Version storage server @@ -109,7 +109,7 @@ Version storage server > `static` **parse**(`data`): `ServerInfo` -Defined in: [messages/ServerInfo.ts:80](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L80) +Defined in: [messages/ServerInfo.ts:80](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L80) #### Parameters diff --git a/docs/sdk/js/api/classes/Token.md b/docs/sdk/js/api/classes/Token.md index 28bf2e8b..c72965d9 100644 --- a/docs/sdk/js/api/classes/Token.md +++ b/docs/sdk/js/api/classes/Token.md @@ -9,7 +9,7 @@ description: "API reference for Token in the ReductStore Client SDK for JavaScri # Token -Defined in: [messages/Token.ts:114](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L114) +Defined in: [messages/Token.ts:114](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L114) Information about an access token @@ -29,7 +29,7 @@ Information about an access token > `readonly` **createdAt**: `number` = `0` -Defined in: [messages/Token.ts:123](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L123) +Defined in: [messages/Token.ts:123](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L123) Creation time of the token as unix timestamp in milliseconds @@ -39,7 +39,7 @@ Creation time of the token as unix timestamp in milliseconds > `readonly` `optional` **expiresAt**: `number` -Defined in: [messages/Token.ts:143](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L143) +Defined in: [messages/Token.ts:143](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L143) Expiration time as unix timestamp in milliseconds @@ -49,7 +49,7 @@ Expiration time as unix timestamp in milliseconds > `readonly` `optional` **ipAllowlist**: `string`[] -Defined in: [messages/Token.ts:148](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L148) +Defined in: [messages/Token.ts:148](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L148) List of IP addresses and CIDR ranges allowed to use the token @@ -59,7 +59,7 @@ List of IP addresses and CIDR ranges allowed to use the token > `readonly` `optional` **isExpired**: `boolean` -Defined in: [messages/Token.ts:138](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L138) +Defined in: [messages/Token.ts:138](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L138) True if the token is expired @@ -69,7 +69,7 @@ True if the token is expired > `readonly` `optional` **isProvisioned**: `boolean` = `false` -Defined in: [messages/Token.ts:153](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L153) +Defined in: [messages/Token.ts:153](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L153) Is the token provisioned, and you can't remove it or change it @@ -79,7 +79,7 @@ Is the token provisioned, and you can't remove it or change it > `readonly` `optional` **lastAccess**: `number` -Defined in: [messages/Token.ts:128](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L128) +Defined in: [messages/Token.ts:128](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L128) Last access time of the token as unix timestamp in milliseconds @@ -89,7 +89,7 @@ Last access time of the token as unix timestamp in milliseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/Token.ts:118](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L118) +Defined in: [messages/Token.ts:118](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L118) Name of the token @@ -99,7 +99,7 @@ Name of the token > `readonly` `optional` **permissions**: [`TokenPermissions`](TokenPermissions.md) -Defined in: [messages/Token.ts:158](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L158) +Defined in: [messages/Token.ts:158](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L158) Permissions of the token @@ -109,7 +109,7 @@ Permissions of the token > `readonly` `optional` **ttl**: `number` -Defined in: [messages/Token.ts:133](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L133) +Defined in: [messages/Token.ts:133](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L133) Time to live in seconds @@ -119,7 +119,7 @@ Time to live in seconds > `static` **parse**(`data`): `Token` -Defined in: [messages/Token.ts:160](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L160) +Defined in: [messages/Token.ts:160](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L160) #### Parameters diff --git a/docs/sdk/js/api/classes/TokenCreateRequest.md b/docs/sdk/js/api/classes/TokenCreateRequest.md index f12282d3..68415d38 100644 --- a/docs/sdk/js/api/classes/TokenCreateRequest.md +++ b/docs/sdk/js/api/classes/TokenCreateRequest.md @@ -9,7 +9,7 @@ description: "API reference for TokenCreateRequest in the ReductStore Client SDK # TokenCreateRequest -Defined in: [messages/Token.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L23) +Defined in: [messages/Token.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L23) Token create request @@ -29,7 +29,7 @@ Token create request > `readonly` `optional` **expiresAt**: `number` -Defined in: [messages/Token.ts:32](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L32) +Defined in: [messages/Token.ts:32](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L32) Expiration time as unix timestamp in milliseconds @@ -39,7 +39,7 @@ Expiration time as unix timestamp in milliseconds > `readonly` `optional` **ipAllowlist**: `string`[] -Defined in: [messages/Token.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L42) +Defined in: [messages/Token.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L42) List of IP addresses and CIDR ranges allowed to use the token @@ -49,7 +49,7 @@ List of IP addresses and CIDR ranges allowed to use the token > `readonly` **permissions**: [`TokenPermissions`](TokenPermissions.md) -Defined in: [messages/Token.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L27) +Defined in: [messages/Token.ts:27](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L27) Permissions for the token @@ -59,7 +59,7 @@ Permissions for the token > `readonly` `optional` **ttl**: `number` -Defined in: [messages/Token.ts:37](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L37) +Defined in: [messages/Token.ts:37](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L37) Time to live in seconds @@ -69,7 +69,7 @@ Time to live in seconds > `static` **serialize**(`data`): `OriginalTokenCreateRequest` -Defined in: [messages/Token.ts:44](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L44) +Defined in: [messages/Token.ts:44](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L44) #### Parameters diff --git a/docs/sdk/js/api/classes/TokenPermissions.md b/docs/sdk/js/api/classes/TokenPermissions.md index a5d4e1f0..5fae8b93 100644 --- a/docs/sdk/js/api/classes/TokenPermissions.md +++ b/docs/sdk/js/api/classes/TokenPermissions.md @@ -9,7 +9,7 @@ description: "API reference for TokenPermissions in the ReductStore Client SDK f # TokenPermissions -Defined in: [messages/Token.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L60) +Defined in: [messages/Token.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L60) Token Permissions @@ -29,7 +29,7 @@ Token Permissions > `readonly` **fullAccess**: `boolean` = `false` -Defined in: [messages/Token.ts:65](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L65) +Defined in: [messages/Token.ts:65](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L65) Full access The token allows to create, remove and update settings of buckets, manage tokens and read and write data. @@ -40,7 +40,7 @@ The token allows to create, remove and update settings of buckets, manage tokens > `readonly` `optional` **read**: `string`[] = `[]` -Defined in: [messages/Token.ts:71](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L71) +Defined in: [messages/Token.ts:71](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L71) Read access List of buckets allowed to read @@ -51,7 +51,7 @@ List of buckets allowed to read > `readonly` `optional` **write**: `string`[] = `[]` -Defined in: [messages/Token.ts:77](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L77) +Defined in: [messages/Token.ts:77](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L77) Write access List of buckets allowed to write @@ -62,7 +62,7 @@ List of buckets allowed to write > `static` **parse**(`data`): `TokenPermissions` -Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L79) +Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L79) #### Parameters @@ -80,7 +80,7 @@ Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob > `static` **serialize**(`data`): `OriginalTokenPermission` -Defined in: [messages/Token.ts:87](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L87) +Defined in: [messages/Token.ts:87](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L87) #### Parameters diff --git a/docs/sdk/js/api/enumerations/QuotaType.md b/docs/sdk/js/api/enumerations/QuotaType.md index 4cd05ede..7595c8d7 100644 --- a/docs/sdk/js/api/enumerations/QuotaType.md +++ b/docs/sdk/js/api/enumerations/QuotaType.md @@ -9,7 +9,7 @@ description: "API reference for QuotaType in the ReductStore Client SDK for Java # QuotaType -Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L1) +Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L1) ## Enumeration Members @@ -17,7 +17,7 @@ Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct > **FIFO**: `1` -Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L3) +Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L3) *** @@ -25,7 +25,7 @@ Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct > **HARD**: `2` -Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L4) +Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L4) *** @@ -33,4 +33,4 @@ Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct > **NONE**: `0` -Defined in: [messages/BucketSettings.ts:2](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L2) +Defined in: [messages/BucketSettings.ts:2](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L2) diff --git a/docs/sdk/js/api/enumerations/RecordBatchType.md b/docs/sdk/js/api/enumerations/RecordBatchType.md index 10d04c2c..33233edb 100644 --- a/docs/sdk/js/api/enumerations/RecordBatchType.md +++ b/docs/sdk/js/api/enumerations/RecordBatchType.md @@ -9,7 +9,7 @@ description: "API reference for RecordBatchType in the ReductStore Client SDK fo # RecordBatchType -Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L25) +Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L25) ## Enumeration Members @@ -17,7 +17,7 @@ Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/e2 > **REMOVE**: `2` -Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L28) +Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L28) *** @@ -25,7 +25,7 @@ Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/e2 > **UPDATE**: `1` -Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L27) +Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L27) *** @@ -33,4 +33,4 @@ Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/e2 > **WRITE**: `0` -Defined in: [RecordBatch.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L26) +Defined in: [RecordBatch.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L26) diff --git a/docs/sdk/js/api/enumerations/Status.md b/docs/sdk/js/api/enumerations/Status.md index ded42060..d624fc43 100644 --- a/docs/sdk/js/api/enumerations/Status.md +++ b/docs/sdk/js/api/enumerations/Status.md @@ -9,7 +9,7 @@ description: "API reference for Status in the ReductStore Client SDK for JavaScr # Status -Defined in: [messages/Status.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L4) +Defined in: [messages/Status.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L4) Resource status during deletion @@ -19,7 +19,7 @@ Resource status during deletion > **DELETING**: `"DELETING"` -Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L6) +Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L6) *** @@ -27,4 +27,4 @@ Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob > **READY**: `"READY"` -Defined in: [messages/Status.ts:5](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L5) +Defined in: [messages/Status.ts:5](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L5) diff --git a/docs/sdk/js/api/interfaces/WriteOptions.md b/docs/sdk/js/api/interfaces/WriteOptions.md index d20e92c7..32c45614 100644 --- a/docs/sdk/js/api/interfaces/WriteOptions.md +++ b/docs/sdk/js/api/interfaces/WriteOptions.md @@ -9,7 +9,7 @@ description: "API reference for WriteOptions in the ReductStore Client SDK for J # WriteOptions -Defined in: [Bucket.ts:18](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L18) +Defined in: [Bucket.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L19) Options for writing records @@ -19,7 +19,7 @@ Options for writing records > `optional` **contentType**: `string` -Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L21) +Defined in: [Bucket.ts:22](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L22) *** @@ -27,7 +27,7 @@ Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a71 > `optional` **labels**: `LabelMap` -Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L20) +Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L21) *** @@ -35,4 +35,4 @@ Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a71 > `optional` **ts**: `bigint` -Defined in: [Bucket.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L19) +Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L20) diff --git a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/DISABLED.md b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/DISABLED.md index 2f4edf9d..aeb5fe31 100644 --- a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/DISABLED.md +++ b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/DISABLED.md @@ -11,4 +11,4 @@ description: "API reference for Variable: DISABLED in the ReductStore Client SDK > `const` **DISABLED**: `"disabled"` = `"disabled"` -Defined in: [messages/ReplicationMode.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationMode.ts#L20) +Defined in: [messages/ReplicationMode.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationMode.ts#L20) diff --git a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/ENABLED.md b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/ENABLED.md index 06cf5dbb..baef18d4 100644 --- a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/ENABLED.md +++ b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/ENABLED.md @@ -11,4 +11,4 @@ description: "API reference for Variable: ENABLED in the ReductStore Client SDK > `const` **ENABLED**: `"enabled"` = `"enabled"` -Defined in: [messages/ReplicationMode.ts:18](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationMode.ts#L18) +Defined in: [messages/ReplicationMode.ts:18](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationMode.ts#L18) diff --git a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/PAUSED.md b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/PAUSED.md index e91a8965..a307b08c 100644 --- a/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/PAUSED.md +++ b/docs/sdk/js/api/reduct-js/namespaces/ReplicationMode/variables/PAUSED.md @@ -11,4 +11,4 @@ description: "API reference for Variable: PAUSED in the ReductStore Client SDK f > `const` **PAUSED**: `"paused"` = `"paused"` -Defined in: [messages/ReplicationMode.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationMode.ts#L19) +Defined in: [messages/ReplicationMode.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationMode.ts#L19) diff --git a/docs/sdk/js/api/type-aliases/ReplicationMode.md b/docs/sdk/js/api/type-aliases/ReplicationMode.md index b79ae05a..c68cbe7b 100644 --- a/docs/sdk/js/api/type-aliases/ReplicationMode.md +++ b/docs/sdk/js/api/type-aliases/ReplicationMode.md @@ -11,6 +11,6 @@ description: "API reference for ReplicationMode in the ReductStore Client SDK fo > **ReplicationMode** = `"enabled"` \| `"paused"` \| `"disabled"` -Defined in: [messages/ReplicationMode.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationMode.ts#L4) +Defined in: [messages/ReplicationMode.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationMode.ts#L4) ReplicationMode string literal type for TypeScript type checking diff --git a/docs/sdk/js/batch/index.mdx b/docs/sdk/js/batch/index.mdx index 17bfa517..70bb385f 100644 --- a/docs/sdk/js/batch/index.mdx +++ b/docs/sdk/js/batch/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Batch Module of the ReductStore Client SDK fo ## Batch -Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L15) +Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L15) ### Constructors @@ -20,7 +20,7 @@ Defined in: [Batch.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718 > **new Batch**(`bucketName`, `entryName`, `httpClient`, `type`): `Batch` -Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L33) +Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L33) ##### Parameters @@ -50,7 +50,7 @@ Defined in: [Batch.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718 > **add**(`ts`, `data`, `contentType?`, `labels?`): `void` -Defined in: [Batch.ts:55](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L55) +Defined in: [Batch.ts:55](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L55) Add record to batch @@ -90,7 +90,7 @@ default: {} > **addOnlyLabels**(`ts`, `labels`): `void` -Defined in: [Batch.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L82) +Defined in: [Batch.ts:82](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L82) Add only labels to batch Use for updating labels @@ -117,7 +117,7 @@ timestamp of record as a UNIX timestamp in microseconds > **addOnlyTimestamp**(`ts`): `void` -Defined in: [Batch.ts:95](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L95) +Defined in: [Batch.ts:95](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L95) Add only timestamp to batch Use for removing records @@ -140,7 +140,7 @@ timestamp of record as a UNIX timestamp in microseconds > **clear**(): `void` -Defined in: [Batch.ts:218](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L218) +Defined in: [Batch.ts:218](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L218) Clear batch @@ -154,7 +154,7 @@ Clear batch > **items**(): `IterableIterator`<\[`bigint`, \{ `contentType`: `string`; `data`: `Buffer`; `labels`: `LabelMap`; \}\]> -Defined in: [Batch.ts:184](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L184) +Defined in: [Batch.ts:184](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L184) Get records in batch sorted by timestamp @@ -168,7 +168,7 @@ Get records in batch sorted by timestamp > **lastAccessTime**(): `number` -Defined in: [Batch.ts:204](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L204) +Defined in: [Batch.ts:204](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L204) Get last access time of batch @@ -182,7 +182,7 @@ Get last access time of batch > **recordCount**(): `number` -Defined in: [Batch.ts:211](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L211) +Defined in: [Batch.ts:211](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L211) Get number of records in batch @@ -196,7 +196,7 @@ Get number of records in batch > **size**(): `bigint` -Defined in: [Batch.ts:197](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L197) +Defined in: [Batch.ts:197](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L197) Get total size of batch @@ -210,7 +210,7 @@ Get total size of batch > **write**(): `Promise`<`Map`<`bigint`, [`APIError`](api/classes/APIError)>> -Defined in: [Batch.ts:107](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Batch.ts#L107) +Defined in: [Batch.ts:107](https://github.com/reductstore/reduct-js/blob/main/src/Batch.ts#L107) Write batch to entry diff --git a/docs/sdk/js/bucket/index.mdx b/docs/sdk/js/bucket/index.mdx index 6acbada0..01cfda93 100644 --- a/docs/sdk/js/bucket/index.mdx +++ b/docs/sdk/js/bucket/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Bucket Module of the ReductStore Client SDK f ## Bucket -Defined in: [Bucket.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L27) +Defined in: [Bucket.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L28) Represents a bucket in ReductStore @@ -22,7 +22,7 @@ Represents a bucket in ReductStore > **new Bucket**(`name`, `httpClient`): `Bucket` -Defined in: [Bucket.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L38) +Defined in: [Bucket.ts:39](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L39) Create a bucket. Use Client.creatBucket or Client.getBucket instead it @@ -48,7 +48,7 @@ Create a bucket. Use Client.creatBucket or Client.getBucket instead it > **beginRead**(`entry`, `ts?`, `head?`): `Promise`<`ReadableRecord`> -Defined in: [Bucket.ts:233](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L233) +Defined in: [Bucket.ts:234](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L234) Start reading a record from an entry @@ -84,7 +84,7 @@ Promise<ReadableRecord> > **beginRemoveBatch**(`entry`): `Promise`<[`Batch`](api/classes/Batch)> -Defined in: [Bucket.ts:121](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L121) +Defined in: [Bucket.ts:122](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L122) Remove a batch of records @@ -106,7 +106,7 @@ Remove a batch of records > **beginRemoveRecordBatch**(): [`RecordBatch`](api/classes/RecordBatch) -Defined in: [Bucket.ts:478](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L478) +Defined in: [Bucket.ts:479](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L479) Create a new batch for removing records across multiple entries. @@ -120,7 +120,7 @@ Create a new batch for removing records across multiple entries. > **beginUpdateBatch**(`entry`): `Promise`<[`Batch`](api/classes/Batch)> -Defined in: [Bucket.ts:459](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L459) +Defined in: [Bucket.ts:460](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L460) Create a new batch for updating records in the database. @@ -140,7 +140,7 @@ Create a new batch for updating records in the database. > **beginUpdateRecordBatch**(): [`RecordBatch`](api/classes/RecordBatch) -Defined in: [Bucket.ts:471](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L471) +Defined in: [Bucket.ts:472](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L472) Create a new batch for updating records across multiple entries. @@ -163,7 +163,7 @@ await batch.send(); > **beginWrite**(`entry`, `options?`): `Promise`<`WritableRecord`> -Defined in: [Bucket.ts:184](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L184) +Defined in: [Bucket.ts:185](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L185) Start writing a record into an entry @@ -204,7 +204,7 @@ await record.write("Hello!"); > **beginWriteBatch**(`entry`): `Promise`<[`Batch`](api/classes/Batch)> -Defined in: [Bucket.ts:439](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L439) +Defined in: [Bucket.ts:440](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L440) Create a new batch for writing records to the database. @@ -224,7 +224,7 @@ Create a new batch for writing records to the database. > **beginWriteRecordBatch**(): [`RecordBatch`](api/classes/RecordBatch) -Defined in: [Bucket.ts:451](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L451) +Defined in: [Bucket.ts:452](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L452) Create a new batch for writing records to multiple entries. @@ -247,7 +247,7 @@ await batch.send(); > **createQueryLink**(`entry`, `start?`, `stop?`, `query?`, `record?`, `expireAt?`, `fileName?`, `baseUrl?`): `Promise`<`string`> -Defined in: [Bucket.ts:495](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L495) +Defined in: [Bucket.ts:496](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L496) Create a query link for downloading records @@ -313,7 +313,7 @@ base url for link generation. If not set, the server's base url will be used > **getEntryList**(): `Promise`<[`EntryInfo`](api/classes/EntryInfo)[]> -Defined in: [Bucket.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L82) +Defined in: [Bucket.ts:83](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L83) Get entry list @@ -329,7 +329,7 @@ Get entry list > **getInfo**(): `Promise`<[`BucketInfo`](api/classes/BucketInfo)> -Defined in: [Bucket.ts:72](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L72) +Defined in: [Bucket.ts:73](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L73) Get information about a bucket @@ -345,7 +345,7 @@ Get information about a bucket > **getName**(): `string` -Defined in: [Bucket.ts:350](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L350) +Defined in: [Bucket.ts:351](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L351) ##### Returns @@ -357,7 +357,7 @@ Defined in: [Bucket.ts:350](https://github.com/reductstore/reduct-js/blob/e2b7a7 > **getSettings**(): `Promise`<[`BucketSettings`](api/classes/BucketSettings)> -Defined in: [Bucket.ts:50](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L50) +Defined in: [Bucket.ts:51](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L51) Get bucket settings @@ -373,7 +373,7 @@ Get bucket settings > **query**(`entry`, `start?`, `stop?`, `options?`): `AsyncGenerator`<`ReadableRecord`> -Defined in: [Bucket.ts:295](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L295) +Defined in: [Bucket.ts:296](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L296) Query records for a time interval as generator @@ -426,7 +426,7 @@ for await (const record in bucket.query("entry-1", start, stop)) { > **readAttachments**(`entry`): `Promise`<`Record`<`string`, `unknown`>> -Defined in: [Bucket.ts:616](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L616) +Defined in: [Bucket.ts:617](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L617) Read attachments from an entry. @@ -450,7 +450,7 @@ map of attachment key to decoded JSON value > **remove**(): `Promise`<`void`> -Defined in: [Bucket.ts:94](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L94) +Defined in: [Bucket.ts:95](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L95) Remove bucket @@ -466,7 +466,7 @@ Remove bucket > **removeAttachments**(`entry`, `attachmentKeys?`): `Promise`<`void`> -Defined in: [Bucket.ts:640](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L640) +Defined in: [Bucket.ts:646](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L646) Remove attachments from an entry. @@ -496,7 +496,7 @@ list of keys to remove > **removeEntry**(`entry`): `Promise`<`void`> -Defined in: [Bucket.ts:104](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L104) +Defined in: [Bucket.ts:105](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L105) Remove an entry @@ -520,7 +520,7 @@ Remove an entry > **removeQuery**(`entry`, `start?`, `stop?`, `options?`): `Promise`<`number`> -Defined in: [Bucket.ts:132](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L132) +Defined in: [Bucket.ts:133](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L133) Remove records by query @@ -560,7 +560,7 @@ Remove records by query > **removeRecord**(`entry`, `ts`): `Promise`<`void`> -Defined in: [Bucket.ts:113](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L113) +Defined in: [Bucket.ts:114](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L114) Remove a record @@ -588,7 +588,7 @@ Remove a record > **rename**(`newName`): `Promise`<`void`> -Defined in: [Bucket.ts:266](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L266) +Defined in: [Bucket.ts:267](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L267) Rename a bucket @@ -610,7 +610,7 @@ new name of the bucket > **renameEntry**(`entry`, `newEntry`): `Promise`<`void`> -Defined in: [Bucket.ts:250](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L250) +Defined in: [Bucket.ts:251](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L251) Rename an entry @@ -638,7 +638,7 @@ new entry name > **setSettings**(`settings`): `Promise`<`void`> -Defined in: [Bucket.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L60) +Defined in: [Bucket.ts:61](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L61) Set bucket settings @@ -662,7 +662,7 @@ Set bucket settings > **update**(`entry`, `ts`, `labels`): `Promise`<`void`> -Defined in: [Bucket.ts:212](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L212) +Defined in: [Bucket.ts:213](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L213) Update labels of an existing record @@ -696,9 +696,9 @@ If a label has empty string value, it will be removed. #### writeAttachments() -> **writeAttachments**(`entry`, `attachments`): `Promise`<`void`> +> **writeAttachments**(`entry`, `attachments`, `contentType?`): `Promise`<`void`> -Defined in: [Bucket.ts:587](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L587) +Defined in: [Bucket.ts:588](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L588) Write attachments to an entry. @@ -718,6 +718,10 @@ name of the source entry map of attachment key to JSON-serializable content +###### contentType? + +`string` + ##### Returns `Promise`<`void`> @@ -727,7 +731,7 @@ map of attachment key to JSON-serializable content ## WriteOptions -Defined in: [Bucket.ts:18](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L18) +Defined in: [Bucket.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L19) Options for writing records @@ -737,7 +741,7 @@ Options for writing records > `optional` **contentType**: `string` -Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L21) +Defined in: [Bucket.ts:22](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L22) *** @@ -745,7 +749,7 @@ Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a71 > `optional` **labels**: `LabelMap` -Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L20) +Defined in: [Bucket.ts:21](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L21) *** @@ -753,5 +757,5 @@ Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a71 > `optional` **ts**: `bigint` -Defined in: [Bucket.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Bucket.ts#L19) +Defined in: [Bucket.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/Bucket.ts#L20) diff --git a/docs/sdk/js/client/index.mdx b/docs/sdk/js/client/index.mdx index 7ce1024a..f4a2af4d 100644 --- a/docs/sdk/js/client/index.mdx +++ b/docs/sdk/js/client/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Client Module of the ReductStore Client SDK f ## Client -Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L43) +Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L43) ### Constructors @@ -20,7 +20,7 @@ Defined in: [Client.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a71 > **new Client**(`url`, `options`): `Client` -Defined in: [Client.ts:51](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L51) +Defined in: [Client.ts:51](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L51) HTTP Client for ReductStore @@ -46,7 +46,7 @@ URL to the storage > **close**(): `Promise`<`void`> -Defined in: [Client.ts:68](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L68) +Defined in: [Client.ts:68](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L68) Close underlying HTTP resources (Node.js only). @@ -60,7 +60,7 @@ Close underlying HTTP resources (Node.js only). > **createBucket**(`name`, `settings?`): `Promise`<[`Bucket`](api/classes/Bucket)> -Defined in: [Client.ts:91](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L91) +Defined in: [Client.ts:91](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L91) Create a new bucket @@ -88,7 +88,7 @@ optional settings > **createReplication**(`name`, `settings`): `Promise`<`void`> -Defined in: [Client.ts:246](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L246) +Defined in: [Client.ts:246](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L246) Create a new replication @@ -116,7 +116,7 @@ settings of the replication > **createToken**(`name`, `permissionsOrRequest`): `Promise`<`string`> -Defined in: [Client.ts:141](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L141) +Defined in: [Client.ts:141](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L141) Create a new access token @@ -153,7 +153,7 @@ const client = new Client("https://play.storage-reduct.dev", {apiToken: token}); > **deleteReplication**(`name`): `Promise`<`void`> -Defined in: [Client.ts:287](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L287) +Defined in: [Client.ts:287](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L287) Delete a replication @@ -175,7 +175,7 @@ name of the replication > **deleteToken**(`name`): `Promise`<`void`> -Defined in: [Client.ts:202](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L202) +Defined in: [Client.ts:202](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L202) Delete a token by name @@ -197,7 +197,7 @@ name of the token > **getBucket**(`name`): `Promise`<[`Bucket`](api/classes/Bucket)> -Defined in: [Client.ts:104](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L104) +Defined in: [Client.ts:104](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L104) Get a bucket by name @@ -219,7 +219,7 @@ name of the bucket > **getBucketList**(): `Promise`<[`BucketInfo`](api/classes/BucketInfo)[]> -Defined in: [Client.ts:78](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L78) +Defined in: [Client.ts:78](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L78) Get list of buckets @@ -239,7 +239,7 @@ BucketInfo > **getInfo**(): `Promise`<[`ServerInfo`](api/classes/ServerInfo)> -Defined in: [Client.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L60) +Defined in: [Client.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L60) Get server information @@ -257,7 +257,7 @@ the data about the server > **getOrCreateBucket**(`name`, `settings?`): `Promise`<[`Bucket`](api/classes/Bucket)> -Defined in: [Client.ts:115](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L115) +Defined in: [Client.ts:115](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L115) Try to create a bucket and get it if it already exists @@ -285,7 +285,7 @@ optional settings > **getReplication**(`name`): `Promise`<[`FullReplicationInfo`](api/classes/FullReplicationInfo)> -Defined in: [Client.ts:233](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L233) +Defined in: [Client.ts:233](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L233) Get full information about a replication @@ -309,7 +309,7 @@ the replication > **getReplicationList**(): `Promise`<[`ReplicationInfo`](api/classes/ReplicationInfo)[]> -Defined in: [Client.ts:219](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L219) +Defined in: [Client.ts:219](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L219) Get the list of replications @@ -325,7 +325,7 @@ the list of replications > **getToken**(`name`): `Promise`<[`Token`](api/classes/Token)> -Defined in: [Client.ts:180](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L180) +Defined in: [Client.ts:180](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L180) Get a token by name @@ -349,7 +349,7 @@ the token > **getTokenList**(): `Promise`<[`Token`](api/classes/Token)[]> -Defined in: [Client.ts:191](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L191) +Defined in: [Client.ts:191](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L191) List all tokens @@ -365,7 +365,7 @@ the list of tokens > **me**(): `Promise`<[`Token`](api/classes/Token)> -Defined in: [Client.ts:210](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L210) +Defined in: [Client.ts:210](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L210) Get current API token and its permissions @@ -381,7 +381,7 @@ the token > **rotateToken**(`name`): `Promise`<`string`> -Defined in: [Client.ts:167](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L167) +Defined in: [Client.ts:167](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L167) Rotate a token by name @@ -405,7 +405,7 @@ new token value > **setReplicationMode**(`name`, `mode`): `Promise`<`void`> -Defined in: [Client.ts:278](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L278) +Defined in: [Client.ts:278](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L278) Update replication mode without changing settings @@ -433,7 +433,7 @@ new mode: enabled, paused, or disabled > **updateReplication**(`name`, `settings`): `Promise`<`void`> -Defined in: [Client.ts:262](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/Client.ts#L262) +Defined in: [Client.ts:262](https://github.com/reductstore/reduct-js/blob/main/src/Client.ts#L262) Update a replication diff --git a/docs/sdk/js/error/index.mdx b/docs/sdk/js/error/index.mdx index dc37d719..9523e39e 100644 --- a/docs/sdk/js/error/index.mdx +++ b/docs/sdk/js/error/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Error Module of the ReductStore Client SDK fo ## APIError -Defined in: [APIError.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L4) +Defined in: [APIError.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L4) Represents HTTP Error @@ -22,7 +22,7 @@ Represents HTTP Error > **new APIError**(`message`, `status?`, `original?`): `APIError` -Defined in: [APIError.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L23) +Defined in: [APIError.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L23) Create an error from HTTP status and message @@ -50,7 +50,7 @@ Create an error from HTTP status and message > `optional` **message**: `string` -Defined in: [APIError.ts:13](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L13) +Defined in: [APIError.ts:13](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L13) Parsed message from the storage engine @@ -60,7 +60,7 @@ Parsed message from the storage engine > `optional` **original**: `unknown` -Defined in: [APIError.ts:18](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L18) +Defined in: [APIError.ts:18](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L18) Original error from HTTP client with the full information @@ -70,7 +70,7 @@ Original error from HTTP client with the full information > `optional` **status**: `number` -Defined in: [APIError.ts:8](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/APIError.ts#L8) +Defined in: [APIError.ts:8](https://github.com/reductstore/reduct-js/blob/main/src/APIError.ts#L8) HTTP status of error. If it is empty, it means communication problem diff --git a/docs/sdk/js/msg/bucket-info/index.mdx b/docs/sdk/js/msg/bucket-info/index.mdx index 35fb52c0..d6b1f8b5 100644 --- a/docs/sdk/js/msg/bucket-info/index.mdx +++ b/docs/sdk/js/msg/bucket-info/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Bucket Info Module of the ReductStore Client ## BucketInfo -Defined in: [messages/BucketInfo.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L6) +Defined in: [messages/BucketInfo.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L6) Represents information about a bucket @@ -32,7 +32,7 @@ Represents information about a bucket > `readonly` **entryCount**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L15) +Defined in: [messages/BucketInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L15) Number of entries in the bucket @@ -42,7 +42,7 @@ Number of entries in the bucket > `readonly` `optional` **isProvisioned**: `boolean` = `false` -Defined in: [messages/BucketInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L35) +Defined in: [messages/BucketInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L35) Is the bucket provisioned, and you can't remove it or change its settings @@ -52,7 +52,7 @@ Is the bucket provisioned, and you can't remove it or change its settings > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L30) +Defined in: [messages/BucketInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L30) Unix timestamp of the latest record in microseconds @@ -62,7 +62,7 @@ Unix timestamp of the latest record in microseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/BucketInfo.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L10) +Defined in: [messages/BucketInfo.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L10) Name of the bucket @@ -72,7 +72,7 @@ Name of the bucket > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L25) +Defined in: [messages/BucketInfo.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L25) Unix timestamp of the oldest record in microseconds @@ -82,7 +82,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **size**: `bigint` = `0n` -Defined in: [messages/BucketInfo.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L20) +Defined in: [messages/BucketInfo.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L20) Size of stored data in the bucket in bytes @@ -92,7 +92,7 @@ Size of stored data in the bucket in bytes > `readonly` **status**: [`Status`](../api/enumerations/Status) = `Status.READY` -Defined in: [messages/BucketInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L40) +Defined in: [messages/BucketInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L40) Current status of the bucket (READY or DELETING) @@ -102,7 +102,7 @@ Current status of the bucket (READY or DELETING) > `static` **parse**(`bucket`): `BucketInfo` -Defined in: [messages/BucketInfo.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketInfo.ts#L42) +Defined in: [messages/BucketInfo.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketInfo.ts#L42) ##### Parameters diff --git a/docs/sdk/js/msg/bucket-settings/index.mdx b/docs/sdk/js/msg/bucket-settings/index.mdx index 6f2c0ac4..f363bd3d 100644 --- a/docs/sdk/js/msg/bucket-settings/index.mdx +++ b/docs/sdk/js/msg/bucket-settings/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Bucket Settings Module of the ReductStore Cli ## BucketSettings -Defined in: [messages/BucketSettings.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L10) +Defined in: [messages/BucketSettings.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L10) Represents bucket settings @@ -32,7 +32,7 @@ Represents bucket settings > `readonly` `optional` **maxBlockRecords**: `bigint` -Defined in: [messages/BucketSettings.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L19) +Defined in: [messages/BucketSettings.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L19) Maximum number of records in a block @@ -42,7 +42,7 @@ Maximum number of records in a block > `readonly` `optional` **maxBlockSize**: `bigint` -Defined in: [messages/BucketSettings.ts:14](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L14) +Defined in: [messages/BucketSettings.ts:14](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L14) Maximal block size in a block @@ -52,7 +52,7 @@ Maximal block size in a block > `readonly` `optional` **quotaSize**: `bigint` -Defined in: [messages/BucketSettings.ts:31](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L31) +Defined in: [messages/BucketSettings.ts:31](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L31) Quota size in bytes @@ -62,7 +62,7 @@ Quota size in bytes > `readonly` `optional` **quotaType**: [`QuotaType`](../api/enumerations/QuotaType) -Defined in: [messages/BucketSettings.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L26) +Defined in: [messages/BucketSettings.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L26) Quota type. The storage supports two types: NONE: A bucket will consume the whole free disk space. @@ -74,7 +74,7 @@ Quota type. The storage supports two types: > `static` **parse**(`data`): `BucketSettings` -Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L33) +Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L33) ##### Parameters @@ -92,7 +92,7 @@ Defined in: [messages/BucketSettings.ts:33](https://github.com/reductstore/reduc > `static` **serialize**(`settings`): `OriginalBucketSettings` -Defined in: [messages/BucketSettings.ts:46](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L46) +Defined in: [messages/BucketSettings.ts:46](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L46) ##### Parameters @@ -109,7 +109,7 @@ Defined in: [messages/BucketSettings.ts:46](https://github.com/reductstore/reduc ## QuotaType -Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L1) +Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L1) ### Enumeration Members @@ -117,7 +117,7 @@ Defined in: [messages/BucketSettings.ts:1](https://github.com/reductstore/reduct > **FIFO**: `1` -Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L3) +Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L3) *** @@ -125,7 +125,7 @@ Defined in: [messages/BucketSettings.ts:3](https://github.com/reductstore/reduct > **HARD**: `2` -Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L4) +Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L4) *** @@ -133,5 +133,5 @@ Defined in: [messages/BucketSettings.ts:4](https://github.com/reductstore/reduct > **NONE**: `0` -Defined in: [messages/BucketSettings.ts:2](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/BucketSettings.ts#L2) +Defined in: [messages/BucketSettings.ts:2](https://github.com/reductstore/reduct-js/blob/main/src/messages/BucketSettings.ts#L2) diff --git a/docs/sdk/js/msg/entry-info/index.mdx b/docs/sdk/js/msg/entry-info/index.mdx index 89391244..eaee68aa 100644 --- a/docs/sdk/js/msg/entry-info/index.mdx +++ b/docs/sdk/js/msg/entry-info/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Entry Info Module of the ReductStore Client S ## EntryInfo -Defined in: [messages/EntryInfo.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L6) +Defined in: [messages/EntryInfo.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L6) Information about entry @@ -32,7 +32,7 @@ Information about entry > `readonly` **blockCount**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L15) +Defined in: [messages/EntryInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L15) Number of blocks @@ -42,7 +42,7 @@ Number of blocks > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L35) +Defined in: [messages/EntryInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L35) Unix timestamp of the latest record in microseconds @@ -52,7 +52,7 @@ Unix timestamp of the latest record in microseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/EntryInfo.ts:10](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L10) +Defined in: [messages/EntryInfo.ts:10](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L10) Name of the entry @@ -62,7 +62,7 @@ Name of the entry > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L30) +Defined in: [messages/EntryInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L30) Unix timestamp of the oldest record in microseconds @@ -72,7 +72,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **recordCount**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:20](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L20) +Defined in: [messages/EntryInfo.ts:20](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L20) Number of records @@ -82,7 +82,7 @@ Number of records > `readonly` **size**: `bigint` = `0n` -Defined in: [messages/EntryInfo.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L25) +Defined in: [messages/EntryInfo.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L25) Size of stored data in the bucket in bytes @@ -92,7 +92,7 @@ Size of stored data in the bucket in bytes > `readonly` **status**: [`Status`](../api/enumerations/Status) = `Status.READY` -Defined in: [messages/EntryInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L40) +Defined in: [messages/EntryInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L40) Current status of the entry (READY or DELETING) @@ -102,7 +102,7 @@ Current status of the entry (READY or DELETING) > `static` **parse**(`bucket`): `EntryInfo` -Defined in: [messages/EntryInfo.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/EntryInfo.ts#L42) +Defined in: [messages/EntryInfo.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/EntryInfo.ts#L42) ##### Parameters diff --git a/docs/sdk/js/msg/query-entry/index.mdx b/docs/sdk/js/msg/query-entry/index.mdx index a4c11042..0aee0644 100644 --- a/docs/sdk/js/msg/query-entry/index.mdx +++ b/docs/sdk/js/msg/query-entry/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Query Entry Module of the ReductStore Client ## QueryOptions -Defined in: [messages/QueryEntry.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L38) +Defined in: [messages/QueryEntry.ts:38](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L38) Options for querying records @@ -32,7 +32,7 @@ Options for querying records > `optional` **continuous**: `boolean` -Defined in: [messages/QueryEntry.ts:55](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L55) +Defined in: [messages/QueryEntry.ts:55](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L55) Don't stop query until TTL is reached @@ -42,7 +42,7 @@ Don't stop query until TTL is reached > `optional` **eachN**: `number` -Defined in: [messages/QueryEntry.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L48) +Defined in: [messages/QueryEntry.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L48) Return only one record per N records @deprecated: use $each_n operator in when instead. Will be remove in v1.18.0 @@ -53,7 +53,7 @@ Return only one record per N records > `optional` **eachS**: `number` -Defined in: [messages/QueryEntry.ts:44](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L44) +Defined in: [messages/QueryEntry.ts:44](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L44) Return only one record per S second @deprecated: use $each_t operator in when instead. Will be remove in v1.18.0 @@ -64,7 +64,7 @@ Return only one record per S second > `optional` **ext**: `Record`<`string`, `any`> -Defined in: [messages/QueryEntry.ts:65](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L65) +Defined in: [messages/QueryEntry.ts:65](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L65) Additional parameters for extensions @@ -74,7 +74,7 @@ Additional parameters for extensions > `optional` **head**: `boolean` -Defined in: [messages/QueryEntry.ts:59](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L59) +Defined in: [messages/QueryEntry.ts:59](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L59) Return only metadata @@ -84,7 +84,7 @@ Return only metadata > `optional` **limit**: `number` -Defined in: [messages/QueryEntry.ts:52](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L52) +Defined in: [messages/QueryEntry.ts:52](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L52) Limit number of records @deprecated: use $limit operator in when instead. Will be remove in v1.18.0 @@ -95,7 +95,7 @@ Limit number of records > `optional` **pollInterval**: `number` -Defined in: [messages/QueryEntry.ts:57](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L57) +Defined in: [messages/QueryEntry.ts:57](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L57) Poll interval for new records only for continue=true @@ -105,7 +105,7 @@ Poll interval for new records only for continue=true > `optional` **strict**: `boolean` -Defined in: [messages/QueryEntry.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L63) +Defined in: [messages/QueryEntry.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L63) strict conditional query @@ -115,7 +115,7 @@ strict conditional query > `optional` **ttl**: `number` -Defined in: [messages/QueryEntry.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L40) +Defined in: [messages/QueryEntry.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L40) Time to live in seconds @@ -125,7 +125,7 @@ Time to live in seconds > `optional` **when**: `Record`<`string`, `any`> -Defined in: [messages/QueryEntry.ts:61](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L61) +Defined in: [messages/QueryEntry.ts:61](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L61) Conditional query @@ -135,7 +135,7 @@ Conditional query > `static` **serialize**(`queryType`, `data`, `start?`, `stop?`, `entries?`): `QueryEntry` -Defined in: [messages/QueryEntry.ts:67](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/QueryEntry.ts#L67) +Defined in: [messages/QueryEntry.ts:67](https://github.com/reductstore/reduct-js/blob/main/src/messages/QueryEntry.ts#L67) ##### Parameters diff --git a/docs/sdk/js/msg/replication-info/index.mdx b/docs/sdk/js/msg/replication-info/index.mdx index cb45eb5d..f7117957 100644 --- a/docs/sdk/js/msg/replication-info/index.mdx +++ b/docs/sdk/js/msg/replication-info/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Replication Info Module of the ReductStore Cl ## FullReplicationInfo -Defined in: [messages/ReplicationInfo.ts:66](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L66) +Defined in: [messages/ReplicationInfo.ts:66](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L66) Replication full info @@ -32,7 +32,7 @@ Replication full info > `readonly` **diagnostics**: `Diagnostics` -Defined in: [messages/ReplicationInfo.ts:80](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L80) +Defined in: [messages/ReplicationInfo.ts:80](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L80) Replication statistics @@ -42,7 +42,7 @@ Replication statistics > `readonly` **info**: [`ReplicationInfo`](../api/classes/ReplicationInfo) -Defined in: [messages/ReplicationInfo.ts:70](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L70) +Defined in: [messages/ReplicationInfo.ts:70](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L70) Replication info @@ -52,7 +52,7 @@ Replication info > `readonly` **settings**: [`ReplicationSettings`](../api/classes/ReplicationSettings) -Defined in: [messages/ReplicationInfo.ts:75](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L75) +Defined in: [messages/ReplicationInfo.ts:75](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L75) Replication settings @@ -62,7 +62,7 @@ Replication settings > `static` **parse**(`data`): `FullReplicationInfo` -Defined in: [messages/ReplicationInfo.ts:82](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L82) +Defined in: [messages/ReplicationInfo.ts:82](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L82) ##### Parameters @@ -76,7 +76,7 @@ Defined in: [messages/ReplicationInfo.ts:82](https://github.com/reductstore/redu ## ReplicationInfo -Defined in: [messages/ReplicationInfo.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L26) +Defined in: [messages/ReplicationInfo.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L26) Replication info @@ -96,7 +96,7 @@ Replication info > `readonly` **isActive**: `boolean` = `false` -Defined in: [messages/ReplicationInfo.ts:35](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L35) +Defined in: [messages/ReplicationInfo.ts:35](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L35) Remote instance is available and replication is active @@ -106,7 +106,7 @@ Remote instance is available and replication is active > `readonly` **isProvisioned**: `boolean` = `false` -Defined in: [messages/ReplicationInfo.ts:45](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L45) +Defined in: [messages/ReplicationInfo.ts:45](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L45) Replication is provisioned @@ -116,7 +116,7 @@ Replication is provisioned > `readonly` **mode**: [`ReplicationMode`](../api/type-aliases/ReplicationMode) = `DEFAULT_REPLICATION_MODE` -Defined in: [messages/ReplicationInfo.ts:40](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L40) +Defined in: [messages/ReplicationInfo.ts:40](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L40) Replication mode @@ -126,7 +126,7 @@ Replication mode > `readonly` **name**: `string` = `""` -Defined in: [messages/ReplicationInfo.ts:30](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L30) +Defined in: [messages/ReplicationInfo.ts:30](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L30) Replication name @@ -136,7 +136,7 @@ Replication name > `readonly` **pendingRecords**: `bigint` = `0n` -Defined in: [messages/ReplicationInfo.ts:50](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L50) +Defined in: [messages/ReplicationInfo.ts:50](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L50) Number of records pending replication @@ -146,7 +146,7 @@ Number of records pending replication > `static` **parse**(`data`): `ReplicationInfo` -Defined in: [messages/ReplicationInfo.ts:52](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationInfo.ts#L52) +Defined in: [messages/ReplicationInfo.ts:52](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationInfo.ts#L52) ##### Parameters diff --git a/docs/sdk/js/msg/replication-settings/index.mdx b/docs/sdk/js/msg/replication-settings/index.mdx index a205f5d1..2745cfe0 100644 --- a/docs/sdk/js/msg/replication-settings/index.mdx +++ b/docs/sdk/js/msg/replication-settings/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Replication Settings Module of the ReductStor ## ReplicationSettings -Defined in: [messages/ReplicationSettings.ts:24](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L24) +Defined in: [messages/ReplicationSettings.ts:24](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L24) Replication settings @@ -32,7 +32,7 @@ Replication settings > `readonly` **dstBucket**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:33](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L33) +Defined in: [messages/ReplicationSettings.ts:33](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L33) Destination bucket. Must exist. @@ -42,7 +42,7 @@ Destination bucket. Must exist. > `readonly` **dstHost**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:38](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L38) +Defined in: [messages/ReplicationSettings.ts:38](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L38) Destination host. Must exist. @@ -52,7 +52,7 @@ Destination host. Must exist. > `readonly` `optional` **dstToken**: `string` -Defined in: [messages/ReplicationSettings.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L43) +Defined in: [messages/ReplicationSettings.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L43) Destination token. Must have write access to the destination bucket. @@ -62,7 +62,7 @@ Destination token. Must have write access to the destination bucket. > `readonly` **entries**: `string`[] = `[]` -Defined in: [messages/ReplicationSettings.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L48) +Defined in: [messages/ReplicationSettings.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L48) List of entries to replicate. If empty, all entries are replicated. Wildcards are supported. @@ -72,7 +72,7 @@ List of entries to replicate. If empty, all entries are replicated. Wildcards ar > `readonly` `optional` **mode**: [`ReplicationMode`](../api/type-aliases/ReplicationMode) -Defined in: [messages/ReplicationSettings.ts:58](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L58) +Defined in: [messages/ReplicationSettings.ts:58](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L58) Replication mode @@ -82,7 +82,7 @@ Replication mode > `readonly` **srcBucket**: `string` = `""` -Defined in: [messages/ReplicationSettings.ts:28](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L28) +Defined in: [messages/ReplicationSettings.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L28) Source bucket. Must exist. @@ -92,7 +92,7 @@ Source bucket. Must exist. > `readonly` `optional` **when**: `any` -Defined in: [messages/ReplicationSettings.ts:53](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L53) +Defined in: [messages/ReplicationSettings.ts:53](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L53) Conditional query @@ -102,7 +102,7 @@ Conditional query > `static` **parse**(`data`): `ReplicationSettings` -Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L60) +Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L60) ##### Parameters @@ -120,7 +120,7 @@ Defined in: [messages/ReplicationSettings.ts:60](https://github.com/reductstore/ > `static` **serialize**(`data`): `OriginalReplicationSettings` -Defined in: [messages/ReplicationSettings.ts:72](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ReplicationSettings.ts#L72) +Defined in: [messages/ReplicationSettings.ts:72](https://github.com/reductstore/reduct-js/blob/main/src/messages/ReplicationSettings.ts#L72) ##### Parameters diff --git a/docs/sdk/js/msg/server-info/index.mdx b/docs/sdk/js/msg/server-info/index.mdx index d1eab171..0f251151 100644 --- a/docs/sdk/js/msg/server-info/index.mdx +++ b/docs/sdk/js/msg/server-info/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Server Info Module of the ReductStore Client ## LicenseInfo -Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L7) +Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L7) ### Constructors @@ -30,7 +30,7 @@ Defined in: [messages/ServerInfo.ts:7](https://github.com/reductstore/reduct-js/ > `readonly` **deviceNumber**: `number` = `0` -Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L17) +Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L17) *** @@ -38,7 +38,7 @@ Defined in: [messages/ServerInfo.ts:17](https://github.com/reductstore/reduct-js > `readonly` **diskQuota**: `number` = `0` -Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L19) +Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L19) *** @@ -46,7 +46,7 @@ Defined in: [messages/ServerInfo.ts:19](https://github.com/reductstore/reduct-js > `readonly` **expiryDate**: `number` = `0` -Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L13) +Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L13) *** @@ -54,7 +54,7 @@ Defined in: [messages/ServerInfo.ts:13](https://github.com/reductstore/reduct-js > `readonly` **fingerprint**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L21) +Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L21) *** @@ -62,7 +62,7 @@ Defined in: [messages/ServerInfo.ts:21](https://github.com/reductstore/reduct-js > `readonly` **invoice**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L11) +Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L11) *** @@ -70,7 +70,7 @@ Defined in: [messages/ServerInfo.ts:11](https://github.com/reductstore/reduct-js > `readonly` **licensee**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L9) +Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L9) *** @@ -78,7 +78,7 @@ Defined in: [messages/ServerInfo.ts:9](https://github.com/reductstore/reduct-js/ > `readonly` **plan**: `string` = `"UNKNOWN"` -Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L15) +Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L15) ### Methods @@ -86,7 +86,7 @@ Defined in: [messages/ServerInfo.ts:15](https://github.com/reductstore/reduct-js > `static` **parse**(`data`): `LicenseInfo` -Defined in: [messages/ServerInfo.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L23) +Defined in: [messages/ServerInfo.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L23) ##### Parameters @@ -100,7 +100,7 @@ Defined in: [messages/ServerInfo.ts:23](https://github.com/reductstore/reduct-js ## ServerInfo -Defined in: [messages/ServerInfo.ts:39](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L39) +Defined in: [messages/ServerInfo.ts:39](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L39) Represents information about storage @@ -120,7 +120,7 @@ Represents information about storage > `readonly` **bucketCount**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:48](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L48) +Defined in: [messages/ServerInfo.ts:48](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L48) Number of buckets @@ -130,7 +130,7 @@ Number of buckets > `readonly` **defaults**: `ServerDefaults` -Defined in: [messages/ServerInfo.ts:78](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L78) +Defined in: [messages/ServerInfo.ts:78](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L78) Default settings @@ -140,7 +140,7 @@ Default settings > `readonly` **latestRecord**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:68](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L68) +Defined in: [messages/ServerInfo.ts:68](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L68) Unix timestamp of the latest record in microseconds @@ -150,7 +150,7 @@ Unix timestamp of the latest record in microseconds > `readonly` `optional` **license**: [`LicenseInfo`](../api/classes/LicenseInfo) -Defined in: [messages/ServerInfo.ts:73](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L73) +Defined in: [messages/ServerInfo.ts:73](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L73) License information @@ -160,7 +160,7 @@ License information > `readonly` **oldestRecord**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L63) +Defined in: [messages/ServerInfo.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L63) Unix timestamp of the oldest record in microseconds @@ -170,7 +170,7 @@ Unix timestamp of the oldest record in microseconds > `readonly` **uptime**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:58](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L58) +Defined in: [messages/ServerInfo.ts:58](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L58) Server uptime in seconds @@ -180,7 +180,7 @@ Server uptime in seconds > `readonly` **usage**: `bigint` = `0n` -Defined in: [messages/ServerInfo.ts:53](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L53) +Defined in: [messages/ServerInfo.ts:53](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L53) Stored data in bytes @@ -190,7 +190,7 @@ Stored data in bytes > `readonly` **version**: `string` = `""` -Defined in: [messages/ServerInfo.ts:43](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L43) +Defined in: [messages/ServerInfo.ts:43](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L43) Version storage server @@ -200,7 +200,7 @@ Version storage server > `static` **parse**(`data`): `ServerInfo` -Defined in: [messages/ServerInfo.ts:80](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/ServerInfo.ts#L80) +Defined in: [messages/ServerInfo.ts:80](https://github.com/reductstore/reduct-js/blob/main/src/messages/ServerInfo.ts#L80) ##### Parameters diff --git a/docs/sdk/js/msg/status/index.mdx b/docs/sdk/js/msg/status/index.mdx index 3a2b885f..a79ea5ca 100644 --- a/docs/sdk/js/msg/status/index.mdx +++ b/docs/sdk/js/msg/status/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Status Module of the ReductStore Client SDK f ## Status -Defined in: [messages/Status.ts:4](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L4) +Defined in: [messages/Status.ts:4](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L4) Resource status during deletion @@ -22,7 +22,7 @@ Resource status during deletion > **DELETING**: `"DELETING"` -Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L6) +Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L6) *** @@ -30,5 +30,5 @@ Defined in: [messages/Status.ts:6](https://github.com/reductstore/reduct-js/blob > **READY**: `"READY"` -Defined in: [messages/Status.ts:5](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Status.ts#L5) +Defined in: [messages/Status.ts:5](https://github.com/reductstore/reduct-js/blob/main/src/messages/Status.ts#L5) diff --git a/docs/sdk/js/msg/token/index.mdx b/docs/sdk/js/msg/token/index.mdx index 49c275f1..862855a4 100644 --- a/docs/sdk/js/msg/token/index.mdx +++ b/docs/sdk/js/msg/token/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Token Module of the ReductStore Client SDK fo ## Token -Defined in: [messages/Token.ts:114](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L114) +Defined in: [messages/Token.ts:114](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L114) Information about an access token @@ -32,7 +32,7 @@ Information about an access token > `readonly` **createdAt**: `number` = `0` -Defined in: [messages/Token.ts:123](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L123) +Defined in: [messages/Token.ts:123](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L123) Creation time of the token as unix timestamp in milliseconds @@ -42,7 +42,7 @@ Creation time of the token as unix timestamp in milliseconds > `readonly` `optional` **expiresAt**: `number` -Defined in: [messages/Token.ts:143](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L143) +Defined in: [messages/Token.ts:143](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L143) Expiration time as unix timestamp in milliseconds @@ -52,7 +52,7 @@ Expiration time as unix timestamp in milliseconds > `readonly` `optional` **ipAllowlist**: `string`[] -Defined in: [messages/Token.ts:148](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L148) +Defined in: [messages/Token.ts:148](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L148) List of IP addresses and CIDR ranges allowed to use the token @@ -62,7 +62,7 @@ List of IP addresses and CIDR ranges allowed to use the token > `readonly` `optional` **isExpired**: `boolean` -Defined in: [messages/Token.ts:138](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L138) +Defined in: [messages/Token.ts:138](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L138) True if the token is expired @@ -72,7 +72,7 @@ True if the token is expired > `readonly` `optional` **isProvisioned**: `boolean` = `false` -Defined in: [messages/Token.ts:153](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L153) +Defined in: [messages/Token.ts:153](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L153) Is the token provisioned, and you can't remove it or change it @@ -82,7 +82,7 @@ Is the token provisioned, and you can't remove it or change it > `readonly` `optional` **lastAccess**: `number` -Defined in: [messages/Token.ts:128](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L128) +Defined in: [messages/Token.ts:128](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L128) Last access time of the token as unix timestamp in milliseconds @@ -92,7 +92,7 @@ Last access time of the token as unix timestamp in milliseconds > `readonly` **name**: `string` = `""` -Defined in: [messages/Token.ts:118](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L118) +Defined in: [messages/Token.ts:118](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L118) Name of the token @@ -102,7 +102,7 @@ Name of the token > `readonly` `optional` **permissions**: [`TokenPermissions`](../api/classes/TokenPermissions) -Defined in: [messages/Token.ts:158](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L158) +Defined in: [messages/Token.ts:158](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L158) Permissions of the token @@ -112,7 +112,7 @@ Permissions of the token > `readonly` `optional` **ttl**: `number` -Defined in: [messages/Token.ts:133](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L133) +Defined in: [messages/Token.ts:133](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L133) Time to live in seconds @@ -122,7 +122,7 @@ Time to live in seconds > `static` **parse**(`data`): `Token` -Defined in: [messages/Token.ts:160](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L160) +Defined in: [messages/Token.ts:160](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L160) ##### Parameters @@ -136,7 +136,7 @@ Defined in: [messages/Token.ts:160](https://github.com/reductstore/reduct-js/blo ## TokenCreateRequest -Defined in: [messages/Token.ts:23](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L23) +Defined in: [messages/Token.ts:23](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L23) Token create request @@ -156,7 +156,7 @@ Token create request > `readonly` `optional` **expiresAt**: `number` -Defined in: [messages/Token.ts:32](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L32) +Defined in: [messages/Token.ts:32](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L32) Expiration time as unix timestamp in milliseconds @@ -166,7 +166,7 @@ Expiration time as unix timestamp in milliseconds > `readonly` `optional` **ipAllowlist**: `string`[] -Defined in: [messages/Token.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L42) +Defined in: [messages/Token.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L42) List of IP addresses and CIDR ranges allowed to use the token @@ -176,7 +176,7 @@ List of IP addresses and CIDR ranges allowed to use the token > `readonly` **permissions**: [`TokenPermissions`](../api/classes/TokenPermissions) -Defined in: [messages/Token.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L27) +Defined in: [messages/Token.ts:27](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L27) Permissions for the token @@ -186,7 +186,7 @@ Permissions for the token > `readonly` `optional` **ttl**: `number` -Defined in: [messages/Token.ts:37](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L37) +Defined in: [messages/Token.ts:37](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L37) Time to live in seconds @@ -196,7 +196,7 @@ Time to live in seconds > `static` **serialize**(`data`): `OriginalTokenCreateRequest` -Defined in: [messages/Token.ts:44](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L44) +Defined in: [messages/Token.ts:44](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L44) ##### Parameters @@ -210,7 +210,7 @@ Defined in: [messages/Token.ts:44](https://github.com/reductstore/reduct-js/blob ## TokenPermissions -Defined in: [messages/Token.ts:60](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L60) +Defined in: [messages/Token.ts:60](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L60) Token Permissions @@ -230,7 +230,7 @@ Token Permissions > `readonly` **fullAccess**: `boolean` = `false` -Defined in: [messages/Token.ts:65](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L65) +Defined in: [messages/Token.ts:65](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L65) Full access The token allows to create, remove and update settings of buckets, manage tokens and read and write data. @@ -241,7 +241,7 @@ The token allows to create, remove and update settings of buckets, manage tokens > `readonly` `optional` **read**: `string`[] = `[]` -Defined in: [messages/Token.ts:71](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L71) +Defined in: [messages/Token.ts:71](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L71) Read access List of buckets allowed to read @@ -252,7 +252,7 @@ List of buckets allowed to read > `readonly` `optional` **write**: `string`[] = `[]` -Defined in: [messages/Token.ts:77](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L77) +Defined in: [messages/Token.ts:77](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L77) Write access List of buckets allowed to write @@ -263,7 +263,7 @@ List of buckets allowed to write > `static` **parse**(`data`): `TokenPermissions` -Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L79) +Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L79) ##### Parameters @@ -281,7 +281,7 @@ Defined in: [messages/Token.ts:79](https://github.com/reductstore/reduct-js/blob > `static` **serialize**(`data`): `OriginalTokenPermission` -Defined in: [messages/Token.ts:87](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/messages/Token.ts#L87) +Defined in: [messages/Token.ts:87](https://github.com/reductstore/reduct-js/blob/main/src/messages/Token.ts#L87) ##### Parameters diff --git a/docs/sdk/js/record-batch/index.mdx b/docs/sdk/js/record-batch/index.mdx index d7b3cc73..f68f979a 100644 --- a/docs/sdk/js/record-batch/index.mdx +++ b/docs/sdk/js/record-batch/index.mdx @@ -12,7 +12,7 @@ description: API reference for the Record Batch Module of the ReductStore Client ## RecordBatch -Defined in: [RecordBatch.ts:34](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L34) +Defined in: [RecordBatch.ts:34](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L34) Batch of records to write them in one request (batch protocol v2). @@ -22,7 +22,7 @@ Batch of records to write them in one request (batch protocol v2). > **new RecordBatch**(`bucketName`, `httpClient`, `type`): `RecordBatch` -Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L42) +Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L42) ##### Parameters @@ -48,7 +48,7 @@ Defined in: [RecordBatch.ts:42](https://github.com/reductstore/reduct-js/blob/e2 > **add**(`entry`, `ts`, `data`, `contentType?`, `labels?`): `void` -Defined in: [RecordBatch.ts:63](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L63) +Defined in: [RecordBatch.ts:63](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L63) Add record to batch with entry name. @@ -94,7 +94,7 @@ default: {} > **addOnlyLabels**(`entry`, `ts`, `labels`): `void` -Defined in: [RecordBatch.ts:97](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L97) +Defined in: [RecordBatch.ts:97](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L97) Add labels to batch for update. @@ -128,7 +128,7 @@ labels to update > **addOnlyTimestamp**(`entry`, `ts`): `void` -Defined in: [RecordBatch.ts:119](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L119) +Defined in: [RecordBatch.ts:119](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L119) Add timestamps to batch for removal. @@ -156,7 +156,7 @@ timestamp of record as a UNIX timestamp in microseconds > **clear**(): `void` -Defined in: [RecordBatch.ts:259](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L259) +Defined in: [RecordBatch.ts:259](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L259) Clear batch @@ -170,7 +170,7 @@ Clear batch > **items**(): \[\[`string`, `bigint`\], `RecordBatchItem`\][] -Defined in: [RecordBatch.ts:212](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L212) +Defined in: [RecordBatch.ts:212](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L212) Get records in batch sorted by timestamp and entry name. @@ -184,7 +184,7 @@ Get records in batch sorted by timestamp and entry name. > **lastAccessTime**(): `number` -Defined in: [RecordBatch.ts:245](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L245) +Defined in: [RecordBatch.ts:245](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L245) Get last access time of batch @@ -198,7 +198,7 @@ Get last access time of batch > **recordCount**(): `number` -Defined in: [RecordBatch.ts:252](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L252) +Defined in: [RecordBatch.ts:252](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L252) Get number of records in batch @@ -212,7 +212,7 @@ Get number of records in batch > **send**(): `Promise`<`Map`<`string`, `Map`<`bigint`, [`APIError`](api/classes/APIError)>>> -Defined in: [RecordBatch.ts:140](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L140) +Defined in: [RecordBatch.ts:140](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L140) Send batch request (Multi-entry API). @@ -226,7 +226,7 @@ Send batch request (Multi-entry API). > **size**(): `bigint` -Defined in: [RecordBatch.ts:238](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L238) +Defined in: [RecordBatch.ts:238](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L238) Get total size of batch @@ -239,7 +239,7 @@ Get total size of batch ## RecordBatchType -Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L25) +Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L25) ### Enumeration Members @@ -247,7 +247,7 @@ Defined in: [RecordBatch.ts:25](https://github.com/reductstore/reduct-js/blob/e2 > **REMOVE**: `2` -Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L28) +Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L28) *** @@ -255,7 +255,7 @@ Defined in: [RecordBatch.ts:28](https://github.com/reductstore/reduct-js/blob/e2 > **UPDATE**: `1` -Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L27) +Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L27) *** @@ -263,5 +263,5 @@ Defined in: [RecordBatch.ts:27](https://github.com/reductstore/reduct-js/blob/e2 > **WRITE**: `0` -Defined in: [RecordBatch.ts:26](https://github.com/reductstore/reduct-js/blob/e2b7a718b68db625d48f717e9082216ff8a962ad/src/RecordBatch.ts#L26) +Defined in: [RecordBatch.ts:26](https://github.com/reductstore/reduct-js/blob/main/src/RecordBatch.ts#L26) diff --git a/docs/sdk/py/bucket/index.mdx b/docs/sdk/py/bucket/index.mdx index 217586a3..2c697192 100644 --- a/docs/sdk/py/bucket/index.mdx +++ b/docs/sdk/py/bucket/index.mdx @@ -675,7 +675,9 @@ multiple entries. You can also use wildcards in entry names. #### write\_attachments ```python -async def write_attachments(entry_name: str, attachments: dict[str, dict]) +async def write_attachments(entry_name: str, + attachments: dict[str, dict], + content_type: str = None) ``` Write attachments to an entry diff --git a/sidebars.json b/sidebars.json index acd6b727..4da67ad5 100644 --- a/sidebars.json +++ b/sidebars.json @@ -63,6 +63,7 @@ "guides/data-ingestion", "guides/data-querying", "guides/data-management", + "guides/lifecycle-policies", "guides/data-replication", "guides/access-control", "guides/disaster-recovery" From bd3d4ac3f0f663fc36c2eaf5fb21df3c20c3dbf9 Mon Sep 17 00:00:00 2001 From: Alexey Timin Date: Sun, 10 May 2026 11:10:04 +0200 Subject: [PATCH 02/14] update with new limits --- docs/configuration/provisioning.mdx | 25 ++++++++++++++----------- docs/glossary.mdx | 2 +- docs/guides/data-management.mdx | 3 ++- 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/docs/configuration/provisioning.mdx b/docs/configuration/provisioning.mdx index 13fc2be2..08d76c0a 100644 --- a/docs/configuration/provisioning.mdx +++ b/docs/configuration/provisioning.mdx @@ -86,16 +86,16 @@ These settings apply to all replication tasks created through provisioning, the You can provision lifecycle policies by setting environment variables. Lifecycle policies run in the background and currently support deleting old records from a bucket. -| Name | Default | Description | -| ---------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------- | -| `RS_LIFECYCLE__NAME` | | Provisioned lifecycle policy name (required) | -| `RS_LIFECYCLE__TYPE` | delete | Lifecycle action type. Currently only `delete` is supported. | -| `RS_LIFECYCLE__BUCKET` | | Bucket to apply the lifecycle policy to (required) | -| `RS_LIFECYCLE__MAX_AGE` | | Maximum record age before deletion, for example `30d`, `24h`, or `3600s` (required) | -| `RS_LIFECYCLE__INTERVAL` | - | Interval between lifecycle runs, for example `10m`, `1h`, or `3600s` | -| `RS_LIFECYCLE__ENTRIES` | | Comma-separated list of entries to clean. If empty, all entries are matched. Prefix wildcards are supported. | -| `RS_LIFECYCLE__WHEN` | | JSON condition for records to delete. Uses the same condition syntax as queries, but `#ext` is not supported. | -| `RS_LIFECYCLE__MODE` | enabled | Policy mode: `enabled` or `disabled`. | +| Name | Default | Description | +| ---------------------------- | ------- | ------------------------------------------------------------------------------------------------------------- | +| `RS_LIFECYCLE__NAME` | | Provisioned lifecycle policy name (required) | +| `RS_LIFECYCLE__TYPE` | delete | Lifecycle action type. Currently only `delete` is supported. | +| `RS_LIFECYCLE__BUCKET` | | Bucket to apply the lifecycle policy to (required) | +| `RS_LIFECYCLE__MAX_AGE` | | Maximum record age before deletion, for example `30d`, `24h`, or `3600s` (required). Minimum value is `1h`. | +| `RS_LIFECYCLE__INTERVAL` | 3600s | Interval between lifecycle runs, for example `10m`, `1h`, or `3600s`. Minimum value is `10m`. | +| `RS_LIFECYCLE__ENTRIES` | | Comma-separated list of entries to clean. If empty, all entries are matched. Prefix wildcards are supported. | +| `RS_LIFECYCLE__WHEN` | | JSON condition for records to delete. Uses the same condition syntax as queries, but `#ext` is not supported. | +| `RS_LIFECYCLE__MODE` | enabled | Policy mode: `enabled`, `disabled`, or `dry_run`. | Example: @@ -107,8 +107,11 @@ RS_LIFECYCLE_A_ENTRIES=sensors/*,env/temp,env/humidity RS_LIFECYCLE_A_MAX_AGE=30d RS_LIFECYCLE_A_INTERVAL=10m RS_LIFECYCLE_A_WHEN={"$eq":["&label","true"]} +RS_LIFECYCLE_A_MODE=dry_run ``` -Provisioned lifecycle policies cannot be updated or removed through the API. Change their environment variables and restart ReductStore to update them. +Use `dry_run` mode to count matching records and write lifecycle audit events without deleting data. This is useful for validating `max_age`, `entries`, and `when` filters before switching the policy to `enabled`. + +Provisioned lifecycle policies cannot be updated or removed through the API. Change their environment variables and restart ReductStore to update them. If `RS_LIFECYCLE__MODE` is not set, ReductStore preserves the existing stored mode for an already provisioned lifecycle policy. For more information about lifecycle policies, see the **[Lifecycle Policies Guide](../guides/lifecycle-policies.mdx)**. diff --git a/docs/glossary.mdx b/docs/glossary.mdx index ce2fa6a3..fc1918ef 100644 --- a/docs/glossary.mdx +++ b/docs/glossary.mdx @@ -127,6 +127,6 @@ A secure way to share data from ReductStore without using access tokens. Query l ## lifecycle policy -A background task that periodically applies an action (such as deleting old records) to a bucket. Lifecycle policies can be scoped to specific entries and filtered with a conditional query. +A background task that periodically applies an action, such as deleting old records, to a bucket. Lifecycle policies can be scoped to specific entries, filtered with a conditional query, disabled, or run in `dry_run` preview mode. _Related entries:_ bucket, record, conditional query diff --git a/docs/guides/data-management.mdx b/docs/guides/data-management.mdx index 97d4f342..85fac11f 100644 --- a/docs/guides/data-management.mdx +++ b/docs/guides/data-management.mdx @@ -132,7 +132,8 @@ You can do this using the Client SDKs, the Reduct CLI, or the HTTP API. For automatic cleanup, use lifecycle policies. A delete lifecycle policy periodically removes records older than `max_age` from a bucket. You can limit cleanup to selected -entries with `entries` and to matching records with a `when` condition. +entries with `entries` and to matching records with a `when` condition. Use `dry_run` +mode to preview how many records match before enabling deletion. For a full explanation and provisioning examples, see the **[Lifecycle Policies](lifecycle-policies.mdx)** guide. From d3851c5198f19f6330e312130c67fa4fbe0a6cf1 Mon Sep 17 00:00:00 2001 From: Alexey Timin Date: Sun, 10 May 2026 11:41:50 +0200 Subject: [PATCH 03/14] add files --- .gitignore | 3 + .../provisioning/lifecycle_create.yml | 22 +++++ docs/guides/lifecycle-policies.mdx | 80 +++++++++++++++++ docs/reduct-bridge/input/mqtt/index.mdx | 87 +++++++++++++++++++ 4 files changed, 192 insertions(+) create mode 100644 docs/examples/provisioning/lifecycle_create.yml create mode 100644 docs/guides/lifecycle-policies.mdx create mode 100644 docs/reduct-bridge/input/mqtt/index.mdx diff --git a/.gitignore b/.gitignore index 75f95099..090efeb7 100644 --- a/.gitignore +++ b/.gitignore @@ -41,3 +41,6 @@ package-lock.json # local indexing artifacts .ai/ + + +.kilo diff --git a/docs/examples/provisioning/lifecycle_create.yml b/docs/examples/provisioning/lifecycle_create.yml new file mode 100644 index 00000000..f6300fb4 --- /dev/null +++ b/docs/examples/provisioning/lifecycle_create.yml @@ -0,0 +1,22 @@ +version: "3" +services: + reductstore: + image: reduct/store:latest + ports: + - "8383:8383" + volumes: + - ./data:/data + environment: + RS_API_TOKEN: my-api-token + RS_BUCKET_1_NAME: telemetry + RS_LIFECYCLE_1_NAME: purge-sensors-30d + RS_LIFECYCLE_1_BUCKET: telemetry + RS_LIFECYCLE_1_TYPE: delete + RS_LIFECYCLE_1_MAX_AGE: 30d + RS_LIFECYCLE_1_INTERVAL: 10m + RS_LIFECYCLE_1_ENTRIES: "sensor-1,sensor-2" + + RS_LIFECYCLE_1_WHEN: | + { + "&sensor_type": { "$eq": "temperature" } + } \ No newline at end of file diff --git a/docs/guides/lifecycle-policies.mdx b/docs/guides/lifecycle-policies.mdx new file mode 100644 index 00000000..6ad021cf --- /dev/null +++ b/docs/guides/lifecycle-policies.mdx @@ -0,0 +1,80 @@ +--- +title: Lifecycle Policies +description: Complete guide to managing lifecycle policies in ReductStore +--- + +import CodeBlock from "@theme/CodeBlock"; +import lifecycleCreate from "!!raw-loader!@site/docs/examples/provisioning/lifecycle_create.yml"; + + + + + +# Lifecycle Policies + +**[Lifecycle policies](../glossary#lifecycle-policy)** are background tasks that automatically clean up old records from your **[buckets](../glossary#bucket)**. They help you manage storage efficiently by removing outdated data based on rules you define. + +## How It Works + +A lifecycle policy runs at a configurable interval and scans the target bucket for records older than `max_age`. It removes these records and logs the operation in the `$audit` system bucket. You can optionally scope policies to specific **[entries](../glossary#entry)** or filter records using conditions. + +Policies are stored on disk and remain active after restarts. However, read-only (replica) instances cannot execute lifecycle policies. Every policy run is recorded as a `lifecycle_run` event in the `$audit` bucket for transparency and debugging. + +## Supported Actions + +Currently, ReductStore supports one action type for lifecycle policies: + +| Type | Description | +|---------|--------------------------------------------------| +| `delete` | Removes records older than `max_age` from the bucket | + +More action types may be added in future releases. + +## Policy Settings + +You can configure lifecycle policies using the following settings: + +| Setting | Description | Required | Default | +|-----------|-------------------------------------------------------------------------------------------------|----------|----------| +| `type` | Action type (e.g., `delete`) | No | `delete` | +| `bucket` | Target bucket name | Yes | - | +| `entries` | List of entries to scope the policy (wildcard `*` supported) | No | - | +| `max_age` | Maximum age of records before action is applied (e.g., `30d`, `1h`, `5m`) | Yes | - | +| `interval`| Policy execution interval (e.g., `3600s`, `10m`) | No | `3600s` | +| `when` | JSON condition to filter records (see **[Conditional Query Reference](/docs/conditional-query/index.mdx)**) | No | - | +| `mode` | Policy mode: `enabled` (default) or `disabled` | No | `enabled`| + +## Conditional Policies + +You can refine lifecycle policies using the `entries` and `when` parameters: + +- **`entries`**: Limit the policy to specific entries (e.g., `sensor-1,sensor-2` or `sensor-*`) +- **`when`**: Apply the policy only to records matching a condition (e.g., `{"&sensor_type": {"$eq": "temperature"}}`) + +For more details, see the **[Conditional Query Reference](/docs/conditional-query/index.mdx)**. + +## Example + +Imagine you store telemetry data from temperature sensors in a bucket called `telemetry`. You want to automatically delete records older than 30 days, but only for specific sensors (`sensor-1` and `sensor-2`) and only if the `sensor_type` label equals `temperature`. Here’s how you’d configure the policy: + +{lifecycleCreate} + +## Managing Policies + +Currently, lifecycle policies can only be provisioned using environment variables. They cannot be updated or removed via the API. + +:::info +Provisioned policies cannot be modified or deleted through the API. To make changes, update the environment variables and restart the ReductStore instance. +::: + +## Audit Logs + +Every lifecycle run generates a `lifecycle_run` event in the `$audit` bucket. The event includes: + +- Policy name and action type +- Target bucket and duration of the run +- Number of records processed +- Error details (if any) \ No newline at end of file diff --git a/docs/reduct-bridge/input/mqtt/index.mdx b/docs/reduct-bridge/input/mqtt/index.mdx new file mode 100644 index 00000000..0afbc756 --- /dev/null +++ b/docs/reduct-bridge/input/mqtt/index.mdx @@ -0,0 +1,87 @@ +--- +title: "MQTT input" +description: "Documentation for MQTT input in ReductBridge." +--- +# MQTT input + +The MQTT input subscribes to one or more MQTT topics and forwards messages into a pipeline. +Both `mqtt://` and `mqtts://` brokers are supported. + +MQTT label rules follow the same ordered model as the ROS inputs: + +- static labels are applied first +- payload field labels are applied after static labels and can override them +- MQTT v5 property labels are also applied in order and can override earlier labels + +For MQTT v5 property labels: + +- `property = "content_type"` reads the built-in MQTT v5 `content_type` property +- any other `property = ""` reads the MQTT v5 user property named `` + +## Configuration + +```toml +[inputs.mqtt.main] +broker = "mqtts://broker.example.com:8883" +client_id = "reduct-bridge" +version = "v5" +qos = 1 + +username = "bridge" +password = "${MQTT_PASSWORD}" + +entry_prefix = "/mqtt" + +[[inputs.mqtt.main.topics]] +name = "factory/+/telemetry" +entry_name = "telemetry" +content_type = "application/json" +# Optional label rules (default = []): +# 1) Dynamic field label: +# { field = "device_id", label = "device" } +# 2) Static labels: +# { static = { source = "mqtt", site = "lab" } } +# 3) MQTT v5 property label: +# { property = "content_type", label = "mime" } +# { property = "tenant", label = "tenant" } # MQTT v5 user property +labels = [ + { field = "device_id", label = "device" }, + { field = "site", label = "site" }, + { static = { source = "mqtt" } }, + { property = "content_type", label = "mime" }, + { property = "tenant", label = "tenant" } +] + +[[inputs.mqtt.main.topics]] +name = "factory/+/events" +labels = [ + { static = { source = "mqtt-events" } } +] +``` + +`entry_name`, `content_type`, and `labels` are configured per topic. `content_type` is used as the default record content type when an MQTT v5 publish does not provide a `content_type` property; for MQTT v3 it is used directly. +Use bare names such as `tenant`, `status`, or `id` for MQTT v5 user properties. + +### MQTT v3 example + +```toml +[inputs.mqtt.legacy] +broker = "mqtt://broker.example.com:1883" +client_id = "reduct-bridge-legacy" +version = "v3" +qos = 0 + +username = "legacy_user" +password = "${LEGACY_MQTT_PASSWORD}" + +entry_prefix = "/mqtt" + +[[inputs.mqtt.legacy.topics]] +name = "legacy/+/data" +entry_name = "legacy" +content_type = "application/json" +labels = [ + { field = "line", label = "line" }, + { static = { source = "mqtt-v3" } } +] +``` From c65a3ec01b1ae868f7a5e45572b682632f6f36d5 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:19:55 +0200 Subject: [PATCH 04/14] add cli example --- docs/examples/cli/lifecycle_policy_browse.sh | 3 +++ docs/examples/cli/lifecycle_policy_create.sh | 3 +++ docs/examples/cli/lifecycle_policy_mode.sh | 4 ++++ docs/examples/cli/lifecycle_policy_remove.sh | 2 ++ 4 files changed, 12 insertions(+) create mode 100644 docs/examples/cli/lifecycle_policy_browse.sh create mode 100644 docs/examples/cli/lifecycle_policy_create.sh create mode 100644 docs/examples/cli/lifecycle_policy_mode.sh create mode 100644 docs/examples/cli/lifecycle_policy_remove.sh diff --git a/docs/examples/cli/lifecycle_policy_browse.sh b/docs/examples/cli/lifecycle_policy_browse.sh new file mode 100644 index 00000000..24d7a33a --- /dev/null +++ b/docs/examples/cli/lifecycle_policy_browse.sh @@ -0,0 +1,3 @@ +reduct-cli alias add local -L http://localhost:8383 -t "my-token" +reduct-cli lifecycle ls local --full +reduct-cli lifecycle show local/my-lifecycle diff --git a/docs/examples/cli/lifecycle_policy_create.sh b/docs/examples/cli/lifecycle_policy_create.sh new file mode 100644 index 00000000..5594657d --- /dev/null +++ b/docs/examples/cli/lifecycle_policy_create.sh @@ -0,0 +1,3 @@ +reduct-cli alias add local -L http://localhost:8383 -t "my-token" +reduct-cli bucket create local/my-bucket +reduct-cli lifecycle create local/my-lifecycle my-bucket --max-age 30d --interval 1h --entries cli-example --when '{"&anomaly":{"$eq":1}}' diff --git a/docs/examples/cli/lifecycle_policy_mode.sh b/docs/examples/cli/lifecycle_policy_mode.sh new file mode 100644 index 00000000..7dfacc09 --- /dev/null +++ b/docs/examples/cli/lifecycle_policy_mode.sh @@ -0,0 +1,4 @@ +reduct-cli alias add local -L http://localhost:8383 -t "my-token" +reduct-cli lifecycle dry-run local/my-lifecycle +reduct-cli lifecycle disable local/my-lifecycle +reduct-cli lifecycle enable local/my-lifecycle diff --git a/docs/examples/cli/lifecycle_policy_remove.sh b/docs/examples/cli/lifecycle_policy_remove.sh new file mode 100644 index 00000000..ac94fa14 --- /dev/null +++ b/docs/examples/cli/lifecycle_policy_remove.sh @@ -0,0 +1,2 @@ +reduct-cli alias add local -L http://localhost:8383 -t "my-token" +reduct-cli lifecycle rm local/lifecycle-to-remove --yes From ce93cc9372c70e4d08d747181677a8708b86c5d5 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:22:17 +0200 Subject: [PATCH 05/14] add cpp example --- .../cpp/src/lifecycle_policy_browse.cc | 27 +++++++++++++++++++ .../cpp/src/lifecycle_policy_create.cc | 22 +++++++++++++++ .../examples/cpp/src/lifecycle_policy_mode.cc | 18 +++++++++++++ .../cpp/src/lifecycle_policy_remove.cc | 12 +++++++++ 4 files changed, 79 insertions(+) create mode 100644 docs/examples/cpp/src/lifecycle_policy_browse.cc create mode 100644 docs/examples/cpp/src/lifecycle_policy_create.cc create mode 100644 docs/examples/cpp/src/lifecycle_policy_mode.cc create mode 100644 docs/examples/cpp/src/lifecycle_policy_remove.cc diff --git a/docs/examples/cpp/src/lifecycle_policy_browse.cc b/docs/examples/cpp/src/lifecycle_policy_browse.cc new file mode 100644 index 00000000..d8eb1640 --- /dev/null +++ b/docs/examples/cpp/src/lifecycle_policy_browse.cc @@ -0,0 +1,27 @@ +#include +#include + +using reduct::IClient; + +int main() { + auto client = IClient::Build("http://127.0.0.1:8383", {.api_token = "my-token"}); + + auto [lifecycles, list_err] = client->GetLifecycleList(); + if (list_err != reduct::Error::kOk) { + return 1; + } + + for (const auto& lifecycle : lifecycles) { + std::cout << "Lifecycle: " << lifecycle.name << std::endl; + std::cout << "Running: " << lifecycle.is_running << std::endl; + std::cout << "Provisioned: " << lifecycle.is_provisioned << std::endl; + } + + auto [detail, detail_err] = client->GetLifecycle("my-lifecycle"); + if (detail_err != reduct::Error::kOk) { + return 1; + } + + std::cout << "Lifecycle: " << detail.info.name << std::endl; + std::cout << "Bucket: " << detail.settings.bucket << std::endl; +} diff --git a/docs/examples/cpp/src/lifecycle_policy_create.cc b/docs/examples/cpp/src/lifecycle_policy_create.cc new file mode 100644 index 00000000..e1520931 --- /dev/null +++ b/docs/examples/cpp/src/lifecycle_policy_create.cc @@ -0,0 +1,22 @@ +#include +#include + +using reduct::Error; +using reduct::IClient; + +int main() { + auto client = IClient::Build("http://127.0.0.1:8383", {.api_token = "my-token"}); + + auto [bucket, bucket_err] = client->GetOrCreateBucket("my-bucket"); + assert(bucket_err == Error::kOk); + + auto err = client->CreateLifecycle("my-lifecycle", IClient::LifecycleSettings{ + .type = IClient::LifecycleType::kDelete, + .bucket = "my-bucket", + .entries = {"cpp-example"}, + .max_age = "30d", + .interval = "1h", + .when = R"({"&anomaly":{"$eq":1}})", + }); + assert(err == Error::kOk); +} diff --git a/docs/examples/cpp/src/lifecycle_policy_mode.cc b/docs/examples/cpp/src/lifecycle_policy_mode.cc new file mode 100644 index 00000000..5fc3cfba --- /dev/null +++ b/docs/examples/cpp/src/lifecycle_policy_mode.cc @@ -0,0 +1,18 @@ +#include +#include + +using reduct::Error; +using reduct::IClient; + +int main() { + auto client = IClient::Build("http://127.0.0.1:8383", {.api_token = "my-token"}); + + auto err = client->SetLifecycleMode("my-lifecycle", IClient::LifecycleMode::kDryRun); + assert(err == Error::kOk); + + err = client->SetLifecycleMode("my-lifecycle", IClient::LifecycleMode::kDisabled); + assert(err == Error::kOk); + + err = client->SetLifecycleMode("my-lifecycle", IClient::LifecycleMode::kEnabled); + assert(err == Error::kOk); +} diff --git a/docs/examples/cpp/src/lifecycle_policy_remove.cc b/docs/examples/cpp/src/lifecycle_policy_remove.cc new file mode 100644 index 00000000..55cdf05e --- /dev/null +++ b/docs/examples/cpp/src/lifecycle_policy_remove.cc @@ -0,0 +1,12 @@ +#include +#include + +using reduct::Error; +using reduct::IClient; + +int main() { + auto client = IClient::Build("http://127.0.0.1:8383", {.api_token = "my-token"}); + + auto err = client->DeleteLifecycle("lifecycle-to-remove"); + assert(err == Error::kOk); +} From 2cb904f11094a081fcdb4dac3e45d1687fbbe183 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:26:16 +0200 Subject: [PATCH 06/14] add curl example --- docs/examples/curl/lifecycle_policy_browse.sh | 11 ++++++++++ docs/examples/curl/lifecycle_policy_create.sh | 10 ++++++++++ docs/examples/curl/lifecycle_policy_mode.sh | 20 +++++++++++++++++++ docs/examples/curl/lifecycle_policy_remove.sh | 9 +++++++++ 4 files changed, 50 insertions(+) create mode 100644 docs/examples/curl/lifecycle_policy_browse.sh create mode 100644 docs/examples/curl/lifecycle_policy_create.sh create mode 100644 docs/examples/curl/lifecycle_policy_mode.sh create mode 100644 docs/examples/curl/lifecycle_policy_remove.sh diff --git a/docs/examples/curl/lifecycle_policy_browse.sh b/docs/examples/curl/lifecycle_policy_browse.sh new file mode 100644 index 00000000..83181f67 --- /dev/null +++ b/docs/examples/curl/lifecycle_policy_browse.sh @@ -0,0 +1,11 @@ +#!/bin/bash +set -e -x + +API_PATH="http://127.0.0.1:8383/api/v1" +AUTH_HEADER="Authorization: Bearer my-token" + +curl -H "${AUTH_HEADER}" \ + "${API_PATH}"/lifecycles + +curl -H "${AUTH_HEADER}" \ + "${API_PATH}"/lifecycles/my-lifecycle diff --git a/docs/examples/curl/lifecycle_policy_create.sh b/docs/examples/curl/lifecycle_policy_create.sh new file mode 100644 index 00000000..95dd954f --- /dev/null +++ b/docs/examples/curl/lifecycle_policy_create.sh @@ -0,0 +1,10 @@ +#!/bin/bash +set -e -x + +API_PATH="http://127.0.0.1:8383/api/v1" +AUTH_HEADER="Authorization: Bearer my-token" + +curl -X POST \ + -H "${AUTH_HEADER}" \ + -d '{"bucket":"my-bucket","entries":["curl-example"],"max_age":"30d","interval":"1h","when":{"&anomaly":{"$eq":1}}}' \ + "${API_PATH}"/lifecycles/my-lifecycle diff --git a/docs/examples/curl/lifecycle_policy_mode.sh b/docs/examples/curl/lifecycle_policy_mode.sh new file mode 100644 index 00000000..bf58bb7a --- /dev/null +++ b/docs/examples/curl/lifecycle_policy_mode.sh @@ -0,0 +1,20 @@ +#!/bin/bash +set -e -x + +API_PATH="http://127.0.0.1:8383/api/v1" +AUTH_HEADER="Authorization: Bearer my-token" + +curl -X PATCH \ + -H "${AUTH_HEADER}" \ + -d '{"mode":"dry_run"}' \ + "${API_PATH}"/lifecycles/my-lifecycle/mode + +curl -X PATCH \ + -H "${AUTH_HEADER}" \ + -d '{"mode":"disabled"}' \ + "${API_PATH}"/lifecycles/my-lifecycle/mode + +curl -X PATCH \ + -H "${AUTH_HEADER}" \ + -d '{"mode":"enabled"}' \ + "${API_PATH}"/lifecycles/my-lifecycle/mode diff --git a/docs/examples/curl/lifecycle_policy_remove.sh b/docs/examples/curl/lifecycle_policy_remove.sh new file mode 100644 index 00000000..6c989f2d --- /dev/null +++ b/docs/examples/curl/lifecycle_policy_remove.sh @@ -0,0 +1,9 @@ +#!/bin/bash +set -e -x + +API_PATH="http://127.0.0.1:8383/api/v1" +AUTH_HEADER="Authorization: Bearer my-token" + +curl -X DELETE \ + -H "${AUTH_HEADER}" \ + "${API_PATH}"/lifecycles/lifecycle-to-remove From 7487607a5fbd8fed84b70a78f22f931aad3f1f28 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:27:47 +0200 Subject: [PATCH 07/14] add go example --- .../go/src/lifecycle_policy_browse.go | 30 +++++++++++++++++ .../go/src/lifecycle_policy_create.go | 32 +++++++++++++++++++ docs/examples/go/src/lifecycle_policy_mode.go | 22 +++++++++++++ .../go/src/lifecycle_policy_remove.go | 15 +++++++++ 4 files changed, 99 insertions(+) create mode 100644 docs/examples/go/src/lifecycle_policy_browse.go create mode 100644 docs/examples/go/src/lifecycle_policy_create.go create mode 100644 docs/examples/go/src/lifecycle_policy_mode.go create mode 100644 docs/examples/go/src/lifecycle_policy_remove.go diff --git a/docs/examples/go/src/lifecycle_policy_browse.go b/docs/examples/go/src/lifecycle_policy_browse.go new file mode 100644 index 00000000..fdad81ae --- /dev/null +++ b/docs/examples/go/src/lifecycle_policy_browse.go @@ -0,0 +1,30 @@ +package main + +import ( + "context" + + reduct "github.com/reductstore/reduct-go" +) + +func main() { + client := reduct.NewClient("http://localhost:8383", reduct.ClientOptions{APIToken: "my-token"}) + + lifecycles, err := client.GetLifecycles(context.Background()) + if err != nil { + panic(err) + } + + for _, lifecycle := range lifecycles { + println("Lifecycle:", lifecycle.Name) + println("Mode:", string(lifecycle.Mode)) + println("Running:", lifecycle.IsRunning) + println("Provisioned:", lifecycle.IsProvisioned) + } + + detail, err := client.GetLifecycle(context.Background(), "my-lifecycle") + if err != nil { + panic(err) + } + println("Lifecycle:", detail.Info.Name) + println("Bucket:", detail.Settings.Bucket) +} diff --git a/docs/examples/go/src/lifecycle_policy_create.go b/docs/examples/go/src/lifecycle_policy_create.go new file mode 100644 index 00000000..818766e8 --- /dev/null +++ b/docs/examples/go/src/lifecycle_policy_create.go @@ -0,0 +1,32 @@ +package main + +import ( + "context" + + reduct "github.com/reductstore/reduct-go" + model "github.com/reductstore/reduct-go/model" +) + +func main() { + client := reduct.NewClient("http://localhost:8383", reduct.ClientOptions{APIToken: "my-token"}) + _, err := client.CreateOrGetBucket(context.Background(), "my-bucket", nil) + if err != nil { + panic(err) + } + + settings := model.LifecycleSettings{ + LifecycleType: model.LifecycleTypeDelete, + Bucket: "my-bucket", + Entries: []string{"go-example"}, + MaxAge: "30d", + Interval: "1h", + When: map[string]any{ + "&anomaly": map[string]any{"$eq": 1}, + }, + } + + err = client.CreateLifecycle(context.Background(), "my-lifecycle", settings) + if err != nil { + panic(err) + } +} diff --git a/docs/examples/go/src/lifecycle_policy_mode.go b/docs/examples/go/src/lifecycle_policy_mode.go new file mode 100644 index 00000000..25265eb6 --- /dev/null +++ b/docs/examples/go/src/lifecycle_policy_mode.go @@ -0,0 +1,22 @@ +package main + +import ( + "context" + + reduct "github.com/reductstore/reduct-go" + model "github.com/reductstore/reduct-go/model" +) + +func main() { + client := reduct.NewClient("http://localhost:8383", reduct.ClientOptions{APIToken: "my-token"}) + + if err := client.SetLifecycleMode(context.Background(), "my-lifecycle", model.LifecycleModeDryRun); err != nil { + panic(err) + } + if err := client.SetLifecycleMode(context.Background(), "my-lifecycle", model.LifecycleModeDisabled); err != nil { + panic(err) + } + if err := client.SetLifecycleMode(context.Background(), "my-lifecycle", model.LifecycleModeEnabled); err != nil { + panic(err) + } +} diff --git a/docs/examples/go/src/lifecycle_policy_remove.go b/docs/examples/go/src/lifecycle_policy_remove.go new file mode 100644 index 00000000..13ac078c --- /dev/null +++ b/docs/examples/go/src/lifecycle_policy_remove.go @@ -0,0 +1,15 @@ +package main + +import ( + "context" + + reduct "github.com/reductstore/reduct-go" +) + +func main() { + client := reduct.NewClient("http://localhost:8383", reduct.ClientOptions{APIToken: "my-token"}) + + if err := client.DeleteLifecycle(context.Background(), "lifecycle-to-remove"); err != nil { + panic(err) + } +} From 7265c197d51f86c6c52ab1f8186d7611398361ad Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:29:29 +0200 Subject: [PATCH 08/14] add js example --- docs/examples/js/src/lifecycle_policy_browse.mjs | 14 ++++++++++++++ docs/examples/js/src/lifecycle_policy_create.mjs | 15 +++++++++++++++ docs/examples/js/src/lifecycle_policy_mode.mjs | 7 +++++++ docs/examples/js/src/lifecycle_policy_remove.mjs | 4 ++++ 4 files changed, 40 insertions(+) create mode 100644 docs/examples/js/src/lifecycle_policy_browse.mjs create mode 100644 docs/examples/js/src/lifecycle_policy_create.mjs create mode 100644 docs/examples/js/src/lifecycle_policy_mode.mjs create mode 100644 docs/examples/js/src/lifecycle_policy_remove.mjs diff --git a/docs/examples/js/src/lifecycle_policy_browse.mjs b/docs/examples/js/src/lifecycle_policy_browse.mjs new file mode 100644 index 00000000..fe959760 --- /dev/null +++ b/docs/examples/js/src/lifecycle_policy_browse.mjs @@ -0,0 +1,14 @@ +import { Client } from "reduct-js"; + +const client = new Client("http://127.0.0.1:8383", { apiToken: "my-token" }); + +for (const lifecycle of await client.getLifecycleList()) { + console.log("Lifecycle:", lifecycle.name); + console.log("Mode:", lifecycle.mode); + console.log("Running:", lifecycle.isRunning); + console.log("Provisioned:", lifecycle.isProvisioned); +} + +const details = await client.getLifecycle("my-lifecycle"); +console.log("Lifecycle:", details.info.name); +console.log("Settings:", details.settings); diff --git a/docs/examples/js/src/lifecycle_policy_create.mjs b/docs/examples/js/src/lifecycle_policy_create.mjs new file mode 100644 index 00000000..a913c59e --- /dev/null +++ b/docs/examples/js/src/lifecycle_policy_create.mjs @@ -0,0 +1,15 @@ +import { Client, LifecycleType } from "reduct-js"; + +const client = new Client("http://127.0.0.1:8383", { apiToken: "my-token" }); +await client.getOrCreateBucket("my-bucket"); + +const settings = { + lifecycleType: LifecycleType.DELETE, + bucket: "my-bucket", + entries: ["js-example"], + maxAge: "30d", + interval: "1h", + when: { "&anomaly": { $eq: 1 } }, +}; + +await client.createLifecycle("my-lifecycle", settings); diff --git a/docs/examples/js/src/lifecycle_policy_mode.mjs b/docs/examples/js/src/lifecycle_policy_mode.mjs new file mode 100644 index 00000000..5faed484 --- /dev/null +++ b/docs/examples/js/src/lifecycle_policy_mode.mjs @@ -0,0 +1,7 @@ +import { Client, LifecycleMode } from "reduct-js"; + +const client = new Client("http://127.0.0.1:8383", { apiToken: "my-token" }); + +await client.setLifecycleMode("my-lifecycle", LifecycleMode.DRY_RUN); +await client.setLifecycleMode("my-lifecycle", LifecycleMode.DISABLED); +await client.setLifecycleMode("my-lifecycle", LifecycleMode.ENABLED); diff --git a/docs/examples/js/src/lifecycle_policy_remove.mjs b/docs/examples/js/src/lifecycle_policy_remove.mjs new file mode 100644 index 00000000..a19e1777 --- /dev/null +++ b/docs/examples/js/src/lifecycle_policy_remove.mjs @@ -0,0 +1,4 @@ +import { Client } from "reduct-js"; + +const client = new Client("http://127.0.0.1:8383", { apiToken: "my-token" }); +await client.deleteLifecycle("lifecycle-to-remove"); From 14af676b4884cc98fb58ff9f02037e1b32907875 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:33:09 +0200 Subject: [PATCH 09/14] add python example --- .../py/src/lifecycle_policy_browse.py | 19 +++++++++++++++++ .../py/src/lifecycle_policy_create.py | 21 +++++++++++++++++++ docs/examples/py/src/lifecycle_policy_mode.py | 13 ++++++++++++ .../py/src/lifecycle_policy_remove.py | 11 ++++++++++ 4 files changed, 64 insertions(+) create mode 100644 docs/examples/py/src/lifecycle_policy_browse.py create mode 100644 docs/examples/py/src/lifecycle_policy_create.py create mode 100644 docs/examples/py/src/lifecycle_policy_mode.py create mode 100644 docs/examples/py/src/lifecycle_policy_remove.py diff --git a/docs/examples/py/src/lifecycle_policy_browse.py b/docs/examples/py/src/lifecycle_policy_browse.py new file mode 100644 index 00000000..3d16dbad --- /dev/null +++ b/docs/examples/py/src/lifecycle_policy_browse.py @@ -0,0 +1,19 @@ +import asyncio + +from reduct import Client + + +async def main(): + async with Client("http://127.0.0.1:8383", api_token="my-token") as client: + for lifecycle in await client.get_lifecycles(): + print("Lifecycle:", lifecycle.name) + print("Mode:", lifecycle.mode) + print("Running:", lifecycle.is_running) + print("Provisioned:", lifecycle.is_provisioned) + + details = await client.get_lifecycle_detail("my-lifecycle") + print("Lifecycle:", details.info.name) + print("Settings:", details.settings) + + +asyncio.run(main()) diff --git a/docs/examples/py/src/lifecycle_policy_create.py b/docs/examples/py/src/lifecycle_policy_create.py new file mode 100644 index 00000000..a0e8d610 --- /dev/null +++ b/docs/examples/py/src/lifecycle_policy_create.py @@ -0,0 +1,21 @@ +import asyncio + +from reduct import Client, LifecycleSettings, LifecycleType + + +async def main(): + async with Client("http://127.0.0.1:8383", api_token="my-token") as client: + await client.create_bucket("my-bucket", exist_ok=True) + + settings = LifecycleSettings( + type=LifecycleType.DELETE, + bucket="my-bucket", + entries=["py-example"], + max_age="30d", + interval="1h", + when={"&anomaly": {"$eq": 1}}, + ) + await client.create_lifecycle("my-lifecycle", settings) + + +asyncio.run(main()) diff --git a/docs/examples/py/src/lifecycle_policy_mode.py b/docs/examples/py/src/lifecycle_policy_mode.py new file mode 100644 index 00000000..00a19c22 --- /dev/null +++ b/docs/examples/py/src/lifecycle_policy_mode.py @@ -0,0 +1,13 @@ +import asyncio + +from reduct import Client, LifecycleMode + + +async def main(): + async with Client("http://127.0.0.1:8383", api_token="my-token") as client: + await client.set_lifecycle_mode("my-lifecycle", LifecycleMode.DRY_RUN) + await client.set_lifecycle_mode("my-lifecycle", LifecycleMode.DISABLED) + await client.set_lifecycle_mode("my-lifecycle", LifecycleMode.ENABLED) + + +asyncio.run(main()) diff --git a/docs/examples/py/src/lifecycle_policy_remove.py b/docs/examples/py/src/lifecycle_policy_remove.py new file mode 100644 index 00000000..19dd41a2 --- /dev/null +++ b/docs/examples/py/src/lifecycle_policy_remove.py @@ -0,0 +1,11 @@ +import asyncio + +from reduct import Client + + +async def main(): + async with Client("http://127.0.0.1:8383", api_token="my-token") as client: + await client.delete_lifecycle("lifecycle-to-remove") + + +asyncio.run(main()) From 60805e5325a5ae59a6a584f2f71308e4a94ff186 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:34:15 +0200 Subject: [PATCH 10/14] add rust example --- .../rs/examples/lifecycle_policy_browse.rs | 22 +++++++++++++++ .../rs/examples/lifecycle_policy_create.rs | 28 +++++++++++++++++++ .../rs/examples/lifecycle_policy_mode.rs | 21 ++++++++++++++ .../rs/examples/lifecycle_policy_remove.rs | 12 ++++++++ 4 files changed, 83 insertions(+) create mode 100644 docs/examples/rs/examples/lifecycle_policy_browse.rs create mode 100644 docs/examples/rs/examples/lifecycle_policy_create.rs create mode 100644 docs/examples/rs/examples/lifecycle_policy_mode.rs create mode 100644 docs/examples/rs/examples/lifecycle_policy_remove.rs diff --git a/docs/examples/rs/examples/lifecycle_policy_browse.rs b/docs/examples/rs/examples/lifecycle_policy_browse.rs new file mode 100644 index 00000000..28884ec1 --- /dev/null +++ b/docs/examples/rs/examples/lifecycle_policy_browse.rs @@ -0,0 +1,22 @@ +use reduct_rs::{ReductClient, ReductError}; + +#[tokio::main] +async fn main() -> Result<(), ReductError> { + let client = ReductClient::builder() + .url("http://127.0.0.1:8383") + .api_token("my-token") + .build(); + + for lifecycle in client.list_lifecycles().await? { + println!("Lifecycle: {}", lifecycle.name); + println!("Mode: {:?}", lifecycle.mode); + println!("Running: {}", lifecycle.is_running); + println!("Provisioned: {}", lifecycle.is_provisioned); + } + + let detail = client.get_lifecycle("my-lifecycle").await?; + println!("Lifecycle: {}", detail.info.name); + println!("Settings: {:?}", detail.settings); + + Ok(()) +} diff --git a/docs/examples/rs/examples/lifecycle_policy_create.rs b/docs/examples/rs/examples/lifecycle_policy_create.rs new file mode 100644 index 00000000..f09881cb --- /dev/null +++ b/docs/examples/rs/examples/lifecycle_policy_create.rs @@ -0,0 +1,28 @@ +use reduct_rs::{condition, LifecycleType, ReductClient, ReductError}; + +#[tokio::main] +async fn main() -> Result<(), ReductError> { + let client = ReductClient::builder() + .url("http://127.0.0.1:8383") + .api_token("my-token") + .build(); + + let _ = client + .create_bucket("my-bucket") + .exist_ok(true) + .send() + .await?; + + client + .create_lifecycle("my-lifecycle") + .lifecycle_type(LifecycleType::Delete) + .bucket("my-bucket") + .entries(vec!["rs-example".to_string()]) + .max_age("30d") + .interval("1h") + .when(condition!({ "&anomaly": { "$eq": 1 } })) + .send() + .await?; + + Ok(()) +} diff --git a/docs/examples/rs/examples/lifecycle_policy_mode.rs b/docs/examples/rs/examples/lifecycle_policy_mode.rs new file mode 100644 index 00000000..df2e0572 --- /dev/null +++ b/docs/examples/rs/examples/lifecycle_policy_mode.rs @@ -0,0 +1,21 @@ +use reduct_rs::{LifecycleMode, ReductClient, ReductError}; + +#[tokio::main] +async fn main() -> Result<(), ReductError> { + let client = ReductClient::builder() + .url("http://127.0.0.1:8383") + .api_token("my-token") + .build(); + + client + .set_lifecycle_mode("my-lifecycle", LifecycleMode::DryRun) + .await?; + client + .set_lifecycle_mode("my-lifecycle", LifecycleMode::Disabled) + .await?; + client + .set_lifecycle_mode("my-lifecycle", LifecycleMode::Enabled) + .await?; + + Ok(()) +} diff --git a/docs/examples/rs/examples/lifecycle_policy_remove.rs b/docs/examples/rs/examples/lifecycle_policy_remove.rs new file mode 100644 index 00000000..f2defe4b --- /dev/null +++ b/docs/examples/rs/examples/lifecycle_policy_remove.rs @@ -0,0 +1,12 @@ +use reduct_rs::{ReductClient, ReductError}; + +#[tokio::main] +async fn main() -> Result<(), ReductError> { + let client = ReductClient::builder() + .url("http://127.0.0.1:8383") + .api_token("my-token") + .build(); + + client.delete_lifecycle("lifecycle-to-remove").await?; + Ok(()) +} From b35347a8021de2af79891c5e51c69c9f42e7654c Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:35:03 +0200 Subject: [PATCH 11/14] formatting --- docs/examples/provisioning/lifecycle_create.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/examples/provisioning/lifecycle_create.yml b/docs/examples/provisioning/lifecycle_create.yml index f6300fb4..cb98d054 100644 --- a/docs/examples/provisioning/lifecycle_create.yml +++ b/docs/examples/provisioning/lifecycle_create.yml @@ -19,4 +19,4 @@ services: RS_LIFECYCLE_1_WHEN: | { "&sensor_type": { "$eq": "temperature" } - } \ No newline at end of file + } From 85e042b745249204fb5d604d4b93148e960cf5b3 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:48:25 +0200 Subject: [PATCH 12/14] add examples to guide --- docs/guides/lifecycle-policies.mdx | 206 ++++++++++++++++++++++++++--- 1 file changed, 190 insertions(+), 16 deletions(-) diff --git a/docs/guides/lifecycle-policies.mdx b/docs/guides/lifecycle-policies.mdx index 6ad021cf..30ab6738 100644 --- a/docs/guides/lifecycle-policies.mdx +++ b/docs/guides/lifecycle-policies.mdx @@ -4,6 +4,8 @@ description: Complete guide to managing lifecycle policies in ReductStore --- import CodeBlock from "@theme/CodeBlock"; +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; import lifecycleCreate from "!!raw-loader!@site/docs/examples/provisioning/lifecycle_create.yml"; @@ -27,8 +29,8 @@ Policies are stored on disk and remain active after restarts. However, read-only Currently, ReductStore supports one action type for lifecycle policies: -| Type | Description | -|---------|--------------------------------------------------| +| Type | Description | +| -------- | ---------------------------------------------------- | | `delete` | Removes records older than `max_age` from the bucket | More action types may be added in future releases. @@ -37,15 +39,15 @@ More action types may be added in future releases. You can configure lifecycle policies using the following settings: -| Setting | Description | Required | Default | -|-----------|-------------------------------------------------------------------------------------------------|----------|----------| -| `type` | Action type (e.g., `delete`) | No | `delete` | -| `bucket` | Target bucket name | Yes | - | -| `entries` | List of entries to scope the policy (wildcard `*` supported) | No | - | -| `max_age` | Maximum age of records before action is applied (e.g., `30d`, `1h`, `5m`) | Yes | - | -| `interval`| Policy execution interval (e.g., `3600s`, `10m`) | No | `3600s` | -| `when` | JSON condition to filter records (see **[Conditional Query Reference](/docs/conditional-query/index.mdx)**) | No | - | -| `mode` | Policy mode: `enabled` (default) or `disabled` | No | `enabled`| +| Setting | Description | Required | Default | +| ---------- | ----------------------------------------------------------------------------------------------------------- | -------- | --------- | +| `type` | Action type (e.g., `delete`) | No | `delete` | +| `bucket` | Target bucket name | Yes | - | +| `entries` | List of entries to scope the policy (wildcard `*` supported) | No | - | +| `max_age` | Maximum age of records before action is applied (e.g., `30d`, `1h`, `5m`) | Yes | - | +| `interval` | Policy execution interval (e.g., `3600s`, `10m`) | No | `3600s` | +| `when` | JSON condition to filter records (see **[Conditional Query Reference](/docs/conditional-query/index.mdx)**) | No | - | +| `mode` | Policy mode: `enabled` (default), `dry_run`, or `disabled` | No | `enabled` | ## Conditional Policies @@ -62,14 +64,186 @@ Imagine you store telemetry data from temperature sensors in a bucket called `te {lifecycleCreate} -## Managing Policies - -Currently, lifecycle policies can only be provisioned using environment variables. They cannot be updated or removed via the API. +## Managing Lifecycle Policies + +Here you will find examples of how to create, list, retrieve, update modes, and delete lifecycle policies using the ReductStore SDKs, REST API, **[CLI](../glossary#cli)** and **[Web Console](../glossary#web-console)**. + +All examples are written for a local ReductStore instance available at **`http://127.0.0.1:8383`** with API token `my-token`. + +For more information on setting up a local ReductStore instance, see the **[Getting Started](../getting-started/index.mdx)** guide. + +### Creating a Lifecycle Policy + +To create a lifecycle policy, you must provide at least the target bucket and `max_age`. The examples below also include optional filters (`entries` and `when`) and a custom `interval`. + +import CreateLifecycleCli from "!!raw-loader!../examples/cli/lifecycle_policy_create.sh"; +import CreateLifecyclePy from "!!raw-loader!../examples/py/src/lifecycle_policy_create.py"; +import CreateLifecycleJs from "!!raw-loader!../examples/js/src/lifecycle_policy_create.mjs"; +import CreateLifecycleGo from "!!raw-loader!../examples/go/src/lifecycle_policy_create.go"; +import CreateLifecycleRs from "!!raw-loader!../examples/rs/examples/lifecycle_policy_create.rs"; +import CreateLifecycleCpp from "!!raw-loader!../examples/cpp/src/lifecycle_policy_create.cc"; +import CreateLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_create.sh"; + + + + {CreateLifecycleCli} + + + Steps to create a lifecycle policy using the Web Console: + 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. + 2. Enter the API token if authorization is enabled. + 3. Click **"Lifecycles"** in the left sidebar. + 4. Click the plus icon in the top-right corner. + 5. Fill in the lifecycle name, bucket, `max_age`, optional `interval`, and optional filters (`entries` and `when`). + 6. Click **"Create Lifecycle"**. + + + {CreateLifecyclePy} + + + {CreateLifecycleJs} + + + {CreateLifecycleGo} + + + {CreateLifecycleRs} + + + {CreateLifecycleCpp} + + + {CreateLifecycleCurl} + + + +### Browsing Lifecycle Policies + +You can list all lifecycle policies and inspect full settings/details of a specific policy. + +import BrowseLifecycleCli from "!!raw-loader!../examples/cli/lifecycle_policy_browse.sh"; +import BrowseLifecyclePy from "!!raw-loader!../examples/py/src/lifecycle_policy_browse.py"; +import BrowseLifecycleJs from "!!raw-loader!../examples/js/src/lifecycle_policy_browse.mjs"; +import BrowseLifecycleGo from "!!raw-loader!../examples/go/src/lifecycle_policy_browse.go"; +import BrowseLifecycleRs from "!!raw-loader!../examples/rs/examples/lifecycle_policy_browse.rs"; +import BrowseLifecycleCpp from "!!raw-loader!../examples/cpp/src/lifecycle_policy_browse.cc"; +import BrowseLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_browse.sh"; + + + + {BrowseLifecycleCli} + + + Steps to browse lifecycle policies in the Web Console: + 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. + 2. Enter the API token if authorization is enabled. + 3. Click **"Lifecycles"** in the left sidebar. + 4. Open any lifecycle policy in the list to inspect settings and status. + + + {BrowseLifecyclePy} + + + {BrowseLifecycleJs} + + + {BrowseLifecycleGo} + + + {BrowseLifecycleRs} + + + {BrowseLifecycleCpp} + + + {BrowseLifecycleCurl} + + + +### Lifecycle Modes + +Lifecycle policies can be switched between modes without recreating the policy. + +import UpdateLifecycleModeCli from "!!raw-loader!../examples/cli/lifecycle_policy_mode.sh"; +import UpdateLifecycleModePy from "!!raw-loader!../examples/py/src/lifecycle_policy_mode.py"; +import UpdateLifecycleModeJs from "!!raw-loader!../examples/js/src/lifecycle_policy_mode.mjs"; +import UpdateLifecycleModeGo from "!!raw-loader!../examples/go/src/lifecycle_policy_mode.go"; +import UpdateLifecycleModeRs from "!!raw-loader!../examples/rs/examples/lifecycle_policy_mode.rs"; +import UpdateLifecycleModeCpp from "!!raw-loader!../examples/cpp/src/lifecycle_policy_mode.cc"; +import UpdateLifecycleModeCurl from "!!raw-loader!../examples/curl/lifecycle_policy_mode.sh"; + + + + {UpdateLifecycleModeCli} + + + {UpdateLifecycleModePy} + + + {UpdateLifecycleModeJs} + + + {UpdateLifecycleModeGo} + + + {UpdateLifecycleModeRs} + + + {UpdateLifecycleModeCpp} + + + {UpdateLifecycleModeCurl} + + + +### Removing a Lifecycle Policy + +You can remove a lifecycle policy when it is no longer needed. :::info -Provisioned policies cannot be modified or deleted through the API. To make changes, update the environment variables and restart the ReductStore instance. +Provisioned lifecycle policies cannot be modified or deleted through the API. To change or remove them, update environment variables and restart ReductStore. ::: +import RemoveLifecycleCli from "!!raw-loader!../examples/cli/lifecycle_policy_remove.sh"; +import RemoveLifecyclePy from "!!raw-loader!../examples/py/src/lifecycle_policy_remove.py"; +import RemoveLifecycleJs from "!!raw-loader!../examples/js/src/lifecycle_policy_remove.mjs"; +import RemoveLifecycleGo from "!!raw-loader!../examples/go/src/lifecycle_policy_remove.go"; +import RemoveLifecycleRs from "!!raw-loader!../examples/rs/examples/lifecycle_policy_remove.rs"; +import RemoveLifecycleCpp from "!!raw-loader!../examples/cpp/src/lifecycle_policy_remove.cc"; +import RemoveLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_remove.sh"; + + + + {RemoveLifecycleCli} + + + Steps to remove a lifecycle policy using the Web Console: + 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. + 2. Enter the API token if authorization is enabled. + 3. Click **"Lifecycles"** in the left sidebar. + 4. Open the lifecycle policy details. + 5. Click the trash icon in the bottom-right corner and confirm by typing the policy name. + + + {RemoveLifecyclePy} + + + {RemoveLifecycleJs} + + + {RemoveLifecycleGo} + + + {RemoveLifecycleRs} + + + {RemoveLifecycleCpp} + + + {RemoveLifecycleCurl} + + + ## Audit Logs Every lifecycle run generates a `lifecycle_run` event in the `$audit` bucket. The event includes: @@ -77,4 +251,4 @@ Every lifecycle run generates a `lifecycle_run` event in the `$audit` bucket. Th - Policy name and action type - Target bucket and duration of the run - Number of records processed -- Error details (if any) \ No newline at end of file +- Error details (if any) From e48db189a0807dad820fad0f24e6b780069fdd56 Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Mon, 18 May 2026 18:52:55 +0200 Subject: [PATCH 13/14] formatting --- docs/guides/lifecycle-policies.mdx | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/docs/guides/lifecycle-policies.mdx b/docs/guides/lifecycle-policies.mdx index 30ab6738..367dbbe9 100644 --- a/docs/guides/lifecycle-policies.mdx +++ b/docs/guides/lifecycle-policies.mdx @@ -89,6 +89,7 @@ import CreateLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_ {CreateLifecycleCli} + Steps to create a lifecycle policy using the Web Console: 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. 2. Enter the API token if authorization is enabled. @@ -96,6 +97,7 @@ import CreateLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_ 4. Click the plus icon in the top-right corner. 5. Fill in the lifecycle name, bucket, `max_age`, optional `interval`, and optional filters (`entries` and `when`). 6. Click **"Create Lifecycle"**. + {CreateLifecyclePy} @@ -134,11 +136,13 @@ import BrowseLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_ {BrowseLifecycleCli} + Steps to browse lifecycle policies in the Web Console: 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. 2. Enter the API token if authorization is enabled. 3. Click **"Lifecycles"** in the left sidebar. 4. Open any lifecycle policy in the list to inspect settings and status. + {BrowseLifecyclePy} @@ -176,6 +180,15 @@ import UpdateLifecycleModeCurl from "!!raw-loader!../examples/curl/lifecycle_pol {UpdateLifecycleModeCli} + + + Steps to update lifecycle policy mode using the Web Console: + 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. + 2. Enter the API token if authorization is enabled. + 3. Click **"Lifecycles"** in the left sidebar. + 4. Update the policy mode by clicking the dropdown button next to the policy name and selecting the desired mode (`enabled`, `dry_run`, or `disabled`). + + {UpdateLifecycleModePy} @@ -217,12 +230,14 @@ import RemoveLifecycleCurl from "!!raw-loader!../examples/curl/lifecycle_policy_ {RemoveLifecycleCli} - Steps to remove a lifecycle policy using the Web Console: + + Steps to remove a lifecycle policy using the Web Console: 1. Open the Web Console at `http://127.0.0.1:8383` in your browser. 2. Enter the API token if authorization is enabled. 3. Click **"Lifecycles"** in the left sidebar. 4. Open the lifecycle policy details. 5. Click the trash icon in the bottom-right corner and confirm by typing the policy name. + {RemoveLifecyclePy} From c7f32aa8f22644562a5abfc5da41af0a33038cbf Mon Sep 17 00:00:00 2001 From: Anthony <26444489+AnthonyCvn@users.noreply.github.com> Date: Tue, 19 May 2026 18:55:23 +0200 Subject: [PATCH 14/14] update generated doc --- docs/cli/attachment/index.mdx | 8 +- docs/cli/bucket/index.mdx | 10 +- docs/cli/cp/index.mdx | 4 +- docs/cli/index.mdx | 20 ++-- docs/cli/replica/index.mdx | 18 ++-- docs/cli/rm/index.mdx | 2 +- docs/cli/token/index.mdx | 8 +- docs/reduct-bridge/dev/index.mdx | 25 +++++ docs/reduct-bridge/index.mdx | 61 ++++++++++- docs/reduct-bridge/input/metrics/index.mdx | 6 -- docs/reduct-bridge/input/mqtt/index.mdx | 92 ++++++++++++---- docs/reduct-bridge/input/ros1/index.mdx | 6 -- docs/reduct-bridge/input/ros2/index.mdx | 7 -- docs/reduct-bridge/remote/reduct/index.mdx | 14 +++ docs/sdk/py/bucket/index.mdx | 4 +- docs/sdk/py/client/index.mdx | 117 +++++++++++++++++++++ 16 files changed, 321 insertions(+), 81 deletions(-) create mode 100644 docs/reduct-bridge/dev/index.mdx diff --git a/docs/cli/attachment/index.mdx b/docs/cli/attachment/index.mdx index 961c65e3..fa186796 100644 --- a/docs/cli/attachment/index.mdx +++ b/docs/cli/attachment/index.mdx @@ -49,7 +49,7 @@ List attachment keys of an entry #### Arguments -- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) +- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) #### Options @@ -83,7 +83,7 @@ Read attachments of an entry #### Arguments -- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) +- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) - `[KEY]...`: Attachment keys to read #### Options @@ -119,7 +119,7 @@ Remove attachments from an entry #### Arguments -- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) +- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) - `[KEY]...`: Attachment keys to remove #### Options @@ -157,7 +157,7 @@ Write an attachment to an entry #### Arguments -- ``: Path to an entry (e.g. SERVER\_ALIAS/BUCKET/ENTRY\_NAME or http://token@localhost:8383/BUCKET/ENTRY\_NAME) +- ``: Path to an entry (e.g. SERVER_ALIAS/BUCKET/ENTRY_NAME or http://token@localhost:8383/BUCKET/ENTRY_NAME) - ``: Attachment key - ``: Attachment value in JSON format diff --git a/docs/cli/bucket/index.mdx b/docs/cli/bucket/index.mdx index ffec1b3a..82c1383b 100644 --- a/docs/cli/bucket/index.mdx +++ b/docs/cli/bucket/index.mdx @@ -87,7 +87,7 @@ Show bucket information #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -123,7 +123,7 @@ Create a bucket #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -165,7 +165,7 @@ Update bucket settings #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -207,7 +207,7 @@ Rename a bucket or an entry #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) - ``: New name for the bucket or entry #### Options @@ -245,7 +245,7 @@ Remove a bucket #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options diff --git a/docs/cli/cp/index.mdx b/docs/cli/cp/index.mdx index 627c4418..dc6d4575 100644 --- a/docs/cli/cp/index.mdx +++ b/docs/cli/cp/index.mdx @@ -13,8 +13,8 @@ Copy data between instances or between an instance and the local filesystem ## Arguments -- ``: Source bucket or folder (e.g. SERVER\_ALIAS/BUCKET, SERVER\_ALIAS/\*, SERVER\_ALIAS/test-\*, or ./folder) -- ``: Destination bucket, instance, or folder (e.g. SERVER\_ALIAS/BUCKET, SERVER\_ALIAS, or ./folder) +- ``: Source bucket or folder (e.g. SERVER_ALIAS/BUCKET, SERVER_ALIAS/\*, SERVER_ALIAS/test-\*, or ./folder) +- ``: Destination bucket, instance, or folder (e.g. SERVER_ALIAS/BUCKET, SERVER_ALIAS, or ./folder) ## Options diff --git a/docs/cli/index.mdx b/docs/cli/index.mdx index 4f5da300..9afa5a27 100644 --- a/docs/cli/index.mdx +++ b/docs/cli/index.mdx @@ -12,17 +12,16 @@ sidebar_position: 0 [![GitHub all releases](https://img.shields.io/github/downloads/reductstore/reduct-cli/total)](https://github.com/reductstore/reduct-cli/releases/latest) [![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/reductstore/reduct-cli/ci.yml?branch=main)](https://github.com/reductstore/reduct-cli/actions) - The ReductStore CLI is a command line client for [ReductStore](https://www.reduct.store), a time series database for blob data. ## Features -* Support for ReductStore API v1.18 -* Easy management of buckets, tokens and replications -* Ability to check the status of a storage engine -* Aliases for storing server credentials -* Export and mirror data +- Support for ReductStore API v1.18 +- Easy management of buckets, tokens and replications +- Ability to check the status of a storage engine +- Aliases for storing server credentials +- Export and mirror data ## Installing @@ -75,14 +74,13 @@ reduct-cli cp play/* backup For more examples, see the [Guides](https://www.reduct.store/docs/guides) section in the ReductStore documentation. - ## Links -* [Project Homepage](https://www.reduct.store) -* [ReductStore Client SDK for Rust](https://github.com/reductstore/reduct-rs) -* [ReductStore](https://github.com/reductstore/reductstore) +- [Project Homepage](https://www.reduct.store) +- [ReductStore Client SDK for Rust](https://github.com/reductstore/reduct-rs) +- [ReductStore](https://github.com/reductstore/reductstore) -import DocCardList from '@theme/DocCardList'; +import DocCardList from "@theme/DocCardList"; ## Commands diff --git a/docs/cli/replica/index.mdx b/docs/cli/replica/index.mdx index d29bc041..7704da52 100644 --- a/docs/cli/replica/index.mdx +++ b/docs/cli/replica/index.mdx @@ -53,9 +53,9 @@ Create a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) - ``: Source bucket on the replicated instance -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -103,8 +103,8 @@ Update a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -189,7 +189,7 @@ Show details about a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -223,7 +223,7 @@ Enable a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -257,7 +257,7 @@ Disable a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -291,7 +291,7 @@ Pause a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -325,7 +325,7 @@ Remove a replication task #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options diff --git a/docs/cli/rm/index.mdx b/docs/cli/rm/index.mdx index 56c2d52b..37cae79e 100644 --- a/docs/cli/rm/index.mdx +++ b/docs/cli/rm/index.mdx @@ -17,7 +17,7 @@ Remove data from a bucket ## Options -- `-b, --start `: Remove records with timestamps older than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will start from the first record in an entry. +- `-b, --start `: Remove records with timestamps older than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will start from the first record in an entry. - `-i, --ignore-ssl`: Ignore SSL certificate verification - `--ca-cert `: Path to a custom CA certificate bundle/file - `-e, --stop `: Remove records with timestamps newer than this time point in ISO format or Unix timestamp in microseconds. If not specified, the export will end at the last record in an entry. diff --git a/docs/cli/token/index.mdx b/docs/cli/token/index.mdx index 242cb031..23f3be3b 100644 --- a/docs/cli/token/index.mdx +++ b/docs/cli/token/index.mdx @@ -50,7 +50,7 @@ Create an access token #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -134,7 +134,7 @@ Rotate an access token value #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -168,7 +168,7 @@ Show token details #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options @@ -202,7 +202,7 @@ Remove an access token #### Arguments -- ``: Path to a resource to use (e.g. SERVER\_ALIAS/<RESOURCE\_NAME> or http://token@localhost:8383/RESOURCE\_NAME) +- ``: Path to a resource to use (e.g. SERVER_ALIAS/<RESOURCE_NAME> or http://token@localhost:8383/RESOURCE_NAME) #### Options diff --git a/docs/reduct-bridge/dev/index.mdx b/docs/reduct-bridge/dev/index.mdx new file mode 100644 index 00000000..af128d8d --- /dev/null +++ b/docs/reduct-bridge/dev/index.mdx @@ -0,0 +1,25 @@ +--- +title: "Dev Environment" +description: "Documentation for Dev Environment in ReductBridge." +--- +# Dev Environment + +## Start + +```sh +cargo build --features mqtt +cd dev && docker compose up -d +``` + +## Watch (auto-restart on rebuild) + +```sh +cargo watch -x 'build --features mqtt' -s 'docker compose -f dev/docker-compose.yml restart bridge' +``` + +## Regenerate proto files + +```sh +protoc --proto_path=dev/mqtt --include_imports --descriptor_set_out=dev/mqtt/factory.desc factory.proto +protoc --proto_path=dev/mqtt --python_out=dev/mqtt factory.proto +``` diff --git a/docs/reduct-bridge/index.mdx b/docs/reduct-bridge/index.mdx index f64d696a..d106642a 100644 --- a/docs/reduct-bridge/index.mdx +++ b/docs/reduct-bridge/index.mdx @@ -24,8 +24,17 @@ Supported input types include: - **[Metrics](./input/metrics/index.mdx)** - collect host CPU, memory, and disk metrics as JSON records. - **[MQTT](./input/mqtt/index.mdx)** - subscribe to MQTT v3/v5 topics over `mqtt://` or `mqtts://` and store raw payloads with optional payload/property label mapping. - **[Shell](./input/shell/index.mdx)** - run shell commands on a fixed interval and store output lines as records. -- **[ROS1](./input/ros1/index.mdx)** - subscribe to ROS1 topics and store ROS messages as records. -- **[ROS2](./input/ros2/index.mdx)** - subscribe to ROS2 topics and store serialized CDR payloads as records. +- **[ROS1](./input/ros1/index.mdx)** - subscribe to ROS1 topics, store ROS messages, and extract labels from message fields. +- **[ROS2](./input/ros2/index.mdx)** - subscribe to ROS2 topics, store serialized CDR payloads, and extract labels from decoded message fields. + +## Formats + +ReductBridge supports different payload formats. +Support means ReductBridge can parse payloads, extract labels, and, when schema information is available, store that schema in ReductStore. + +- JSON: find values by field path (example: **[examples/mqtt_config.toml](https://github.com/reductstore/reduct-bridge/blob/main/examples/mqtt_config.toml)**). +- Protobuf: find values by field path (with schema) or by field ID/type (example: **[examples/mqtt_protobuf_config.toml](https://github.com/reductstore/reduct-bridge/blob/main/examples/mqtt_protobuf_config.toml)**). +- ROS formats: decode ROS message payloads for labels and store the payloads as records (example: **[examples/ros_config.toml](https://github.com/reductstore/reduct-bridge/blob/main/examples/ros_config.toml)**). ## Remotes @@ -65,6 +74,50 @@ labels = [ ## Installation +ReductBridge is published in build types named after Cargo feature bundles: `ros1`, `ros2`, and `iot`. +Choose the build type for the input family you need. + +### Build Types + +Published packages and Docker images are split into these build types so each artifact only includes the dependencies needed for its input family. + +| Build type | Description | Included inputs | Published artifact names | +| --- | --- | --- | --- | +| `ros1` | ROS1 robotics bundle. | **[ROS1](./input/ros1/index.mdx)**, **[Shell](./input/shell/index.mdx)**, **[Metrics](./input/metrics/index.mdx)** | Snap: `reduct-bridge-ros1`; Docker build type: `ros1`; binary: `bridge-ros1.x86_64-unknown-linux-gnu.tar.gz` | +| `ros2` | ROS2 robotics bundle. | **[ROS2](./input/ros2/index.mdx)**, **[Shell](./input/shell/index.mdx)**, **[Metrics](./input/metrics/index.mdx)** | Snap: `reduct-bridge-ros2`; Docker build types: `ros2-jazzy`, `ros2-humble`; binaries: `bridge-ros2-jazzy.x86_64-unknown-linux-gnu.tar.gz`, `bridge-ros2-humble.x86_64-unknown-linux-gnu.tar.gz` | +| `iot` | MQTT/IIoT bundle. | **[MQTT](./input/mqtt/index.mdx)**, **[Shell](./input/shell/index.mdx)**, **[Metrics](./input/metrics/index.mdx)** | Snap: `reduct-bridge-iot`; Docker build type: `iot`; binary: `bridge-iot.x86_64-unknown-linux-gnu.tar.gz` | + +Note: ROS2 binary and Docker artifacts are published per ROS distribution: `ros2-jazzy` and `ros2-humble`. The ROS2 snap is published as `reduct-bridge-ros2` and currently uses the Jazzy build. + +Input names in configuration use their input table names, for example `[inputs.ros.*]`, `[inputs.ros2.*]`, `[inputs.mqtt.*]`, `[inputs.shell.*]`, and `[inputs.metrics.*]`. + +### Docker + +Docker images are published as `reduct/bridge:`, where `` combines a release channel or version with the build type. +For ROS2 Docker images, use the ROS distribution-specific build type: `ros2-jazzy` or `ros2-humble`. + +```bash +docker pull reduct/bridge:main- # development builds from main +docker pull reduct/bridge:latest- # stable builds +docker pull reduct/bridge:v- # release builds +``` + +For example: + +```bash +docker pull reduct/bridge:main-iot +docker pull reduct/bridge:main-ros2-jazzy +docker pull reduct/bridge:main-ros2-humble +``` + +Run the container with a mounted config file: + +```bash +docker run --rm \ + -v "$PWD/config.toml:/etc/reduct-bridge/config.toml:ro" \ + reduct/bridge:main-iot /etc/reduct-bridge/config.toml +``` + ### Snap (Ubuntu 22.04+) ```bash @@ -100,8 +153,8 @@ To build additional inputs explicitly from source: ```bash cargo build --no-default-features --features ros1 -cargo build --no-default-features --features shell,metrics,iot -cargo build --no-default-features --features all-inputs +cargo build --no-default-features --features ros2 +cargo build --no-default-features --features iot ``` ## Usage diff --git a/docs/reduct-bridge/input/metrics/index.mdx b/docs/reduct-bridge/input/metrics/index.mdx index e990330f..a69bb30b 100644 --- a/docs/reduct-bridge/input/metrics/index.mdx +++ b/docs/reduct-bridge/input/metrics/index.mdx @@ -98,12 +98,6 @@ Build only metrics input support: cargo build --no-default-features --features metrics ``` -Build all inputs in one command: - -```bash -cargo build --no-default-features --features all-inputs -``` - ## Runtime Notes - If `metrics` is empty or omitted, the input collects all supported metrics. diff --git a/docs/reduct-bridge/input/mqtt/index.mdx b/docs/reduct-bridge/input/mqtt/index.mdx index 0afbc756..5e3f0639 100644 --- a/docs/reduct-bridge/input/mqtt/index.mdx +++ b/docs/reduct-bridge/input/mqtt/index.mdx @@ -7,43 +7,64 @@ description: "Documentation for MQTT input in ReductBridge." The MQTT input subscribes to one or more MQTT topics and forwards messages into a pipeline. Both `mqtt://` and `mqtts://` brokers are supported. -MQTT label rules follow the same ordered model as the ROS inputs: +Labels are applied with the following rules: -- static labels are applied first -- payload field labels are applied after static labels and can override them -- MQTT v5 property labels are also applied in order and can override earlier labels +1. Labels are processed in the order they appear in `labels` in TOML. +2. For conflicts, later rules override earlier rules for the same label key. +3. This ordering behavior applies to all rule types: `static`, `field`, and `property`. +4. Payload field labels (`field = "..."`) work with JSON and protobuf payloads. +5. MQTT v5 property labels: + - `property = "content_type"` reads the built-in MQTT v5 `content_type` property. + - `property = ""` reads the MQTT v5 user property named ``. -For MQTT v5 property labels: +## Protobuf support -- `property = "content_type"` reads the built-in MQTT v5 `content_type` property -- any other `property = ""` reads the MQTT v5 user property named `` +MQTT input supports protobuf payloads and can map protobuf fields to labels. +Choose one of these modes. + +1. Schema mode (recommended) + +- `schema_path` must point to a protobuf descriptor set file generated by `protoc`. + Example command: `protoc --include_imports --descriptor_set_out=schema.desc schema.proto`. +- `schema_name` is the protobuf message type to decode from the payload, e.g. `my.package.Message`. +- Use `{ field = "...", label = "..." }` to extract labels by field path. +- The schema is emitted as attachment `$schema` in JSON with fields: + `encoding` (payload encoding, `protobuf`), + `topic` (MQTT publish topic that produced the record), + `schema_name` (same as configured), and + `schema` (the configured schema file content, base64-encoded). + +Use this mode when you want self-describing data and easier downstream inspection. + +2. No-schema mode + +- Omit both `schema_path` and `schema_name`. +- Use `{ field_id = , field_type = "", label = "..." }` to extract labels from raw protobuf wire fields. + +Use this mode for lightweight setups when you only need a few known fields. ## Configuration +### Shared input settings + ```toml [inputs.mqtt.main] broker = "mqtts://broker.example.com:8883" client_id = "reduct-bridge" version = "v5" qos = 1 - username = "bridge" password = "${MQTT_PASSWORD}" - entry_prefix = "/mqtt" +``` +### JSON topic + +```toml [[inputs.mqtt.main.topics]] name = "factory/+/telemetry" entry_name = "telemetry" content_type = "application/json" -# Optional label rules (default = []): -# 1) Dynamic field label: -# { field = "device_id", label = "device" } -# 2) Static labels: -# { static = { source = "mqtt", site = "lab" } } -# 3) MQTT v5 property label: -# { property = "content_type", label = "mime" } -# { property = "tenant", label = "tenant" } # MQTT v5 user property labels = [ { field = "device_id", label = "device" }, { field = "site", label = "site" }, @@ -51,7 +72,37 @@ labels = [ { property = "content_type", label = "mime" }, { property = "tenant", label = "tenant" } ] +``` + +### Protobuf topic with schema (recommended) +```toml +[[inputs.mqtt.main.topics]] +name = "factory/electrical/+/power" +entry_name = "power" +content_type = "application/protobuf" +schema_path = "./factory.desc" +schema_name = "factory.PowerReading" +labels = [ + { field = "device_id", label = "meter_id" }, + { field = "panel", label = "panel" } +] +``` + +### Protobuf topic without schema + +```toml +[[inputs.mqtt.main.topics]] +name = "factory/electrical/+/power/raw" +content_type = "application/protobuf" +labels = [ + { field_id = 1, field_type = "string", label = "meter_id" } +] +``` + +### Static-only topic + +```toml [[inputs.mqtt.main.topics]] name = "factory/+/events" labels = [ @@ -59,8 +110,11 @@ labels = [ ] ``` -`entry_name`, `content_type`, and `labels` are configured per topic. `content_type` is used as the default record content type when an MQTT v5 publish does not provide a `content_type` property; for MQTT v3 it is used directly. -Use bare names such as `tenant`, `status`, or `id` for MQTT v5 user properties. +`entry_name`, `content_type`, and `labels` are configured per topic. `content_type` +is used as the default record content type when an MQTT v5 publish does not provide +a `content_type` property; for MQTT v3 it is used directly. Use bare names such as +`tenant`, `status`, or `id` for MQTT v5 user properties. +`schema_path` and `schema_name` must be set together. ### MQTT v3 example diff --git a/docs/reduct-bridge/input/ros1/index.mdx b/docs/reduct-bridge/input/ros1/index.mdx index a9fa79cc..a03d612c 100644 --- a/docs/reduct-bridge/input/ros1/index.mdx +++ b/docs/reduct-bridge/input/ros1/index.mdx @@ -57,12 +57,6 @@ Build only ROS1 input support: cargo build --no-default-features --features ros1 ``` -Build all inputs in one command: - -```bash -cargo build --no-default-features --features all-inputs -``` - ## Runtime Notes - Empty topic names are not allowed. diff --git a/docs/reduct-bridge/input/ros2/index.mdx b/docs/reduct-bridge/input/ros2/index.mdx index db6cae8d..4469b2f6 100644 --- a/docs/reduct-bridge/input/ros2/index.mdx +++ b/docs/reduct-bridge/input/ros2/index.mdx @@ -70,13 +70,6 @@ cargo build --no-default-features --features ros2 The ROS2 installation must include the standard interface packages that `rclrs` links against. In CI we install `ros-jazzy-example-interfaces` and `ros-jazzy-test-msgs` explicitly. -Build all inputs in one command: - -```bash -source /opt/ros/jazzy/setup.bash -cargo build --no-default-features --features all-inputs -``` - ## Runtime Notes - Empty topic names are not allowed. diff --git a/docs/reduct-bridge/remote/reduct/index.mdx b/docs/reduct-bridge/remote/reduct/index.mdx index 9cf5bf42..d72b74d8 100644 --- a/docs/reduct-bridge/remote/reduct/index.mdx +++ b/docs/reduct-bridge/remote/reduct/index.mdx @@ -37,12 +37,26 @@ batch_max_size_bytes = 8388608 # Periodic flush interval in milliseconds (default: 1000, must be > 0). batch_max_interval_ms = 1000 + +# Optional: create the bucket on startup if it does not exist. +# Omit this table to require the bucket to exist before starting reduct-bridge. +[remotes.reduct.create_bucket] +# Required when create_bucket is configured: NONE, FIFO, or HARD. +quota_type = "FIFO" + +# Required when create_bucket is configured: quota size as bytes or a unit string. +# Accepted examples: 1073741824, "1GB", "512MB", "4GiB", "1.5TiB", "500 B". +# Accepted decimal units: B, K/KB, M/MB, G/GB, T/TB, P/PB, E/EB. +# Accepted binary units: Ki/KiB, Mi/MiB, Gi/GiB, Ti/TiB, Pi/PiB, Ei/EiB. +quota_size = "1GB" ``` ## Runtime Notes - Records are buffered and flushed by count, size, or interval. - Invalid batching values (`0`) are not allowed. +- Buckets are not created automatically unless `[remotes.reduct.create_bucket]` is configured. +- Automatic bucket creation only applies when the configured bucket is missing; existing bucket settings are not changed. ## Changes diff --git a/docs/sdk/py/bucket/index.mdx b/docs/sdk/py/bucket/index.mdx index 2c697192..217586a3 100644 --- a/docs/sdk/py/bucket/index.mdx +++ b/docs/sdk/py/bucket/index.mdx @@ -675,9 +675,7 @@ multiple entries. You can also use wildcards in entry names. #### write\_attachments ```python -async def write_attachments(entry_name: str, - attachments: dict[str, dict], - content_type: str = None) +async def write_attachments(entry_name: str, attachments: dict[str, dict]) ``` Write attachments to an entry diff --git a/docs/sdk/py/client/index.mdx b/docs/sdk/py/client/index.mdx index 14657a2a..f972456c 100644 --- a/docs/sdk/py/client/index.mdx +++ b/docs/sdk/py/client/index.mdx @@ -387,4 +387,121 @@ Delete a replication - `ReductError` - if there is an HTTP error + + +#### get\_lifecycles + +```python +async def get_lifecycles() -> list[LifecycleInfo] +``` + +Get a list of lifecycle policies + +**Returns**: + +- `List[LifecycleInfo]` - List of lifecycle policies with their statuses + +**Raises**: + +- `ReductError` - if there is an HTTP error + + + +#### get\_lifecycle\_detail + +```python +async def get_lifecycle_detail(lifecycle_name: str) -> LifecycleDetailInfo +``` + +Get detailed information about a lifecycle policy + +**Arguments**: + +- `lifecycle_name` - Name of the lifecycle policy to show details + +**Returns**: + +- `LifecycleDetailInfo` - Detailed information about the lifecycle policy + +**Raises**: + +- `ReductError` - if there is an HTTP error + + + +#### create\_lifecycle + +```python +async def create_lifecycle(lifecycle_name: str, + settings: LifecycleSettings) -> None +``` + +Create a new lifecycle policy + +**Arguments**: + +- `lifecycle_name` - Name of the new lifecycle policy +- `settings` - Settings for the new lifecycle policy + +**Raises**: + +- `ReductError` - if there is an HTTP error + + + +#### update\_lifecycle + +```python +async def update_lifecycle(lifecycle_name: str, + settings: LifecycleSettings) -> None +``` + +Update an existing lifecycle policy + +**Arguments**: + +- `lifecycle_name` - Name of the lifecycle policy to update +- `settings` - New settings for the lifecycle policy + +**Raises**: + +- `ReductError` - if there is an HTTP error + + + +#### set\_lifecycle\_mode + +```python +async def set_lifecycle_mode(lifecycle_name: str, mode: LifecycleMode) -> None +``` + +Update mode for an existing lifecycle policy without overriding settings + +**Arguments**: + +- `lifecycle_name` - Name of the lifecycle policy to update +- `mode` - New lifecycle mode + +**Raises**: + +- `ReductError` - if there is an HTTP error + + + +#### delete\_lifecycle + +```python +async def delete_lifecycle(lifecycle_name: str) -> None +``` + +Delete a lifecycle policy + +**Arguments**: + +- `lifecycle_name` - Name of the lifecycle policy to delete + +**Raises**: + +- `ReductError` - if there is an HTTP error +