faastruby-rpc 0.2.2 → 0.2.3
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 +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/faastruby-rpc/function.rb +6 -2
- data/lib/faastruby-rpc/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 383470c554e6aa94b4735e03ed92d06d1b77cbc6dc47ed3c275e48b9d3674a3a
|
|
4
|
+
data.tar.gz: 82348f64c96d71bd23e9d7b1da964ac393a46bbf91c75fe93410f9469192d037
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 444b6b1aaa348adb6cb575d9e9d1ca1bef07cd9a927812dc10b9f055b73cfe7d23c3678d3e7e6c36d7e4b2dd5caa5bb35fd0bb648c6d37bae7cad89b9a58aa78
|
|
7
|
+
data.tar.gz: b95350721e8390ba5e6a1e6f900c3d6fa3f198efe909e3c08882eb66e848cf1eb84e4decff435da71304e56ee0c0681a4fe2521dd9c9307b73c2ff66c9235372
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
module FaaStRuby
|
|
2
|
-
FAASTRUBY_WORKSPACE_BASE_HOST = ENV['FAASTRUBY_WORKSPACE_BASE_HOST']
|
|
3
2
|
module RPC
|
|
4
3
|
class ExecutionError < StandardError
|
|
5
4
|
end
|
|
@@ -16,6 +15,11 @@ module FaaStRuby
|
|
|
16
15
|
end
|
|
17
16
|
end
|
|
18
17
|
class Function
|
|
18
|
+
@@region = ENV['REGION']
|
|
19
|
+
@@endpoint_base_host = ENV['ENDPOINT_BASE_HOST']
|
|
20
|
+
def self.workspace=(workspace)
|
|
21
|
+
@@workspace = workspace
|
|
22
|
+
end
|
|
19
23
|
def initialize(path, raise_errors: true)
|
|
20
24
|
@response = nil
|
|
21
25
|
@path = path
|
|
@@ -38,7 +42,7 @@ module FaaStRuby
|
|
|
38
42
|
end
|
|
39
43
|
|
|
40
44
|
def get_endpoint(query_params)
|
|
41
|
-
return "https://#{
|
|
45
|
+
return "https://#{@@workspace}.#{@@region}.#{@@endpoint_base_host}/#{@path}#{query_params}" if @@endpoint_base_host && @@region && @@workspace
|
|
42
46
|
return "http://localhost:3000/#{@path}#{query_params}"
|
|
43
47
|
end
|
|
44
48
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: faastruby-rpc
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Paulo Arruda
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2019-03-
|
|
11
|
+
date: 2019-03-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: oj
|