ocean-rails 5.5.5 → 5.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ocean/api.rb +16 -0
- data/lib/ocean/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28fc3fe87d46aa6a8fef90e97666eecbb0374e6d
|
4
|
+
data.tar.gz: ba0a331acd12c986d47adb3c79f4d1e77e058756
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6f6790a906a3ff973f6b50ecfb75c860e1c5a9939999bda54b7720906611a6cabb223b6f32aa81b756122e060ab8e130bcf531d99b4dcef75854062c013bbd0
|
7
|
+
data.tar.gz: 4f729097a080810b7f1b9983c07fce31f7e30297e0d91e67afa83b9460431c2b67fbfdd71070b1f561f0d0e30f74be99e0add4e7a715100586c188cb0e742e59
|
data/lib/ocean/api.rb
CHANGED
@@ -517,6 +517,22 @@ class Api
|
|
517
517
|
end
|
518
518
|
|
519
519
|
|
520
|
+
#
|
521
|
+
# Raise a semaphore by making an internal request to the Cloud service.
|
522
|
+
# +level+ - Severity level. One of INFO, WARNING, ERROR, and ALERT. Must be in uppercase.
|
523
|
+
# +area+ - The area of functionality to which the semaphore belongs, such as "EC2". The value is arbitrary.
|
524
|
+
# +name+ - The name or ID of the semaphore. The value is arbitrary.
|
525
|
+
# +description+ - An optional description.
|
526
|
+
#
|
527
|
+
def self.raise_semaphore(level, area, name, description: nil)
|
528
|
+
Api.request "/v1/semaphores", :post,
|
529
|
+
x_api_token: Api.service_token, credentials: Api.credentials,
|
530
|
+
body: {
|
531
|
+
level: level, area: area, name: name, description: description
|
532
|
+
}.to_json
|
533
|
+
end
|
534
|
+
|
535
|
+
|
520
536
|
#
|
521
537
|
# Constructs a hash suitable as the body of a POST to async_jobs. It lets you set
|
522
538
|
# all the allowed attributes, and it also provides a terse shortcut for one-step
|
data/lib/ocean/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ocean-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Bengtson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|