snowplow-tracker 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/README.md +18 -2
- data/lib/snowplow-tracker/emitters.rb +2 -3
- data/lib/snowplow-tracker/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
NTI5MDdmMWUwZjNlYjYwM2M1NTI2YzMzZWViMjMzZmMwNWYzNGMwMw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YTQwYzM4NjQ3N2VjZWNmNjk5ODdjZTE0MWYwZTVkZjQzMTc3OWMwNg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NTNiMjI4NmQzMTdmM2VkZWQwODgyYTZkOTY3MWEwMzQ2MjMwNTAxYzlkNTM4
|
10
|
+
YTViOTNmMjk0Y2UyZDIyZjViNTY4NWY5YzZhMTE4ZDUwNWQyNzZkMGM5ZGQw
|
11
|
+
ZTU3MzUzYTc0Mzg0ODhjM2ZmZjcwZGQ0YTliYTg2ZWUwMTIzNDg=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NTQxODBlODY4ZmFlMGU4YWNlODA2MGFkYWU3YmQyMTYwNjFlZDc4MThkZGNl
|
14
|
+
YjE1MGRjZGFmY2I4MTlhODFjYmVlMjQ4MmMwMTFmMDA2NzcxNmFmNGUzMGU1
|
15
|
+
NWI0MTM2YmEzMmY4MmJlYmJjYTRlY2NjMWFjYjc2MjExYWE3NjA=
|
data/README.md
CHANGED
@@ -6,9 +6,22 @@
|
|
6
6
|
|
7
7
|
## Overview
|
8
8
|
|
9
|
-
Add analytics to your Ruby and Rails apps and gems with the [Snowplow] [snowplow] event tracker for [Ruby] [ruby]
|
9
|
+
Add analytics to your Ruby and Rails apps and gems with the **[Snowplow] [snowplow]** event tracker for **[Ruby] [ruby]**.
|
10
10
|
|
11
|
-
With this tracker you can collect event data from your [Ruby] [ruby] applications, [Ruby on Rails] [rails] web applications and [Ruby gems] [rubygems]
|
11
|
+
With this tracker you can collect event data from your **[Ruby] [ruby]** applications, **[Ruby on Rails] [rails]** web applications and **[Ruby gems] [rubygems]**.
|
12
|
+
|
13
|
+
## Quickstart
|
14
|
+
|
15
|
+
Assuming git, **[Vagrant] [vagrant-install]** and **[VirtualBox] [virtualbox-install]** installed:
|
16
|
+
|
17
|
+
```bash
|
18
|
+
host$ git clone https://github.com/snowplow/snowplow-ruby-tracker.git
|
19
|
+
host$ cd snowplow-ruby-tracker
|
20
|
+
host$ vagrant up && vagrant ssh
|
21
|
+
guest$ cd /vagrant
|
22
|
+
guest$ bundle install
|
23
|
+
guest$ rspec
|
24
|
+
```
|
12
25
|
|
13
26
|
## Find out more
|
14
27
|
|
@@ -36,6 +49,9 @@ limitations under the License.
|
|
36
49
|
|
37
50
|
[snowplow]: http://snowplowanalytics.com
|
38
51
|
|
52
|
+
[vagrant-install]: http://docs.vagrantup.com/v2/installation/index.html
|
53
|
+
[virtualbox-install]: https://www.virtualbox.org/wiki/Downloads
|
54
|
+
|
39
55
|
[techdocs-image]: https://d3i6fms1cm1j0i.cloudfront.net/github/images/techdocs.png
|
40
56
|
[setup-image]: https://d3i6fms1cm1j0i.cloudfront.net/github/images/setup.png
|
41
57
|
[roadmap-image]: https://d3i6fms1cm1j0i.cloudfront.net/github/images/roadmap.png
|
@@ -129,7 +129,7 @@ module SnowplowTracker
|
|
129
129
|
elsif @method == 'post'
|
130
130
|
if temp_buffer.size > 0
|
131
131
|
request = http_post({
|
132
|
-
'schema' => 'iglu:com.snowplowanalytics.snowplow/payload_data/1-0-
|
132
|
+
'schema' => 'iglu:com.snowplowanalytics.snowplow/payload_data/jsonschema/1-0-2',
|
133
133
|
'data' => temp_buffer
|
134
134
|
})
|
135
135
|
|
@@ -177,12 +177,11 @@ module SnowplowTracker
|
|
177
177
|
LOGGER.debug("Payload: #{payload}")
|
178
178
|
destination = URI(@collector_uri)
|
179
179
|
http = Net::HTTP.new(destination.host, destination.port)
|
180
|
-
request = Net::HTTP::Post.new(destination)
|
181
180
|
request = Net::HTTP::Post.new(destination.request_uri)
|
182
181
|
if destination.scheme == 'https'
|
183
182
|
http.use_ssl = true
|
184
183
|
end
|
185
|
-
request.
|
184
|
+
request.body = payload.to_json
|
186
185
|
request.set_content_type('application/json; charset=utf-8')
|
187
186
|
response = http.request(request)
|
188
187
|
LOGGER.add(response.code == '200' ? Logger::INFO : Logger::WARN) {
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: snowplow-tracker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Dean
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2015-01-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: contracts
|
@@ -76,13 +76,13 @@ extra_rdoc_files: []
|
|
76
76
|
files:
|
77
77
|
- LICENSE-2.0.txt
|
78
78
|
- README.md
|
79
|
+
- lib/snowplow-tracker.rb
|
79
80
|
- lib/snowplow-tracker/contracts.rb
|
80
81
|
- lib/snowplow-tracker/emitters.rb
|
81
82
|
- lib/snowplow-tracker/payload.rb
|
82
83
|
- lib/snowplow-tracker/subject.rb
|
83
84
|
- lib/snowplow-tracker/tracker.rb
|
84
85
|
- lib/snowplow-tracker/version.rb
|
85
|
-
- lib/snowplow-tracker.rb
|
86
86
|
homepage: http://github.com/snowplow/snowplow-ruby-tracker
|
87
87
|
licenses:
|
88
88
|
- Apache License 2.0
|
@@ -103,7 +103,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
103
103
|
version: '0'
|
104
104
|
requirements: []
|
105
105
|
rubyforge_project:
|
106
|
-
rubygems_version: 2.
|
106
|
+
rubygems_version: 2.4.5
|
107
107
|
signing_key:
|
108
108
|
specification_version: 4
|
109
109
|
summary: Ruby Analytics for Snowplow
|