ocean-rails 6.0.0 → 6.0.1

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/ocean/api.rb +20 -16
  3. data/lib/ocean/version.rb +1 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d044bc337f03486f319acad37b8bb5bae323d47e
4
- data.tar.gz: 3e52e7a21755ce16625b703b523250afaf4b8b6c
3
+ metadata.gz: 5b293b0bc6aea7b3f4dfb8be54347c3bc4edc4ab
4
+ data.tar.gz: d9bc449a6991f8da2d6190e21843ae8a9dae7a5e
5
5
  SHA512:
6
- metadata.gz: c3683f1df8ccb04a8d4f52203d49b08c4b769cae8ad3ce223eb32cae24ce5d33823cdc70b7844e83533679ec8b84a759fd825c80c0fbc03d13e013f59263de3f
7
- data.tar.gz: afd88531c431f62c13a3009dada64c26dc3a119c2fe5250acc26ffd8939d809b1524615bdf82c58ca373df7e37340e679fa9b05e5e0ff544e4acf89e8d3bc827
6
+ metadata.gz: f519f38524ec7a2d2b60558e30ba9c0c3e1077e3c1f5abd5ee2eacc7600c3efdb0c1e45af279e95101d6aa2a0e32b4e58937297e2a1b8d832c4cf5b9f5f62dd9
7
+ data.tar.gz: 14da6157c34aa3031ee4399674d22c6618e2ed3ecbb0b5c50aa1932396918694010a9649f04f8bfd0778fd74cb319c0d266d59c253dea8d635515d77a9380157
@@ -517,22 +517,6 @@ 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
-
536
520
  #
537
521
  # Constructs a hash suitable as the body of a POST to async_jobs. It lets you set
538
522
  # all the allowed attributes, and it also provides a terse shortcut for one-step
@@ -604,4 +588,24 @@ class Api
604
588
  block.call e
605
589
  end
606
590
 
591
+
592
+ #
593
+ # Raise a semaphore by making an internal request to the Cloud service.
594
+ # +level+ - Severity level. One of INFO, WARNING, ERROR, and ALERT. Must be in uppercase.
595
+ # +area+ - The area of functionality to which the semaphore belongs, such as "EC2" or "Login". The value is arbitrary.
596
+ # +name+ - The name or ID of the semaphore. The value is arbitrary.
597
+ # +description+ - An optional description.
598
+ #
599
+ def self.raise_semaphore(level, area, name, description: nil)
600
+ run_async_job "/v1/semaphores", :post,
601
+ body: {
602
+ level: level,
603
+ area: area,
604
+ name: name,
605
+ description: description
606
+ }#.to_json
607
+ end
608
+
609
+
610
+
607
611
  end
@@ -1,3 +1,3 @@
1
1
  module Ocean
2
- VERSION = "6.0.0"
2
+ VERSION = "6.0.1"
3
3
  end
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: 6.0.0
4
+ version: 6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Bengtson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-16 00:00:00.000000000 Z
11
+ date: 2016-05-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus