aliyun 0.3.0 → 0.3.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 805a759b4575f23be67e18372e06c5c66d487ace
4
- data.tar.gz: 9c14c17f044ad1f047c8bc2fa202ab3298ab5b58
3
+ metadata.gz: 2dc5e0595cf65cbc2bf6d43fa1332f025143be87
4
+ data.tar.gz: cd067473afc476ba9c400787c7ce65943c162c7e
5
5
  SHA512:
6
- metadata.gz: 06eae905ebdf489de03547cef5d7636f99ab94c546822328f18c42ce43c3dfb767fde74ec43583a01185bac0abdb2b3851c6df7c704b1fc4e7ba845aa4b68124
7
- data.tar.gz: 2bd6e052e61ccc33911e03a5603c62f687de84d6e9b98230d40c7ff9022d72c4fad3c8567f98c935ae1d7ebdad51d4bc9949c85e1e7cf376db989e5dfc05f7d3
6
+ metadata.gz: fa762f088fb80c27b196f2e65e7b8e3f3c3971eb6045fce149710e614b910f3ec64f5b5b87b860fd4a0a1c003c60728c524d2a8fe98c9082bc33a1604e0b327a
7
+ data.tar.gz: 336643ed67cbacfe091043cd0999938e6459c4430f048bf645854351bbad2a0a187a904ec51640db93d98ed1efe06a32944e0f0303bca74b78a0424a23cb2056
@@ -45,8 +45,32 @@ module Aliyun
45
45
  end
46
46
  end
47
47
 
48
+ class RDSConfig < APIConfig
49
+ def self.info
50
+ "Aliyu RDS Service"
51
+ end
52
+ def self.endpoint
53
+ 'https://rds.aliyuncs.com/'
54
+ end
55
+ def self.default_parameters
56
+ {
57
+ :Format=>"JSON",
58
+ :Version=>"2014-08-15",
59
+ :SignatureMethod=>"HMAC-SHA1",
60
+ :SignatureVersion=>"1.0"
61
+ }
62
+ end
63
+ def self.separator
64
+ super
65
+ end
66
+ def self.http_method
67
+ super
68
+ end
69
+ end
70
+
48
71
  SERVICES = {
49
72
  :ecs => ECSConfig,
50
- :slb => SLBConfig
73
+ :slb => SLBConfig,
74
+ :rds => RDSConfig
51
75
  }
52
76
  end
@@ -1,3 +1,3 @@
1
1
  module Aliyun
2
- VERSION = "0.3.0"
2
+ VERSION = "0.3.1"
3
3
  end
@@ -30,6 +30,15 @@ describe Aliyun do
30
30
  expect(service.service).to be(Aliyun::SLBConfig)
31
31
  end
32
32
 
33
+ it 'can create aliyun rds service' do
34
+ options = load_options
35
+ options[:service] = :rds
36
+ service = Aliyun::Service.new options
37
+
38
+ expect(service).to be_instance_of(Aliyun::Service)
39
+ expect(service.service).to be(Aliyun::RDSConfig)
40
+ end
41
+
33
42
  it 'can query aliyun ecs regions' do
34
43
  options = load_options
35
44
  options[:service] = :ecs
@@ -52,6 +61,17 @@ describe Aliyun do
52
61
  expect(regions["Regions"]).to have_key("Region")
53
62
  end
54
63
 
64
+ it 'can query aliyun rds regions' do
65
+ options = load_options
66
+ options[:service] = :rds
67
+ service = Aliyun::Service.new options
68
+ parameters = {}
69
+ regions = service.DescribeRegions parameters
70
+
71
+ expect(regions).to have_key("Regions")
72
+ expect(regions["Regions"]).to have_key("RDSRegion")
73
+ end
74
+
55
75
  it "can describe aliyun slb regions" do
56
76
  options = load_options
57
77
  options[:service] = :slb
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aliyun
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Liu Lantao