statscloud 1.0.1 → 1.0.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cfc4b9f7ca3ff6dfc74d26c74805c53562ef11ae1842c043ff76fa802025867e
4
- data.tar.gz: 8bd02234c81c1537ed5b03b5eb507d31e23cf0140ebf03343445af1d143904c5
3
+ metadata.gz: 975399b879c7b5d75bce48b4318eb6d2c8a15a84e12b3b88a91ba11780a5fba7
4
+ data.tar.gz: 9a89d250087c614d37c8ce2b6e25fff3b7bbc9d4fecbf52b0c2839211a75ba58
5
5
  SHA512:
6
- metadata.gz: 1036da28708e37ced51549361dc0f200ba3ab9a4386ad9b5ce6b0228d77ed56e25b3ff491ff9d80f449ce9806c42be70da2655ababfd629b93066fd06a13889d
7
- data.tar.gz: 09800276336b3e3087c332d27facf0e57118ba3175c141af87b5467a21a7c434ae4d3d9a9b2fa38acb9186bf0f0d957109bd1439556eb6a0a2f819e580226e98
6
+ metadata.gz: cf9e39a86f33e9fc6fa960470303eefc15a5f9e89ff16648fe104a5ff7eb734367e6e319d1c0c3b62fa0c69e01c4f473c27d8b617fd7bb78a9b992bd4625e82b
7
+ data.tar.gz: e244c81a7dd520fbec1c3f2c3614fcd26e8a4656b27bfe45bdf6b6d0ffe51e4f7020c88d919c6182495c96ed5d448b27cc3ad64d1a5a7164e9466f84c3f3f7d7
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- statscloud (1.0.0)
4
+ statscloud (1.0.2)
5
5
  activesupport (>= 5.0.0.1)
6
6
  crc32 (~> 1.0.1)
7
7
  eventmachine (~> 1.2)
@@ -86,4 +86,4 @@ DEPENDENCIES
86
86
  statscloud!
87
87
 
88
88
  BUNDLED WITH
89
- 1.16.3
89
+ 1.17.1
data/README.md CHANGED
@@ -24,7 +24,9 @@ Or install it yourself as:
24
24
  ```ruby
25
25
  rails g stats_cloud:install
26
26
  ```
27
- 2. Set up your configuration files (you can read more about StatsCloud configuration [here](https://medium.com/@roman.kisilenko/software-application-monitoring-how-to-or-how-not-to-let-your-production-fail-9481dd0ef6de)).
27
+ 2. Set up your configuration files (you can read more about StatsCloud configuration [here](https://medium.com/@roman.kisilenko/software-application-monitoring-how-to-or-how-not-to-let-your-production-fail-9481dd0ef6de)).
28
+
29
+ StatsCloud auth token is a required parameter for getting access to StatsCloud service. The best way to configure this auth token in your application is using environment variable `STATSCLOUD_AUTH_TOKEN`. StatsCloud add-on at Heroku configures this environment variable automatically during adding this add-on to your application. If you want to use statscloud service in your development process (or somewhere else) you can [copy Heroku config vars to your local .env file](https://devcenter.heroku.com/articles/heroku-local).
28
30
 
29
31
  3. You can change `statscloud.rb` intializer file if you want to start StatsCloud service with a different environment or add some tags to your StatsmeterClient.
30
32
 
@@ -15,6 +15,10 @@ module StatsCloud
15
15
  @tags = tags
16
16
  end
17
17
 
18
+ def config_token
19
+ @token = @config['token'] || ENV['STATSCLOUD_AUTH_TOKEN']
20
+ end
21
+
18
22
  def env
19
23
  @env ||= @config['environment'] || ENV['RAILS_ENV'] || 'default'
20
24
  end
@@ -109,7 +109,7 @@ module StatsCloud
109
109
 
110
110
  def config_values
111
111
  @config['sourceMaps'] = source_mappings
112
- @token = @config['token']
112
+ config_token
113
113
  @app = @config['application']
114
114
  end
115
115
 
@@ -4,5 +4,5 @@ module StatsCloud
4
4
  # version of statscloud-ruby-client.
5
5
  #
6
6
  # Type: *String*
7
- VERSION = '1.0.1'
7
+ VERSION = '1.0.2'
8
8
  end
@@ -1,5 +1,5 @@
1
1
  ---
2
- token: place-your-token-here
2
+ token:
3
3
  passwordProtect: false
4
4
  application: your-application-name
5
5
  flushIntervalInSeconds: 15
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: statscloud
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Roman Ovcharov
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-29 00:00:00.000000000 Z
11
+ date: 2018-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport