optics-agent 0.4.1 → 0.4.2

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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -2
  3. metadata +23 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c2b2a148777b845f0cf7b9857985e17546a70320
4
- data.tar.gz: 48aab1abbf6eb781bf9a1744e0ffec7ac551c85a
3
+ metadata.gz: b416f4296566bd8ee9c925ebf368420da59875f9
4
+ data.tar.gz: 8a7915bbf4b4aeea8020e6d2e7e848696f567bcd
5
5
  SHA512:
6
- metadata.gz: 2179a4eb6d2d6be7cdd61be3aa84a66e82afcba9687023a4106cc4671533bc4c158c7c0c6af6a3449755611ed174b20c22db078a7ec99fb273c2398829369cb2
7
- data.tar.gz: 98079604f11e6cf92e5ebdcbabbffa389fac48ded7f0560444f6866f0d674775a95111b794d5884a53f22df841778fb7f391ed9510a29b8df221356c1f21883d
6
+ metadata.gz: 4a74329dd8338234ab390071767c7212c5a6d7fcab76d137be9d579c1a2e53a6a171af28f663e99bdd133e1e6f3c7a88c73479558a150635b5ac1b2335b21869
7
+ data.tar.gz: d634b06b48fc8e2439997eec02313f45b4fa61cc6087932048c02653b2ca9da9c4ae5b46420a890c81acdd94091a73ea670dbbff07db1da68fe7def4a8198f9c
data/README.md CHANGED
@@ -16,7 +16,7 @@ To your `Gemfile`
16
16
 
17
17
  ### API key
18
18
 
19
- You'll need to run your app with the `OPTICS_API_KEY` environment variable set (or set via `agent.configure`) to the API key of your Apollo Optics service; you can get an API key by setting up a service at https://optics.apollodata.com.
19
+ You'll need to run your app with the `OPTICS_API_KEY` environment variable set (or set via [`agent.configure`](#configuration)) to the API key of your Apollo Optics endpoint; you can get an API key by setting up a endpoint at https://optics.apollodata.com.
20
20
 
21
21
  ## Rails Setup
22
22
 
@@ -30,7 +30,7 @@ end
30
30
  Rails.application.config.middleware.use optics_agent.rack_middleware
31
31
  ```
32
32
 
33
- Register Optics Agent on the GraphQL context within your `graphql` action as below:
33
+ Register Optics Agent from your on the GraphQL context within your `graphql` action as below:
34
34
  ```ruby
35
35
  def create
36
36
  query_string = params[:query]
@@ -40,6 +40,8 @@ def create
40
40
  query_string,
41
41
  variables: query_variables,
42
42
  context: {
43
+ # This is the key line: we take the optics_agent passed in from the
44
+ # Rack environment, give it the query_string, and pass it as context
43
45
  optics_agent: env[:optics_agent].with_document(query_string)
44
46
  }
45
47
  )
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: optics-agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - 'Tom Coleman '
@@ -16,33 +16,36 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 1.1.0
19
+ version: '1.1'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 1.1.0
26
+ version: '1.1'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: google-protobuf
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 3.1.0
33
+ version: '3.1'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 3.1.0
40
+ version: '3.1'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: faraday
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '0.9'
48
+ - - ">="
46
49
  - !ruby/object:Gem::Version
47
50
  version: 0.9.2
48
51
  type: :runtime
@@ -50,6 +53,9 @@ dependencies:
50
53
  version_requirements: !ruby/object:Gem::Requirement
51
54
  requirements:
52
55
  - - "~>"
56
+ - !ruby/object:Gem::Version
57
+ version: '0.9'
58
+ - - ">="
53
59
  - !ruby/object:Gem::Version
54
60
  version: 0.9.2
55
61
  - !ruby/object:Gem::Dependency
@@ -57,6 +63,9 @@ dependencies:
57
63
  requirement: !ruby/object:Gem::Requirement
58
64
  requirements:
59
65
  - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '2.0'
68
+ - - ">="
60
69
  - !ruby/object:Gem::Version
61
70
  version: 2.0.0
62
71
  type: :runtime
@@ -64,6 +73,9 @@ dependencies:
64
73
  version_requirements: !ruby/object:Gem::Requirement
65
74
  requirements:
66
75
  - - "~>"
76
+ - !ruby/object:Gem::Version
77
+ version: '2.0'
78
+ - - ">="
67
79
  - !ruby/object:Gem::Version
68
80
  version: 2.0.0
69
81
  - !ruby/object:Gem::Dependency
@@ -71,6 +83,9 @@ dependencies:
71
83
  requirement: !ruby/object:Gem::Requirement
72
84
  requirements:
73
85
  - - "~>"
86
+ - !ruby/object:Gem::Version
87
+ version: '1.2'
88
+ - - ">="
74
89
  - !ruby/object:Gem::Version
75
90
  version: 1.2.4
76
91
  type: :runtime
@@ -78,6 +93,9 @@ dependencies:
78
93
  version_requirements: !ruby/object:Gem::Requirement
79
94
  requirements:
80
95
  - - "~>"
96
+ - !ruby/object:Gem::Version
97
+ version: '1.2'
98
+ - - ">="
81
99
  - !ruby/object:Gem::Version
82
100
  version: 1.2.4
83
101
  - !ruby/object:Gem::Dependency