yugabyte_ysql 0.2 → 0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +9 -1
- data/lib/pg/connection.rb +8 -1
- data/lib/pg/load_balance_service.rb +1 -1
- data/lib/pg/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: efed9ab399e09009ea47c27a31e9a4d83521921bd1c40dec9d5964f2bc5eb913
|
4
|
+
data.tar.gz: b3b96169102271a054dcfe48092c996768250fdd73bd65ed3a6357347c811adc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 64fd469fa89722be35d1f7ba890a3d97654670284d282592c92cca65cce72f7e80b7459c970ed806bc9aa416db4865530a861b855b4b0c7380c684fc9e7fedde
|
7
|
+
data.tar.gz: 2b8b3bfa1717ff53fa30037cf82e0521ca2c0f43cfb7c34600a21ae6cfcb4fa97d4cacfcc8c6dc4fb5f8ffe575fe6974a38c2638d4dce36a2ce45cf803a71dec
|
data/README.md
CHANGED
@@ -27,7 +27,7 @@ Please refer to the [Use the Driver](#Use the Driver) section for examples.
|
|
27
27
|
## Install the Driver
|
28
28
|
|
29
29
|
```shell
|
30
|
-
gem install -- --with-pg-config=<yugabyte-install-dir>/postgres/bin/pg_config
|
30
|
+
gem install yugabyte_ysql -- --with-pg-config=<yugabyte-install-dir>/postgres/bin/pg_config
|
31
31
|
```
|
32
32
|
|
33
33
|
## Use the Driver
|
@@ -53,6 +53,14 @@ gem install -- --with-pg-config=<yugabyte-install-dir>/postgres/bin/pg_config
|
|
53
53
|
...
|
54
54
|
```
|
55
55
|
|
56
|
+
Alternatively, you could also specify the properties as key, value pairs as shown below.
|
57
|
+
|
58
|
+
```
|
59
|
+
connection = YugabyteYSQL.connect(host: 'localhost', port: '5433', dbname: 'yugabyte',
|
60
|
+
user: 'yugabyte', password: 'yugabyte',
|
61
|
+
load_balance: 'true', yb_servers_refresh_interval: '10')
|
62
|
+
```
|
63
|
+
|
56
64
|
### Specifying fallback zones
|
57
65
|
|
58
66
|
For topology-aware load balancing, you can specify fallback placements too. This is not applicable for cluster-aware load balancing.
|
data/lib/pg/connection.rb
CHANGED
@@ -333,7 +333,14 @@ class YugabyteYSQL::Connection
|
|
333
333
|
### Returns an array of Hashes with connection defaults. See ::conndefaults
|
334
334
|
### for details.
|
335
335
|
def conndefaults
|
336
|
-
|
336
|
+
original = self.class.conndefaults
|
337
|
+
original << {:keyword=>"load_balance", :label=>"YB-Load-Balance", :dispchar=>"", :dispsize=>5}
|
338
|
+
original << {:keyword=>"topology_keys", :label=>"YB-Topology-Keys", :dispchar=>"", :dispsize=>64}
|
339
|
+
original << {:keyword=>"yb_servers_refresh_interval", :label=>"YB-Refresh-Interval", :dispchar=>"", :dispsize=>3}
|
340
|
+
original << {:keyword=>"fallback_to_topology_keys_only", :label=>"YB-Fallback-To-Topology-Keys-Only", :dispchar=>"", :dispsize=>5}
|
341
|
+
original << {:keyword=>"failed_host_reconnect_delay_secs", :label=>"YB-Failed-Host-Reconnect-Delay", :dispchar=>"", :dispsize=>3}
|
342
|
+
|
343
|
+
original
|
337
344
|
end
|
338
345
|
|
339
346
|
### Return the Postgres connection defaults structure as a Hash keyed by option
|
data/lib/pg/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yugabyte_ysql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.3'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Granger
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2024-06-
|
13
|
+
date: 2024-06-25 00:00:00.000000000 Z
|
14
14
|
dependencies: []
|
15
15
|
description: Pg_YugabyteDB is the Ruby interface to the PostgreSQL-compatible YugabyteDB.
|
16
16
|
It works with YugabyteDB 2.20 and later.
|
@@ -225,7 +225,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
225
225
|
- !ruby/object:Gem::Version
|
226
226
|
version: '0'
|
227
227
|
requirements: []
|
228
|
-
rubygems_version: 3.
|
228
|
+
rubygems_version: 3.3.27
|
229
229
|
signing_key:
|
230
230
|
specification_version: 4
|
231
231
|
summary: The Ruby interface to YugabyteDB, based on PG Ruby Driver v1.5.6
|