bjond-api 0.3.3 → 0.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/bjond-api.gemspec +2 -2
- data/lib/bjond-api.rb +4 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1bef5e11b37c3488a65f61a7bc1d68b553b32a77
|
4
|
+
data.tar.gz: 9c4e296d904a5672837e9d9e0d4189907231b32b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e4e27adf972e6d56b871c05328f538f0dfddc0dd03560c9496de21e37412cf1c5b2c83d09e7a70084d58af53c19cb4ee385baa9173d719ad9553286bcc6229ef
|
7
|
+
data.tar.gz: bba3308820b734d400cf5831f7562d5bb140f17407e156be51c7a95e328ee4adf044194f910b4abfb5ada697b1d4d211bb6e9964b03d6a99681b9ec4459e4d5b
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.4
|
data/bjond-api.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: bjond-api 0.3.
|
5
|
+
# stub: bjond-api 0.3.4 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "bjond-api".freeze
|
9
|
-
s.version = "0.3.
|
9
|
+
s.version = "0.3.4"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib".freeze]
|
data/lib/bjond-api.rb
CHANGED
@@ -25,10 +25,13 @@ module BjondApi
|
|
25
25
|
##
|
26
26
|
# Fires events to all bjond_registrations
|
27
27
|
def fire_event(bjond_registration, payload, event_id)
|
28
|
+
puts "Firing event for registration " + bjond_registration.id.
|
28
29
|
services = BjondService.where(:bjond_registration_id => bjond_registration.id)
|
29
30
|
connections = []
|
30
31
|
services.each do |bjond_svc|
|
31
|
-
|
32
|
+
url = bjond_svc.endpoint# + "/#{event_id}"
|
33
|
+
puts "Creating connection to " + url
|
34
|
+
conn = Faraday.new(:url => url)
|
32
35
|
conn.post do |req|
|
33
36
|
req.headers['Content-Type'] = 'application/json'
|
34
37
|
req.body = BjondJwt::jwt_encode_payload(payload, bjond_registration)
|