gremlin_client 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ac1726d69ef30e73f89b9df036282fdaaa2ba7ec
4
- data.tar.gz: 5cc55e6a074faad8e7ed1b95a3e5832a572ac3b8
3
+ metadata.gz: aefc65f39b83dd628d9ef6e2202c16b11cc05920
4
+ data.tar.gz: 7f5ae544adb28d7c873c587e74636c82b97b1e71
5
5
  SHA512:
6
- metadata.gz: 577ae755b2dd6838ae88caa683af726f65b6e8423717608a1fe23173b0dc85a5a96c6f7695e06136de2ed559f337eeafdb0134ced79f53f7765434ce283a6804
7
- data.tar.gz: ca42b57048b747bf4816aa1b7e4ebd4f556fddcdbe743e0037744c7f4f7153fa59bc31aeb746a4bcf8bdc53a57428980a12a7cdc8cb34d76637a44ca043b26a0
6
+ metadata.gz: d698276d7cafde7e6a3b9a2fb774e4a370e559633f063357546e7fa04ebe38e12678c23ed06b3c7da3691ff0c24466903dfce7974f31c551393a60200e9589f2
7
+ data.tar.gz: b8f896109203ddb86be159e31bd094d0062cd56f3dcc0ddc674f5b3f1e1eb54f3498ed107b319639e63a799c8c509605ec7ebfb3c0470bb1791aeed08203dc23
@@ -1,7 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gremlin_client (0.1.3)
4
+ gremlin_client (0.1.4)
5
+ oj (~> 2.18)
5
6
  websocket-client-simple (~> 0.3)
6
7
 
7
8
  GEM
@@ -45,6 +46,7 @@ GEM
45
46
  notiffany (0.1.1)
46
47
  nenv (~> 0.1)
47
48
  shellany (~> 0.0)
49
+ oj (2.18.5)
48
50
  parser (2.4.0.0)
49
51
  ast (~> 2.2)
50
52
  powerpack (0.1.1)
data/README.md CHANGED
@@ -8,6 +8,16 @@
8
8
 
9
9
 
10
10
 
11
+ ```
12
+ =================================== WARNING ===================================
13
+ || If you are using version 0.1.2 or prior please update! Your results won't ||
14
+ || be consistent while you don't do so! ||
15
+ =================================== WARNING ===================================
16
+ ```
17
+ Details on the above at
18
+ [#3](https://github.com/marcelocf/gremlin_client/issues/3)
19
+
20
+
11
21
  Gremlin client in ruby for the WebSocketChannelizer.
12
22
 
13
23
  This client is not thread safe by itself! If you want to make it safer for your app, please make sure
@@ -5,11 +5,4 @@ require 'gremlin_client'
5
5
 
6
6
 
7
7
  conn = GremlinClient::Connection.new(gremlin_script_path: 'example/scripts')
8
-
9
- pp conn.send_query('1+what', {what: 10})
10
-
11
- pp conn.send_query('0 && 1')
12
-
13
- pp conn.send_file('test.groovy', {what: Time.now.to_i})
14
-
15
- conn.close
8
+ pp conn.send_file('test.groovy', {what: 10})
@@ -20,6 +20,7 @@ Gem::Specification.new do |spec|
20
20
  spec.require_paths = ["lib"]
21
21
 
22
22
  spec.add_dependency 'websocket-client-simple', '~> 0.3'
23
+ spec.add_dependency 'oj', '~> 2.18'
23
24
 
24
25
  spec.add_development_dependency 'bundler', '~> 1.13'
25
26
  spec.add_development_dependency 'rake', '~> 12.0'
@@ -1,4 +1,4 @@
1
-
1
+ require 'oj'
2
2
  module GremlinClient
3
3
  # represents the connection to our gremlin server
4
4
  class Connection
@@ -95,7 +95,7 @@ module GremlinClient
95
95
 
96
96
  # this has to be public so the websocket client thread sees it
97
97
  def receive_message(msg)
98
- response = JSON.parse(msg.data)
98
+ response = Oj.load(msg.data)
99
99
  # this check is important in case a request timeout and we make new ones after
100
100
  if response['requestId'] == @request_id
101
101
  if @response.nil?
@@ -175,7 +175,7 @@ module GremlinClient
175
175
  language: 'gremlin-groovy'
176
176
  }
177
177
  }
178
- JSON.generate(message)
178
+ Oj.dump(message, mode: :compat)
179
179
  end
180
180
 
181
181
  def resolve_path(filename)
@@ -1,3 +1,3 @@
1
1
  module GremliClient
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gremlin_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcelo Coraça de Freitas
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-30 00:00:00.000000000 Z
11
+ date: 2017-04-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: websocket-client-simple
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0.3'
27
+ - !ruby/object:Gem::Dependency
28
+ name: oj
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.18'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.18'
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: bundler
29
43
  requirement: !ruby/object:Gem::Requirement
@@ -158,7 +172,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
158
172
  version: '0'
159
173
  requirements: []
160
174
  rubyforge_project:
161
- rubygems_version: 2.6.10
175
+ rubygems_version: 2.5.1
162
176
  signing_key:
163
177
  specification_version: 4
164
178
  summary: Simple Gremlin server client for the WebSocketChannelizer