Skip to content

Kotlin SDK: Remove websocket docs #212

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 5, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 0 additions & 27 deletions client-sdk-references/kotlin-multiplatform.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -338,43 +338,16 @@
- Most upcoming features will not be ported to this implementation, and we intend to remove it eventually.
2. **Rust (currently experimental)**
- This is a newer implementation, mostly implemented in Rust but still using Kotlin for networking.
- Apart from newer features, this implementation is also more performant.

Check warning on line 341 in client-sdk-references/kotlin-multiplatform.mdx

View check run for this annotation

Mintlify / Mintlify Validation (powersync) - vale-spellcheck

client-sdk-references/kotlin-multiplatform.mdx#L341

Did you really mean 'performant'?
- We [encourage interested users to try it out](https://releases.powersync.com/announcements/improved-sync-performance-in-our-client-sdks)
and report feedback, as we intend to make it the default after a stabilization period.

To enable the Rust client, pass `SyncOptions(newClientImplementation = true)` as a second parameter when
[connecting](https://powersync-ja.github.io/powersync-kotlin/core/com.powersync/-power-sync-database/connect.html).

### Connection Methods

This SDK supports two methods for streaming sync commands:

1. **WebSocket (currently experimental)**
- The implementation leverages RSocket for handling reactive socket streams.
- Back-pressure is effectively managed through client-controlled command requests.
- Sync commands are transmitted efficiently as BSON (binary) documents.
- Enabling websocket support requires the new client implementation.
2. **HTTP Streaming (default)**
- This is the original implementation method.
- This method sends data as text (JSON) instead of BSON.

By default, the `PowerSyncDatabase.connect()` method uses HTTP streams.
You can optionally specify the `connectionMethod` to override this:

```Kotlin
// HTTP streaming (default)
powerSync.connect(connector)

// WebSockets (experimental)
powerSync.connect(connector, SyncOptions(
newClientImplementation = true,
method = ConnectionMethod.WebSocket(),
))
```

## ORM Support

ORM support is not yet available, we are still investigating options to integrate the SDK with Room and SQLDelight.

Check warning on line 350 in client-sdk-references/kotlin-multiplatform.mdx

View check run for this annotation

Mintlify / Mintlify Validation (powersync) - vale-spellcheck

client-sdk-references/kotlin-multiplatform.mdx#L350

Did you really mean 'SQLDelight'?
Please [let us know](/resources/contact-us) what your needs around ORMs are.

## Troubleshooting
Expand Down