neo4j-java-driver 0.1.11-java → 0.2.0-java
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/jruby/neo4j/driver/ext/graph_database.rb +5 -14
- data/lib/neo4j/driver/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1bdf27c962cb244f14fb20db18054c7796339860b4b17dc3bb5922130d392f99
|
4
|
+
data.tar.gz: ddc24ae83bd8673fff646775ecaa96b0de33db1a63ae1cffe963f2bc82424cb2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8efab4fc0fbc83dd2259f49eef7fa60465c85eb2dad646430786d9a2fb4b4aee2a5440c7eda376214ad3116a485639085faf1caa7a16eef2d5c38861ba9e5d95
|
7
|
+
data.tar.gz: d8e4a0d4c06f5e1b7cf73068aa9572297afdb8e90f82723bb87ca1ace7fc641d0376327e2f8791bc698f0a54a814522eafb8c6aa5f68797b925f981aa1f85256
|
@@ -7,7 +7,7 @@ module Neo4j
|
|
7
7
|
extend AutoClosable
|
8
8
|
include ExceptionCheckable
|
9
9
|
|
10
|
-
auto_closable :driver
|
10
|
+
auto_closable :driver, :routing_driver
|
11
11
|
|
12
12
|
def driver(uri, auth_token = Neo4j::Driver::AuthTokens.none, config = nil)
|
13
13
|
check do
|
@@ -16,6 +16,10 @@ module Neo4j
|
|
16
16
|
end
|
17
17
|
end
|
18
18
|
|
19
|
+
def routing_driver(routing_uris, auth_token, config)
|
20
|
+
check { super(routing_uris.map { |uri| java.net.URI.create(uri.to_s) }, auth_token, to_java_config(config)) }
|
21
|
+
end
|
22
|
+
|
19
23
|
private
|
20
24
|
|
21
25
|
def to_java_config(hash)
|
@@ -32,8 +36,6 @@ module Neo4j
|
|
32
36
|
method = :without_encryption
|
33
37
|
value = nil
|
34
38
|
end
|
35
|
-
when 'load_balancing_strategy'
|
36
|
-
value = load_balancing_strategy(value)
|
37
39
|
when /Time(out)?$/i
|
38
40
|
unit = java.util.concurrent.TimeUnit::SECONDS
|
39
41
|
when 'logger'
|
@@ -42,17 +44,6 @@ module Neo4j
|
|
42
44
|
end
|
43
45
|
[method, value, unit].compact
|
44
46
|
end
|
45
|
-
|
46
|
-
def load_balancing_strategy(value)
|
47
|
-
case value
|
48
|
-
when :least_connected
|
49
|
-
Config::LoadBalancingStrategy::LEAST_CONNECTED
|
50
|
-
when :round_robin
|
51
|
-
Config::LoadBalancingStrategy::ROUND_ROBIN
|
52
|
-
else
|
53
|
-
raise ArgumentError
|
54
|
-
end
|
55
|
-
end
|
56
47
|
end
|
57
48
|
end
|
58
49
|
end
|
data/lib/neo4j/driver/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: neo4j-java-driver
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: java
|
6
6
|
authors:
|
7
7
|
- Heinrich Klobuczek
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|