sample_core_api 0.0.9.pre.2 → 0.0.9.pre.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rest/rest_service.rb +5 -0
- data/lib/sample_core_api.rb +2 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 35989ac6301e28ff1dc5ac09f844a9d6e8c448b01ffe5264a1e6d2c432e20c81
|
4
|
+
data.tar.gz: 10eb03d98e8f62476c64c9b90f2496e812c87e77cbac1f995a777a31c6efba46
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 764052388b727bb099eff96b71855b1901128e1145751cdd5a383d5780aac954d5b1be8c1cdfec4e8d4d0213b3bf6ac1018c51ebdc62c3125702c39546960dd4
|
7
|
+
data.tar.gz: 1e886387bef21644bea8e044d8718645d7cce82de1779803bc39172306f7af8f917e076e83917c8885be1952d860a90a9c2d2111b7aa42c4f1a6b8d01f84a462
|
data/lib/rest/rest_service.rb
CHANGED
@@ -29,6 +29,11 @@ class RestService < RestApplication
|
|
29
29
|
extend ::RestConfiguration
|
30
30
|
extend ::RestResponseModel
|
31
31
|
|
32
|
+
before '/*' do
|
33
|
+
puts 'before any route ...'
|
34
|
+
RequestStore.store[:user] = "Nhuan Lai"
|
35
|
+
end
|
36
|
+
|
32
37
|
# Health Check for Consul, run when start Consul
|
33
38
|
def self.start_consul_check_http(url)
|
34
39
|
get url do
|
data/lib/sample_core_api.rb
CHANGED
@@ -5,6 +5,8 @@ require 'request_store'
|
|
5
5
|
require_relative 'application_configuration'
|
6
6
|
require_relative 'app_service'
|
7
7
|
require_relative 'rest/rest_service'
|
8
|
+
require_relative 'decoractors/authenticate'
|
9
|
+
require_relative 'decoractors/valid'
|
8
10
|
# Dir["#{File.dirname(__FILE__)}/**/*.rb"].each {|file| require file }
|
9
11
|
|
10
12
|
|