Skip to content

Commit 1cae7c2

Browse files
committed
📓 [docs] READMEにURLオプションの説明を追加
1 parent 4b78350 commit 1cae7c2

File tree

1 file changed

+38
-1
lines changed

1 file changed

+38
-1
lines changed

README.md

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,37 @@ async fn main() -> anyhow::Result<()> {
4141
}
4242
```
4343

44+
## URL
45+
46+
### Full example
47+
48+
```url
49+
scylladb://myname:mypassword@localhost:9042/my_keyspace?nodes=example.test,example2.test:9043&tcp_nodelay&tcp_keepalive=40&compression=lz4&replication_strategy=SimpleStrategy&replication_factor=2&page_size=10
50+
```
51+
52+
### Basic
53+
54+
| Part | Required | Example | Explanation |
55+
|----------|----------|-------------|-----------------------------------------------|
56+
| schema | Required | scylladb | Only `scylladb` can be specified. |
57+
| username | Optional | myname | Specify the username for user authentication. |
58+
| password | Optional | mypassword | Specify the password for user authentication. |
59+
| host | Required | localhost | Specify the hostname of the primary node. |
60+
| port | Optional | 9042 | Specify the port number. The default is 9042. |
61+
| path | Required | my_keyspace | Specify the keyspace. |
62+
63+
### Query parameters
64+
65+
| Name | Example | Explanation |
66+
|----------------------|---------------------------------|----------------------------------------------------------------------------------------------------------------------------------|
67+
| nodes | example.test,example2.test:9043 | Specify additional nodes separated by commas. |
68+
| tcp_nodelay | | When using tcp_nodelay, specify the key. No value is required. |
69+
| tcp_keepalive | 40 | When using tcp_keepalive, specify the keepalive interval in seconds. |
70+
| compression | lz4 | Specify when compressing communication data. Supported values are `lz4` or `snappy`. |
71+
| replication_strategy | SimpleStrategy | Specifies the replication strategy when creating a keyspace. Supported values are `SimpleStrategy` or `NetworkTopologyStrategy`. |
72+
| replication_factor | 2 | Specify the replication factor when creating a keyspace. |
73+
| page_size | 10 | Specify the number of results to retrieve per page when receiving query results. |
74+
4475
## Features
4576

4677
### Basic type binding
@@ -99,7 +130,7 @@ To avoid additional memory allocation, only borrowing is supported.
99130

100131
Currently, only manual implementation is supported.
101132

102-
- [ ] Manual implementation.
133+
- [x] Manual implementation.
103134
- [ ] Derive macro.
104135

105136
### Testing
@@ -111,3 +142,9 @@ Currently, only manual implementation is supported.
111142
- [x] Support migrations in #[sqlx::test] macro.
112143
- [x] sqlx::migrate::Migrator
113144
- [ ] CLI
145+
146+
### TLS
147+
148+
Currently not supported.
149+
150+
- [ ] TLS

0 commit comments

Comments
 (0)