Skip to content

Commit

Permalink
chore: publish new package versions (#2046)
Browse files Browse the repository at this point in the history
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## @electric-sql/[email protected]

### Minor Changes

- e96928e: [BREAKING]: Move non-protocol options like table & where
to the params sub-key

    ## Context

Electric's TypeScript client is currently tightly coupled to
PostgreSQL-specific options in its `ShapeStreamOptions` interface. As
Electric plans to support multiple data sources in the future, we need
to separate protocol-level options from source-specific options.

    ## Changes

1. Created a new `PostgresParams` type to define PostgreSQL-specific
parameters:
        -   `table`: The root table for the shape
        -   `where`: Where clauses for the shape
        -   `columns`: Columns to include in the shape
        -   `replica`: Whether to send full or partial row updates
2. Moved PostgreSQL-specific options from the top-level
`ShapeStreamOptions` interface to the `params` sub-key
    3.  Updated `ParamsRecord` type to include PostgreSQL parameters
4. Updated the `ShapeStream` class to handle parameters from the
`params` object
    5.  Updated documentation to reflect the changes

    ## Migration Example

    Before:

    ```typescript
    const stream = new ShapeStream({
      url: 'http://localhost:3000/v1/shape',
      table: 'users',
      where: 'id > 100',
      columns: ['id', 'name'],
      replica: 'full',
    })
    ```

    After:

    ```typescript
    const stream = new ShapeStream({
      url: 'http://localhost:3000/v1/shape',
      params: {
        table: 'users',
        where: 'id > 100',
        columns: ['id', 'name'],
        replica: 'full',
      },
    })
    ```

### Patch Changes

-   Updated dependencies [9c50e8f]
-   Updated dependencies [af0c0bf]
-   Updated dependencies [e96928e]
    -   @electric-sql/[email protected]

## @electric-sql/[email protected]

### Minor Changes

- 9c50e8f: [BREAKING]: Remove databaseId option from ShapeStream in
favor of params option.
- e96928e: [BREAKING]: Move non-protocol options like table & where
to the params sub-key

    ## Context

Electric's TypeScript client is currently tightly coupled to
PostgreSQL-specific options in its `ShapeStreamOptions` interface. As
Electric plans to support multiple data sources in the future, we need
to separate protocol-level options from source-specific options.

    ## Changes

1. Created a new `PostgresParams` type to define PostgreSQL-specific
parameters:
        -   `table`: The root table for the shape
        -   `where`: Where clauses for the shape
        -   `columns`: Columns to include in the shape
        -   `replica`: Whether to send full or partial row updates
2. Moved PostgreSQL-specific options from the top-level
`ShapeStreamOptions` interface to the `params` sub-key
    3.  Updated `ParamsRecord` type to include PostgreSQL parameters
4. Updated the `ShapeStream` class to handle parameters from the
`params` object
    5.  Updated documentation to reflect the changes

    ## Migration Example

    Before:

    ```typescript
    const stream = new ShapeStream({
      url: 'http://localhost:3000/v1/shape',
      table: 'users',
      where: 'id > 100',
      columns: ['id', 'name'],
      replica: 'full',
    })
    ```

    After:

    ```typescript
    const stream = new ShapeStream({
      url: 'http://localhost:3000/v1/shape',
      params: {
        table: 'users',
        where: 'id > 100',
        columns: ['id', 'name'],
        replica: 'full',
      },
    })
    ```

### Patch Changes

- af0c0bf: Always use sorted query parameters in official clients to
ensure Shape URLs are cached consistently.

## @core/[email protected]

### Patch Changes

-   ea5d03f: Fix mishandling of 400s - should terminate
- af0c0bf: Always use sorted query parameters in official clients to
ensure Shape URLs are cached consistently.

## @core/[email protected]

### Patch Changes

- 3584f67: Validate that user provided offset is not bigger than the
shape's latest offset.
-   0dc844f: Remove redundant spans in open telemetry tracing.
-   a16ab24: feat: add more telemetry
-   3c24208: Clean up directories when removing shapes.
    Remove corrupted shapes from store when recovery fails.
-   4e50204: Telemetry for reporting replication lag.
- 704ac91: Include caching headers on 304 responses to prevent client
from rechecking the previously cached ones over and over again.
-   ceec2d4: Assume process is not alive if registry is not alive.
- 37b4256: Improved replication steam processing for where clauses in
the form `field = const` or `field = const AND another_condition`
- 64fe275: Restore the automatic fallback to unencrypted database
connections when SSL isn't available.
- 5b1c3e6: Resolve naming confusion between
`ELECTRIC_LOG_CHUNK_BYTES_THRESHOLD` and logging-related configuration
options. Add `ELECTRIC_` prefix to `LOG_LEVEL` to `LOG_OTP_REPORTS`
config options. Introduce a new config option named
`ELECTRIC_LOG_COLORS`.
- e815b91: Log error but don't fall over if failing to initialise
recovered shape

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and github-actions[bot] authored Dec 3, 2024
1 parent e96928e commit ab1ea51
Show file tree
Hide file tree
Showing 23 changed files with 140 additions and 125 deletions.
5 changes: 0 additions & 5 deletions .changeset/famous-bananas-report.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/few-gorillas-fetch.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/five-masks-check.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/hungry-apples-sell.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/khaki-meals-accept.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/nasty-emus-rule.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/nine-gorillas-rush.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/old-ligers-run.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/selfish-rings-mate.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/silly-shoes-appear.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/spotty-ears-build.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/stupid-weeks-look.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/sweet-timers-add.md

This file was deleted.

49 changes: 0 additions & 49 deletions .changeset/tiny-socks-drive.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/warm-brooms-approve.md

This file was deleted.

7 changes: 7 additions & 0 deletions packages/elixir-client/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @core/elixir-client

## 0.2.4

### Patch Changes

- ea5d03f: Fix mishandling of 400s - should terminate
- af0c0bf: Always use sorted query parameters in official clients to ensure Shape URLs are cached consistently.

## 0.2.3

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/elixir-client/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@core/elixir-client",
"private": true,
"version": "0.2.3",
"version": "0.2.4",
"scripts": {
"publish:hex": "mix do deps.get, hex.publish --yes || true"
}
Expand Down
57 changes: 57 additions & 0 deletions packages/react-hooks/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,62 @@
# @electric-sql/react

## 0.6.0

### Minor Changes

- e96928e: [BREAKING]: Move non-protocol options like table & where to the params sub-key

## Context

Electric's TypeScript client is currently tightly coupled to PostgreSQL-specific options in its `ShapeStreamOptions` interface. As Electric plans to support multiple data sources in the future, we need to separate protocol-level options from source-specific options.

## Changes

1. Created a new `PostgresParams` type to define PostgreSQL-specific parameters:
- `table`: The root table for the shape
- `where`: Where clauses for the shape
- `columns`: Columns to include in the shape
- `replica`: Whether to send full or partial row updates
2. Moved PostgreSQL-specific options from the top-level `ShapeStreamOptions` interface to the `params` sub-key
3. Updated `ParamsRecord` type to include PostgreSQL parameters
4. Updated the `ShapeStream` class to handle parameters from the `params` object
5. Updated documentation to reflect the changes

## Migration Example

Before:

```typescript
const stream = new ShapeStream({
url: 'http://localhost:3000/v1/shape',
table: 'users',
where: 'id > 100',
columns: ['id', 'name'],
replica: 'full',
})
```

After:

```typescript
const stream = new ShapeStream({
url: 'http://localhost:3000/v1/shape',
params: {
table: 'users',
where: 'id > 100',
columns: ['id', 'name'],
replica: 'full',
},
})
```

### Patch Changes

- Updated dependencies [9c50e8f]
- Updated dependencies [af0c0bf]
- Updated dependencies [e96928e]
- @electric-sql/client@0.9.0

## 0.5.4

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/react-hooks/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@electric-sql/react",
"version": "0.5.4",
"version": "0.6.0",
"description": "React hooks for ElectricSQL",
"type": "module",
"main": "dist/cjs/index.cjs",
Expand Down
17 changes: 17 additions & 0 deletions packages/sync-service/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
# @core/sync-service

## 0.9.4

### Patch Changes

- 3584f67: Validate that user provided offset is not bigger than the shape's latest offset.
- 0dc844f: Remove redundant spans in open telemetry tracing.
- a16ab24: feat: add more telemetry
- 3c24208: Clean up directories when removing shapes.
Remove corrupted shapes from store when recovery fails.
- 4e50204: Telemetry for reporting replication lag.
- 704ac91: Include caching headers on 304 responses to prevent client from rechecking the previously cached ones over and over again.
- ceec2d4: Assume process is not alive if registry is not alive.
- 37b4256: Improved replication steam processing for where clauses in the form `field = const` or `field = const AND another_condition`
- 64fe275: Restore the automatic fallback to unencrypted database connections when SSL isn't available.
- 5b1c3e6: Resolve naming confusion between `ELECTRIC_LOG_CHUNK_BYTES_THRESHOLD` and logging-related configuration options. Add `ELECTRIC_` prefix to `LOG_LEVEL` to `LOG_OTP_REPORTS` config options. Introduce a new config option named `ELECTRIC_LOG_COLORS`.
- e815b91: Log error but don't fall over if failing to initialise recovered shape

## 0.9.3

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/sync-service/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@core/sync-service",
"private": true,
"version": "0.9.3",
"version": "0.9.4",
"scripts": {
"publish:hex": "mix do deps.get, hex.publish --yes || true"
}
Expand Down
55 changes: 55 additions & 0 deletions packages/typescript-client/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,60 @@
# @electric-sql/client

## 0.9.0

### Minor Changes

- 9c50e8f: [BREAKING]: Remove databaseId option from ShapeStream in favor of params option.
- e96928e: [BREAKING]: Move non-protocol options like table & where to the params sub-key

## Context

Electric's TypeScript client is currently tightly coupled to PostgreSQL-specific options in its `ShapeStreamOptions` interface. As Electric plans to support multiple data sources in the future, we need to separate protocol-level options from source-specific options.

## Changes

1. Created a new `PostgresParams` type to define PostgreSQL-specific parameters:
- `table`: The root table for the shape
- `where`: Where clauses for the shape
- `columns`: Columns to include in the shape
- `replica`: Whether to send full or partial row updates
2. Moved PostgreSQL-specific options from the top-level `ShapeStreamOptions` interface to the `params` sub-key
3. Updated `ParamsRecord` type to include PostgreSQL parameters
4. Updated the `ShapeStream` class to handle parameters from the `params` object
5. Updated documentation to reflect the changes

## Migration Example

Before:

```typescript
const stream = new ShapeStream({
url: 'http://localhost:3000/v1/shape',
table: 'users',
where: 'id > 100',
columns: ['id', 'name'],
replica: 'full',
})
```

After:

```typescript
const stream = new ShapeStream({
url: 'http://localhost:3000/v1/shape',
params: {
table: 'users',
where: 'id > 100',
columns: ['id', 'name'],
replica: 'full',
},
})
```

### Patch Changes

- af0c0bf: Always use sorted query parameters in official clients to ensure Shape URLs are cached consistently.

## 0.8.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/typescript-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@electric-sql/client",
"version": "0.8.0",
"version": "0.9.0",
"description": "Postgres everywhere - your data, in sync, wherever you need it.",
"type": "module",
"main": "dist/cjs/index.cjs",
Expand Down

0 comments on commit ab1ea51

Please sign in to comment.