poolparty 1.4.6 → 1.4.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. data/VERSION.yml +2 -2
  2. data/bin/cloud-contract +6 -1
  3. data/bin/cloud-list +5 -6
  4. data/bin/cloud-vnc +39 -0
  5. data/examples/rds_cloud.rb +44 -0
  6. data/lib/cloud_providers/connections.rb +0 -1
  7. data/lib/cloud_providers/ec2/ec2.rb +86 -25
  8. data/lib/cloud_providers/ec2/ec2_instance.rb +6 -2
  9. data/lib/cloud_providers/ec2/helpers/ec2_helper.rb +19 -6
  10. data/lib/cloud_providers/ec2/helpers/elastic_load_balancer.rb +3 -3
  11. data/lib/cloud_providers/ec2/helpers/rds_instance.rb +110 -0
  12. data/lib/cloud_providers/remote_instance.rb +5 -3
  13. data/lib/poolparty/cloud.rb +8 -3
  14. data/lib/poolparty/pool.rb +12 -0
  15. data/test/fixtures/clouds/rds_cloud.rb +14 -0
  16. data/test/fixtures/clouds/rds_missing_params.rb +11 -0
  17. data/test/fixtures/ec2/ec2-describe-security-groups_response_body.xml +23 -0
  18. data/test/fixtures/ec2/rds-describe-db-instances-empty_response_body.xml +9 -0
  19. data/test/lib/poolparty/rds_test.rb +35 -0
  20. data/test/test_helper.rb +4 -4
  21. data/vendor/gems/amazon-ec2/ChangeLog +15 -0
  22. data/vendor/gems/amazon-ec2/README.rdoc +27 -24
  23. data/vendor/gems/amazon-ec2/README_dev.rdoc +0 -2
  24. data/vendor/gems/amazon-ec2/Rakefile +8 -39
  25. data/vendor/gems/amazon-ec2/VERSION +1 -1
  26. data/vendor/gems/amazon-ec2/amazon-ec2.gemspec +24 -16
  27. data/vendor/gems/amazon-ec2/bin/setup.rb +1 -0
  28. data/vendor/gems/amazon-ec2/lib/AWS/Autoscaling/autoscaling.rb +6 -16
  29. data/vendor/gems/amazon-ec2/lib/AWS/EC2/availability_zones.rb +8 -0
  30. data/vendor/gems/amazon-ec2/lib/AWS/EC2/console.rb +2 -0
  31. data/vendor/gems/amazon-ec2/lib/AWS/EC2/devpay.rb +18 -0
  32. data/vendor/gems/amazon-ec2/lib/AWS/EC2/elastic_ips.rb +37 -32
  33. data/vendor/gems/amazon-ec2/lib/AWS/EC2/images.rb +43 -27
  34. data/vendor/gems/amazon-ec2/lib/AWS/EC2/instances.rb +136 -99
  35. data/vendor/gems/amazon-ec2/lib/AWS/EC2/keypairs.rb +3 -17
  36. data/vendor/gems/amazon-ec2/lib/AWS/EC2/security_groups.rb +4 -23
  37. data/vendor/gems/amazon-ec2/lib/AWS/EC2/snapshots.rb +38 -17
  38. data/vendor/gems/amazon-ec2/lib/AWS/EC2/volumes.rb +6 -21
  39. data/vendor/gems/amazon-ec2/lib/AWS/EC2.rb +2 -2
  40. data/vendor/gems/amazon-ec2/lib/AWS/ELB/load_balancers.rb +11 -38
  41. data/vendor/gems/amazon-ec2/lib/AWS/RDS/rds.rb +522 -0
  42. data/vendor/gems/amazon-ec2/lib/AWS/RDS.rb +73 -0
  43. data/vendor/gems/amazon-ec2/lib/AWS/exceptions.rb +103 -25
  44. data/vendor/gems/amazon-ec2/lib/AWS.rb +19 -9
  45. data/vendor/gems/amazon-ec2/perftools/ec2prof +0 -0
  46. data/vendor/gems/amazon-ec2/perftools/ec2prof-results.dot +130 -191
  47. data/vendor/gems/amazon-ec2/perftools/ec2prof-results.txt +100 -126
  48. data/vendor/gems/amazon-ec2/perftools/ec2prof.symbols +102 -129
  49. data/vendor/gems/amazon-ec2/test/test_Autoscaling_groups.rb +3 -2
  50. data/vendor/gems/amazon-ec2/test/test_EC2_images.rb +32 -0
  51. data/vendor/gems/amazon-ec2/test/test_EC2_instances.rb +204 -22
  52. data/vendor/gems/amazon-ec2/test/test_EC2_snapshots.rb +1 -1
  53. data/vendor/gems/amazon-ec2/test/test_ELB_load_balancers.rb +2 -2
  54. data/vendor/gems/amazon-ec2/test/test_RDS.rb +354 -0
  55. data/vendor/gems/amazon-ec2/wsdl/2009-10-31.ec2.wsdl +4261 -0
  56. data/vendor/gems/amazon-ec2/wsdl/2009-11-30.ec2.wsdl +4668 -0
  57. metadata +17 -2
@@ -1,126 +1,100 @@
1
- Total: 2178 samples
2
- 352 16.2% 16.2% 352 16.2% garbage_collector
3
- 162 7.4% 23.6% 462 21.2% REXML::Parsers::BaseParser#pull
4
- 123 5.6% 29.2% 166 7.6% REXML::Source#match
5
- 102 4.7% 33.9% 102 4.7% REXML::Element#root
6
- 80 3.7% 37.6% 146 6.7% Object#find
7
- 80 3.7% 41.3% 140 6.4% REXML::Document#doctype
8
- 79 3.6% 44.9% 95 4.4% REXML::Parent#add
9
- 55 2.5% 47.4% 73 3.4% REXML::Parsers::BaseParser#empty?
10
- 50 2.3% 49.7% 101 4.6% REXML::Child#find_all
11
- 49 2.2% 52.0% 72 3.3% REXML::Child#find
12
- 47 2.2% 54.1% 153 7.0% REXML::Element#add_element
13
- 46 2.1% 56.2% 110 5.1% REXML::Element#texts
14
- 45 2.1% 58.3% 46 2.1% Set#initialize
15
- 43 2.0% 60.3% 43 2.0% Regexp#match
16
- 38 1.7% 62.0% 38 1.7% REXML::Text.unnormalize
17
- 33 1.5% 63.5% 233 10.7% XmlSimple#node_to_text
18
- 33 1.5% 65.1% 33 1.5% XmlSimple#empty
19
- 32 1.5% 66.5% 33 1.5% REXML::Text#initialize
20
- 29 1.3% 67.9% 30 1.4% XmlSimple#force_array?
21
- 27 1.2% 69.1% 83 3.8% REXML::Elements#empty?
22
- 27 1.2% 70.3% 40 1.8% REXML::XPathParser#expr
23
- 25 1.1% 71.5% 25 1.1% REXML::Child#parent=
24
- 24 1.1% 72.6% 24 1.1% REXML::Parent#[]
25
- 24 1.1% 73.7% 970 44.5% REXML::Elements#each
26
- 24 1.1% 74.8% 970 44.5% XmlSimple#collapse
27
- 22 1.0% 75.8% 56 2.6% XmlSimple#get_attributes
28
- 22 1.0% 76.8% 263 12.1% REXML::Element#has_text?
29
- 22 1.0% 77.8% 22 1.0% REXML::Text#to_s
30
- 22 1.0% 78.8% 22 1.0% REXML::Element#whitespace
31
- 22 1.0% 79.8% 42 1.9% REXML::Element#get_text
32
- 21 1.0% 80.8% 155 7.1% REXML::Parent#each
33
- 20 0.9% 81.7% 97 4.5% REXML::Element#initialize
34
- 19 0.9% 82.6% 121 5.6% REXML::Element#document
35
- 18 0.8% 83.4% 18 0.8% REXML::Source#empty?
36
- 18 0.8% 84.3% 107 4.9% REXML::Elements#add
37
- 18 0.8% 85.1% 21 1.0% XmlSimple#fold_arrays
38
- 17 0.8% 85.9% 316 14.5% REXML::Text#value
39
- 16 0.7% 86.6% 34 1.6% REXML::Attributes#each
40
- 14 0.6% 87.2% 241 11.1% REXML::Element#text
41
- 14 0.6% 87.9% 14 0.6% REXML::Parent#name=
42
- 13 0.6% 88.5% 13 0.6% OpenSSL::SSL::SSLSocket#sysread
43
- 13 0.6% 89.1% 13 0.6% REXML::Attributes#initialize
44
- 12 0.6% 89.6% 95 4.4% REXML::Element#has_elements?
45
- 12 0.6% 90.2% 12 0.6% REXML::Element#ignore_whitespace_nodes
46
- 11 0.5% 90.7% 268 12.3% XmlSimple#collapse_text_node
47
- 11 0.5% 91.2% 15 0.7% Set#each
48
- 11 0.5% 91.7% 11 0.5% REXML::Elements#initialize
49
- 11 0.5% 92.2% 12 0.6% Kernel#gem_original_require
50
- 10 0.5% 92.7% 10 0.5% Hash#each_value
51
- 10 0.5% 93.1% 19 0.9% REXML::Parent#<<
52
- 10 0.5% 93.6% 10 0.5% REXML::Element#has_attributes?
53
- 8 0.4% 93.9% 18 0.8% REXML::Attributes#each_attribute
54
- 8 0.4% 94.3% 8 0.4% REXML::Element#node_type
55
- 7 0.3% 94.6% 9 0.4% Thread.start
56
- 7 0.3% 94.9% 37 1.7% XmlSimple#merge
57
- 7 0.3% 95.3% 12 0.6% REXML::Parsers::XPathParser#RelativeLocationPath
58
- 6 0.3% 95.5% 39 1.8% REXML::Parent#initialize
59
- 6 0.3% 95.8% 22 1.0% REXML::Parsers::XPathParser#UnionExpr
60
- 5 0.2% 96.1% 20 0.9% Hash#each
61
- 5 0.2% 96.3% 33 1.5% REXML::Child#initialize
62
- 5 0.2% 96.5% 108 5.0% XmlSimple#has_mixed_content?
63
- 5 0.2% 96.7% 35 1.6% REXML::Parsers::XPathParser#RelationalExpr
64
- 5 0.2% 97.0% 30 1.4% REXML::Parsers::XPathParser#AdditiveExpr
65
- 5 0.2% 97.2% 5 0.2% REXML::Parsers::XPathParser#NodeTest
66
- 4 0.2% 97.4% 4 0.2% REXML::Text#node_type
67
- 4 0.2% 97.6% 4 0.2% Hash#each_key
68
- 3 0.1% 97.7% 3 0.1% Thread#kill
69
- 3 0.1% 97.8% 44 2.0% REXML::Parsers::XPathParser#OrExpr
70
- 3 0.1% 98.0% 38 1.7% REXML::Parsers::XPathParser#EqualityExpr
71
- 3 0.1% 98.1% 41 1.9% REXML::Parsers::XPathParser#AndExpr
72
- 2 0.1% 98.2% 16 0.7% REXML::Parsers::XPathParser#PathExpr
73
- 2 0.1% 98.3% 24 1.1% REXML::Parsers::XPathParser#UnaryExpr
74
- 2 0.1% 98.4% 2 0.1% Object#sleep
75
- 2 0.1% 98.5% 2 0.1% String#slice!
76
- 2 0.1% 98.6% 2 0.1% REXML::Parsers::XPathParser#FilterExpr
77
- 2 0.1% 98.7% 4 0.2% Net::BufferedIO#rbuf_consume
78
- 2 0.1% 98.8% 42 1.9% REXML::XPathParser#match
79
- 2 0.1% 98.9% 3 0.1% REXML::XPathParser#variables=
80
- 1 0.0% 98.9% 1 0.0% REXML::Element#context=
81
- 1 0.0% 98.9% 25 1.1% REXML::Parsers::XPathParser#MultiplicativeExpr
82
- 1 0.0% 99.0% 1 0.0% Hash#[]
83
- 1 0.0% 99.0% 1 0.0% String#=~
84
- 1 0.0% 99.1% 804 36.9% Class#new
85
- 1 0.0% 99.1% 27 1.2% Timeout.timeout
86
- 1 0.0% 99.2% 970 44.5% REXML::Element#each_element
87
- 1 0.0% 99.2% 32 1.5% Net::BufferedIO#read
88
- 1 0.0% 99.3% 1 0.0% REXML::Parent#children
89
- 1 0.0% 99.3% 1 0.0% REXML::Functions.variables=
90
- 1 0.0% 99.4% 27 1.2% Net::BufferedIO#rbuf_fill
91
- 1 0.0% 99.4% 1 0.0% String#<<
92
- 1 0.0% 99.4% 1 0.0% Object#DelegateClass
93
- 1 0.0% 99.5% 1 0.0% REXML::Functions.namespace_context=
94
- 1 0.0% 99.5% 13 0.6% Object#require
95
- 1 0.0% 99.6% 970 44.5% REXML::XPath.each
96
- 1 0.0% 99.6% 2 0.1% Net::BufferedIO#readuntil
97
- 0 0.0% 99.6% 32 1.5% Net::HTTPResponse#read_body_0
98
- 0 0.0% 99.6% 44 2.0% REXML::Parsers::XPathParser#parse
99
- 0 0.0% 99.6% 32 1.5% Net::HTTPResponse#read_chunked
100
- 0 0.0% 99.6% 12 0.6% REXML::Parsers::XPathParser#LocationPath
101
- 0 0.0% 99.6% 152 7.0% Array#map
102
- 0 0.0% 99.6% 945 43.4% AWS::EC2::Base#response_generator
103
- 0 0.0% 99.6% 1 0.0% Net::HTTPResponse.read_status_line
104
- 0 0.0% 99.6% 34 1.6% Net::HTTP#request
105
- 0 0.0% 99.6% 275 12.6% Array#each
106
- 0 0.0% 99.6% 801 36.8% REXML::Parsers::TreeParser#parse
107
- 0 0.0% 99.6% 993 45.6% XmlSimple.xml_in
108
- 0 0.0% 99.6% 32 1.5% Net::HTTPResponse#read_body
109
- 0 0.0% 99.6% 32 1.5% Net::HTTPResponse#reading_body
110
- 0 0.0% 99.6% 1 0.0% Net::HTTPResponse.each_response_header
111
- 0 0.0% 99.6% 801 36.8% REXML::Document#build
112
- 0 0.0% 99.6% 34 1.6% AWS::EC2::Base#make_request
113
- 0 0.0% 99.6% 32 1.5% Net::HTTPResponse#body
114
- 0 0.0% 99.6% 32 1.5% Array#delete_if
115
- 0 0.0% 99.6% 1 0.0% REXML::XPathParser#namespaces=
116
- 0 0.0% 99.6% 34 1.6% Net::HTTP#start
117
- 0 0.0% 99.6% 1113 51.1% XmlSimple#xml_in
118
- 0 0.0% 99.6% 27 1.2% Object#timeout
119
- 0 0.0% 99.6% 801 36.8% XmlSimple#parse
120
- 0 0.0% 99.6% 918 42.1% AWS::EC2::Base#describe_images
121
- 0 0.0% 99.6% 934 42.9% AWS::Response.parse
122
- 0 0.0% 99.6% 801 36.8% REXML::Document#initialize
123
- 0 0.0% 99.6% 22 1.0% Array#join
124
- 0 0.0% 99.6% 1 0.0% Net::BufferedIO#readline
125
- 0 0.0% 99.6% 2 0.1% Net::HTTPResponse.read_new
126
- 0 0.0% 99.6% 86 3.9% REXML::XPathParser#parse
1
+ Total: 2043 samples
2
+ 1298 63.5% 63.5% 1298 63.5% garbage_collector
3
+ 142 7.0% 70.5% 371 18.2% Class#new
4
+ 65 3.2% 73.7% 355 17.4% REXML::Parsers::TreeParser#parse
5
+ 50 2.4% 76.1% 54 2.6% REXML::Child#find
6
+ 45 2.2% 78.3% 338 16.5% XmlSimple#collapse
7
+ 44 2.2% 80.5% 44 2.2% REXML::Source#match
8
+ 37 1.8% 82.3% 40 2.0% REXML::Child#find_all
9
+ 20 1.0% 83.3% 97 4.7% XmlSimple#collapse_text_node
10
+ 19 0.9% 84.2% 74 3.6% REXML::Text#value
11
+ 18 0.9% 85.1% 81 4.0% REXML::Element#initialize
12
+ 18 0.9% 86.0% 18 0.9% REXML::Element#root
13
+ 17 0.8% 86.8% 22 1.1% REXML::Parent#initialize
14
+ 17 0.8% 87.6% 19 0.9% REXML::Text#initialize
15
+ 16 0.8% 88.4% 18 0.9% REXML::Text.unnormalize
16
+ 14 0.7% 89.1% 370 18.1% REXML::Document#build
17
+ 14 0.7% 89.8% 107 5.2% REXML::Parsers::BaseParser#pull
18
+ 13 0.6% 90.4% 14 0.7% Net::BufferedIO#rbuf_fill
19
+ 13 0.6% 91.0% 21 1.0% XmlSimple#merge
20
+ 11 0.5% 91.6% 29 1.4% REXML::Element#document
21
+ 11 0.5% 92.1% 338 16.5% REXML::Elements#each
22
+ 9 0.4% 92.6% 9 0.4% REXML::Parent#name=
23
+ 8 0.4% 93.0% 8 0.4% REXML::Parent#add
24
+ 8 0.4% 93.3% 8 0.4% XmlSimple#force_array?
25
+ 7 0.3% 93.7% 33 1.6% Array#each
26
+ 6 0.3% 94.0% 9 0.4% Kernel#gem_original_require
27
+ 6 0.3% 94.3% 10 0.5% Object#find
28
+ 6 0.3% 94.6% 76 3.7% XmlSimple#node_to_text
29
+ 5 0.2% 94.8% 19 0.9% Net::BufferedIO#read
30
+ 5 0.2% 95.1% 338 16.5% REXML::Element#each_element
31
+ 5 0.2% 95.3% 52 2.5% REXML::Element#text
32
+ 5 0.2% 95.5% 45 2.2% REXML::Element#texts
33
+ 5 0.2% 95.8% 6 0.3% REXML::Parsers::BaseParser#empty?
34
+ 4 0.2% 96.0% 4 0.2% Hash#[]
35
+ 4 0.2% 96.2% 4 0.2% Object#clone
36
+ 4 0.2% 96.4% 15 0.7% REXML::Parsers::XPathParser#parse
37
+ 4 0.2% 96.6% 338 16.5% REXML::XPath.each
38
+ 4 0.2% 96.8% 6 0.3% XmlSimple#get_attributes
39
+ 3 0.1% 96.9% 6 0.3% Array#delete_if
40
+ 3 0.1% 97.1% 3 0.1% Hash#each
41
+ 3 0.1% 97.2% 55 2.7% REXML::Element#has_text?
42
+ 3 0.1% 97.4% 7 0.3% REXML::XPathParser#expr
43
+ 3 0.1% 97.5% 29 1.4% XmlSimple#has_mixed_content?
44
+ 2 0.1% 97.6% 36 1.8% Array#map
45
+ 2 0.1% 97.7% 9 0.4% Object#require
46
+ 2 0.1% 97.8% 5 0.2% REXML::Child#initialize
47
+ 2 0.1% 97.9% 8 0.4% REXML::Document#doctype
48
+ 2 0.1% 98.0% 94 4.6% REXML::Element#add_element
49
+ 2 0.1% 98.1% 3 0.1% REXML::Element#get_text
50
+ 2 0.1% 98.2% 3 0.1% REXML::Element#whitespace
51
+ 2 0.1% 98.3% 92 4.5% REXML::Elements#add
52
+ 2 0.1% 98.4% 55 2.7% REXML::Elements#empty?
53
+ 2 0.1% 98.5% 2 0.1% REXML::Parent#<<
54
+ 2 0.1% 98.6% 16 0.8% REXML::Parent#each
55
+ 2 0.1% 98.7% 9 0.4% REXML::Parsers::XPathParser#AdditiveExpr
56
+ 2 0.1% 98.8% 2 0.1% REXML::Parsers::XPathParser#FilterExpr
57
+ 2 0.1% 98.9% 7 0.3% REXML::Parsers::XPathParser#MultiplicativeExpr
58
+ 2 0.1% 99.0% 11 0.5% REXML::Parsers::XPathParser#OrExpr
59
+ 2 0.1% 99.1% 5 0.2% REXML::Parsers::XPathParser#UnionExpr
60
+ 2 0.1% 99.2% 22 1.1% Set#initialize
61
+ 1 0.0% 99.2% 1 0.0% Array#join
62
+ 1 0.0% 99.3% 1 0.0% Net::BufferedIO#readline
63
+ 1 0.0% 99.3% 1 0.0% REXML::Attributes#each_attribute
64
+ 1 0.0% 99.4% 1 0.0% REXML::Parsers::XPathParser#RelativeLocationPath
65
+ 1 0.0% 99.4% 1 0.0% REXML::Source#empty?
66
+ 1 0.0% 99.5% 1 0.0% REXML::Source#initialize
67
+ 1 0.0% 99.5% 8 0.4% REXML::XPathParser#match
68
+ 1 0.0% 99.6% 1 0.0% REXML::XPathParser#variables=
69
+ 1 0.0% 99.6% 14 0.7% Timeout.timeout
70
+ 0 0.0% 99.6% 20 1.0% AWS::Base#make_request
71
+ 0 0.0% 99.6% 431 21.1% AWS::Base#response_generator
72
+ 0 0.0% 99.6% 422 20.7% AWS::EC2::Base#describe_images
73
+ 0 0.0% 99.6% 442 21.6% AWS::Response.parse
74
+ 0 0.0% 99.6% 20 1.0% Net::HTTP#request
75
+ 0 0.0% 99.6% 20 1.0% Net::HTTP#start
76
+ 0 0.0% 99.6% 20 1.0% Net::HTTPResponse#body
77
+ 0 0.0% 99.6% 20 1.0% Net::HTTPResponse#read_body
78
+ 0 0.0% 99.6% 20 1.0% Net::HTTPResponse#read_body_0
79
+ 0 0.0% 99.6% 20 1.0% Net::HTTPResponse#read_chunked
80
+ 0 0.0% 99.6% 20 1.0% Net::HTTPResponse#reading_body
81
+ 0 0.0% 99.6% 14 0.7% Object#timeout
82
+ 0 0.0% 99.6% 1 0.0% REXML::Attributes#each
83
+ 0 0.0% 99.6% 370 18.1% REXML::Document#initialize
84
+ 0 0.0% 99.6% 55 2.7% REXML::Element#has_elements?
85
+ 0 0.0% 99.6% 1 0.0% REXML::Element#ignore_whitespace_nodes
86
+ 0 0.0% 99.6% 1 0.0% REXML::Parsers::BaseParser#initialize
87
+ 0 0.0% 99.6% 1 0.0% REXML::Parsers::BaseParser#stream=
88
+ 0 0.0% 99.6% 1 0.0% REXML::Parsers::TreeParser#initialize
89
+ 0 0.0% 99.6% 9 0.4% REXML::Parsers::XPathParser#AndExpr
90
+ 0 0.0% 99.6% 9 0.4% REXML::Parsers::XPathParser#EqualityExpr
91
+ 0 0.0% 99.6% 1 0.0% REXML::Parsers::XPathParser#LocationPath
92
+ 0 0.0% 99.6% 3 0.1% REXML::Parsers::XPathParser#PathExpr
93
+ 0 0.0% 99.6% 9 0.4% REXML::Parsers::XPathParser#RelationalExpr
94
+ 0 0.0% 99.6% 5 0.2% REXML::Parsers::XPathParser#UnaryExpr
95
+ 0 0.0% 99.6% 1 0.0% REXML::SourceFactory.create_from
96
+ 0 0.0% 99.6% 23 1.1% REXML::XPathParser#parse
97
+ 0 0.0% 99.6% 3 0.1% XmlSimple#fold_arrays
98
+ 0 0.0% 99.6% 370 18.1% XmlSimple#parse
99
+ 0 0.0% 99.6% 507 24.8% XmlSimple#xml_in
100
+ 0 0.0% 99.6% 469 23.0% XmlSimple.xml_in
@@ -1,129 +1,102 @@
1
- 001414dd: garbage_collector
2
- 0121a9e3: REXML::Elements#empty?
3
- 01222643: REXML::Element#has_elements?
4
- 01124a59: XmlSimple#collapse
5
- 0121a7f5: REXML::Elements#each
6
- 024522b5: REXML::XPath.each
7
- 01222665: REXML::Element#each_element
8
- 011249a9: XmlSimple#xml_in
9
- 0223eb95: XmlSimple.xml_in
10
- 022884f1: AWS::Response.parse
11
- 011ba34d: AWS::EC2::Base#response_generator
12
- 011ba17d: AWS::EC2::Base#describe_images
13
- 01124af1: XmlSimple#get_attributes
14
- 012219b1: REXML::Attributes#each_attribute
15
- 01219c51: REXML::Attributes#each
16
- 024ae844: REXML::Functions.namespace_context=
17
- 01222fe8: REXML::XPathParser#namespaces=
18
- 0003e949: Kernel#gem_original_require
19
- 0003c2dd: Object#require
20
- 00033631: Array#each
21
- 01292161: REXML::Child#find
22
- 012a0661: REXML::Parent#each
23
- 01124b0f: XmlSimple#has_mixed_content?
24
- 00033501: Object#find
25
- 0122269d: REXML::Element#get_text
26
- 0121cbd5: REXML::Element#text
27
- 01222663: REXML::Element#has_text?
28
- 012226eb: REXML::Element#has_attributes?
29
- 01124b11: XmlSimple#collapse_text_node
30
- 01219841: REXML::Attributes#initialize
31
- 0003aa21: Class#new
32
- 0121a435: REXML::Element#initialize
33
- 0121ae0d: REXML::Elements#add
34
- 012224f5: REXML::Element#add_element
35
- 011dfd39: REXML::Parsers::TreeParser#parse
36
- 011e0ce1: REXML::Document#build
37
- 011ddb39: REXML::Document#initialize
38
- 0111db71: XmlSimple#parse
39
- 0121a3e5: REXML::Elements#initialize
40
- 024cec3d: REXML::Text.unnormalize
41
- 012642b5: REXML::Text#value
42
- 012639b5: REXML::Text#to_s
43
- 00033bd9: Array#join
44
- 011e5325: Set#initialize
45
- 011ed101: REXML::Parsers::BaseParser#pull
46
- 011e2f01: REXML::Document#doctype
47
- 0050c805: Net::BufferedIO#readuntil
48
- 025a912d: Net::HTTPResponse.each_response_header
49
- 025a8bfd: Net::HTTPResponse.read_new
50
- 012d8c71: Net::HTTP#request
51
- 011ba2e5: AWS::EC2::Base#make_request
52
- 012d4611: Net::HTTP#start
53
- 005067ad: Net::BufferedIO#read
54
- 012d87bd: Net::HTTPResponse#read_chunked
55
- 012d87ad: Net::HTTPResponse#read_body_0
56
- 012d8095: Net::HTTPResponse#read_body
57
- 012d657d: Net::HTTPResponse#body
58
- 012d83a5: Net::HTTPResponse#reading_body
59
- 01124b39: XmlSimple#node_to_text
60
- 00033561: Array#map
61
- 0003878b: String#slice!
62
- 0050c94d: Net::BufferedIO#rbuf_consume
63
- 012243ad: REXML::Parsers::XPathParser#RelativeLocationPath
64
- 012243a5: REXML::Parsers::XPathParser#LocationPath
65
- 01224425: REXML::Parsers::XPathParser#PathExpr
66
- 0122441d: REXML::Parsers::XPathParser#UnionExpr
67
- 01224415: REXML::Parsers::XPathParser#UnaryExpr
68
- 0122440d: REXML::Parsers::XPathParser#MultiplicativeExpr
69
- 01224405: REXML::Parsers::XPathParser#AdditiveExpr
70
- 012243fd: REXML::Parsers::XPathParser#RelationalExpr
71
- 012243f5: REXML::Parsers::XPathParser#EqualityExpr
72
- 012243ed: REXML::Parsers::XPathParser#AndExpr
73
- 01224385: REXML::Parsers::XPathParser#OrExpr
74
- 0121de09: REXML::Parsers::XPathParser#parse
75
- 0121d5d5: REXML::XPathParser#parse
76
- 0122249d: REXML::Element#node_type
77
- 0122390d: REXML::XPathParser#expr
78
- 000340d1: Array#delete_if
79
- 0121b40d: REXML::XPathParser#match
80
- 0126b96d: REXML::Text#node_type
81
- 0121e725: REXML::Element#root
82
- 012224a5: REXML::Element#document
83
- 0122442d: REXML::Parsers::XPathParser#FilterExpr
84
- 012201a8: REXML::Element#context=
85
- 0129b2f1: REXML::Child#initialize
86
- 012a0251: REXML::Parent#initialize
87
- 0003754a: String#<<
88
- 0129f80c: REXML::Parent#[]
89
- 012a0c79: REXML::Parent#add
90
- 01124b19: XmlSimple#fold_arrays
91
- 0003285d: Hash#each
92
- 011e5735: Set#each
93
- 01223788: REXML::XPathParser#variables=
94
- 0122272d: REXML::Element#texts
95
- 01292179: REXML::Child#find_all
96
- 0003c025: Object#sleep
97
- 02369535: Timeout.timeout
98
- 0006c8ed: Thread.start
99
- 0003ef01: Object#timeout
100
- 0050c955: Net::BufferedIO#rbuf_fill
101
- 000333dd: Hash#each_key
102
- 0003faed: Object#DelegateClass
103
- 01124b97: XmlSimple#force_array?
104
- 0111c369: XmlSimple#merge
105
- 012a3384: REXML::Child#parent=
106
- 0129f80e: REXML::Parent#<<
107
- 000333d5: Hash#each_value
108
- 024ae81c: REXML::Functions.variables=
109
- 0110f181: OpenSSL::SSL::SSLSocket#sysread
110
- 012225c5: REXML::Element#whitespace
111
- 012225e5: REXML::Element#ignore_whitespace_nodes
112
- 0126f51f: REXML::Source#empty?
113
- 011e4e47: REXML::Parsers::BaseParser#empty?
114
- 01124b01: XmlSimple#empty
115
- 00037544: String#=~
116
- 01263905: REXML::Text#initialize
117
- 0126f521: REXML::Source#match
118
- 005067f5: Net::BufferedIO#readline
119
- 025a911d: Net::HTTPResponse.read_status_line
120
- 012243bd: REXML::Parsers::XPathParser#NodeTest
121
- 0003187d: Regexp#match
122
- 00031a08: Hash#[]
123
- 012a39d1: REXML::Parent#children
124
- 0121a58c: REXML::Parent#name=
125
- 00059eb8: Dir.[]
126
- 0008623d: Gem::GemPathSearcher#matching_files
127
- 00086923: Gem::GemPathSearcher#matching_file?
128
- 0008439d: Gem::GemPathSearcher#find
129
- 00036ef9: Thread#kill
1
+ 0000000100037f3a: garbage_collector
2
+ 000000010016bbe9: Array#map
3
+ 0000000102818079: XmlSimple#node_to_text
4
+ 0000000102818051: XmlSimple#collapse_text_node
5
+ 0000000102817f99: XmlSimple#collapse
6
+ 00000001028f9eb1: REXML::Elements#each
7
+ 000000020521dbb1: REXML::XPath.each
8
+ 0000000102902299: REXML::Element#each_element
9
+ 000000010017a719: Class#new
10
+ 00000001028a2949: REXML::Parsers::TreeParser#parse
11
+ 00000001028a3f11: REXML::Document#build
12
+ 00000001028a0d39: REXML::Document#initialize
13
+ 0000000102810de1: XmlSimple#parse
14
+ 0000000102817f71: XmlSimple#xml_in
15
+ 0000000205025409: XmlSimple.xml_in
16
+ 0000000204f566d9: AWS::Response.parse
17
+ 00000001028123e1: AWS::Base#response_generator
18
+ 00000001027f30e1: AWS::EC2::Base#describe_images
19
+ 00000001029b0211: REXML::Child#find
20
+ 000000010016bcb9: Array#each
21
+ 00000001029c5ec1: REXML::Parent#each
22
+ 00000001028fa09f: REXML::Elements#empty?
23
+ 0000000102902277: REXML::Element#has_elements?
24
+ 00000001028a6b49: REXML::Document#doctype
25
+ 000000010016bb61: Object#find
26
+ 00000001029655e9: REXML::Text#value
27
+ 000000010017e629: Kernel#gem_original_require
28
+ 000000010017bf71: Object#require
29
+ 00000001029b0229: REXML::Child#find_all
30
+ 0000000102902361: REXML::Element#texts
31
+ 000000010281804f: XmlSimple#has_mixed_content?
32
+ 00000001029011e9: REXML::Attributes#each_attribute
33
+ 00000001028f8f39: REXML::Attributes#each
34
+ 0000000102818031: XmlSimple#get_attributes
35
+ 00000001028fa4c9: REXML::Elements#add
36
+ 0000000102902111: REXML::Element#add_element
37
+ 000000010290476d: REXML::Parsers::XPathParser#AdditiveExpr
38
+ 0000000102904765: REXML::Parsers::XPathParser#RelationalExpr
39
+ 000000010290475d: REXML::Parsers::XPathParser#EqualityExpr
40
+ 0000000102904755: REXML::Parsers::XPathParser#AndExpr
41
+ 00000001029046ed: REXML::Parsers::XPathParser#OrExpr
42
+ 00000001028fdc59: REXML::Parsers::XPathParser#parse
43
+ 00000001028fd169: REXML::XPathParser#parse
44
+ 00000001028aca99: Set#initialize
45
+ 00000001028b46c9: REXML::Parsers::BaseParser#pull
46
+ 00000001029be149: REXML::Child#initialize
47
+ 00000001029c5ab1: REXML::Parent#initialize
48
+ 00000001028f9b19: REXML::Element#initialize
49
+ 000000010016c759: Array#delete_if
50
+ 00000001029039c1: REXML::XPathParser#expr
51
+ 00000001028faf79: REXML::XPathParser#match
52
+ 00000002052d17d9: REXML::Text.unnormalize
53
+ 00000001028fc2e1: REXML::Element#text
54
+ 0000000102902297: REXML::Element#has_text?
55
+ 00000001029c506e: REXML::Parent#<<
56
+ 0000000102964c39: REXML::Text#initialize
57
+ 00000001029c64d9: REXML::Parent#add
58
+ 0000000102a143b9: Net::BufferedIO#read
59
+ 0000000102a15919: Net::HTTPResponse#read_chunked
60
+ 0000000102a15909: Net::HTTPResponse#read_body_0
61
+ 0000000102a15271: Net::HTTPResponse#read_body
62
+ 0000000102a12ad9: Net::HTTPResponse#body
63
+ 0000000102a15521: Net::HTTPResponse#reading_body
64
+ 0000000102a16b19: Net::HTTP#request
65
+ 0000000102811831: AWS::Base#make_request
66
+ 0000000102a125d9: Net::HTTP#start
67
+ 0000000102a14401: Net::BufferedIO#readline
68
+ 0000000102a1b031: Net::BufferedIO#rbuf_fill
69
+ 0000000203164251: Timeout.timeout
70
+ 000000010017ec59: Object#timeout
71
+ 00000001028abec7: REXML::Parsers::BaseParser#empty?
72
+ 0000000102904785: REXML::Parsers::XPathParser#UnionExpr
73
+ 000000010290477d: REXML::Parsers::XPathParser#UnaryExpr
74
+ 0000000102904775: REXML::Parsers::XPathParser#MultiplicativeExpr
75
+ 000000010037eed9: Gem::GemPathSearcher#matching_files
76
+ 000000010037f5cf: Gem::GemPathSearcher#matching_file?
77
+ 000000010037d021: Gem::GemPathSearcher#find
78
+ 000000010017a531: Object#clone
79
+ 00000001029022d1: REXML::Element#get_text
80
+ 00000001028180d7: XmlSimple#force_array?
81
+ 000000010280f5b1: XmlSimple#merge
82
+ 00000001001692bc: Hash#[]
83
+ 0000000102902219: REXML::Element#ignore_whitespace_nodes
84
+ 00000001029021f9: REXML::Element#whitespace
85
+ 000000010297920f: REXML::Source#empty?
86
+ 000000010290383c: REXML::XPathParser#variables=
87
+ 00000001028ff359: REXML::Element#document
88
+ 00000001028fde41: REXML::Element#root
89
+ 00000001028f9c34: REXML::Parent#name=
90
+ 0000000102979211: REXML::Source#match
91
+ 0000000102904795: REXML::Parsers::XPathParser#FilterExpr
92
+ 000000010290478d: REXML::Parsers::XPathParser#PathExpr
93
+ 000000010016a111: Hash#each
94
+ 0000000102818059: XmlSimple#fold_arrays
95
+ 000000010016c261: Array#join
96
+ 0000000102978c11: REXML::Source#initialize
97
+ 00000002052fa051: REXML::SourceFactory.create_from
98
+ 00000001028b4524: REXML::Parsers::BaseParser#stream=
99
+ 00000001028ab8c9: REXML::Parsers::BaseParser#initialize
100
+ 00000001028a0159: REXML::Parsers::TreeParser#initialize
101
+ 0000000102904715: REXML::Parsers::XPathParser#RelativeLocationPath
102
+ 000000010290470d: REXML::Parsers::XPathParser#LocationPath
@@ -78,11 +78,12 @@ context "autoscaling " do
78
78
  @as.stubs(:make_request).with("CreateAutoScalingGroup", {
79
79
  'AutoScalingGroupName' => 'CloudteamTestAutoscalingGroup1',
80
80
  'AvailabilityZones.member.1' => 'us-east-1a',
81
- 'LoadBalancerNames' => 'TestLoadBalancerName',
81
+ 'LoadBalancerNames.member.1' => 'TestLoadBalancerName',
82
+ 'LoadBalancerNames.member.2' => 'TestLoadBalancerName2',
82
83
  'LaunchConfigurationName' => 'CloudteamTestAutoscaling',
83
84
  'MinSize' => "1", 'MaxSize' => "3"
84
85
  }).returns stub(:body => @create_autoscaling_group_response, :is_a? => true)
85
- response = @as.create_autoscaling_group(:autoscaling_group_name => "CloudteamTestAutoscalingGroup1", :availability_zones => "us-east-1a", :load_balancer_names => "TestLoadBalancerName", :launch_configuration_name => "CloudteamTestAutoscaling", :min_size => 1, :max_size => 3)
86
+ response = @as.create_autoscaling_group(:autoscaling_group_name => "CloudteamTestAutoscalingGroup1", :availability_zones => "us-east-1a", :load_balancer_names => ["TestLoadBalancerName", "TestLoadBalancerName2"], :launch_configuration_name => "CloudteamTestAutoscaling", :min_size => 1, :max_size => 3)
86
87
  response.should.be.an.instance_of Hash
87
88
  end
88
89
 
@@ -15,6 +15,12 @@ context "An EC2 image " do
15
15
  before do
16
16
  @ec2 = AWS::EC2::Base.new( :access_key_id => "not a key", :secret_access_key => "not a secret" )
17
17
 
18
+ @create_image_response_body = <<-RESPONSE
19
+ <CreateImageResponse xmlns="http://ec2.amazonaws.com/doc/2009-10-31/">
20
+ <imageId>ami-4fa54026</imageId>
21
+ </CreateImageResponse>
22
+ RESPONSE
23
+
18
24
  @register_image_response_body = <<-RESPONSE
19
25
  <RegisterImageResponse xmlns="http://ec2.amazonaws.com/doc/2007-03-01">
20
26
  <imageId>ami-61a54008</imageId>
@@ -56,6 +62,32 @@ context "An EC2 image " do
56
62
  end
57
63
 
58
64
 
65
+ specify "should be able to be created" do
66
+ @ec2.stubs(:make_request).with('CreateImage', {"InstanceId"=>"fooid", "Name" => "fooname", "Description" => "foodesc", "NoReboot" => "true"}).
67
+ returns stub(:body => @create_image_response_body, :is_a? => true)
68
+ @ec2.create_image(:instance_id => "fooid", :name => "fooname", :description => "foodesc", :no_reboot => true).should.be.an.instance_of Hash
69
+ @ec2.create_image(:instance_id => "fooid", :name => "fooname", :description => "foodesc", :no_reboot => true).imageId.should.equal "ami-4fa54026"
70
+ end
71
+
72
+
73
+ specify "method create_image should raise an exception when called with nil/empty string arguments" do
74
+ lambda { @ec2.create_image() }.should.raise(AWS::ArgumentError)
75
+ lambda { @ec2.create_image(:instance_id => "", :name => "fooname") }.should.raise(AWS::ArgumentError)
76
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "") }.should.raise(AWS::ArgumentError)
77
+ lambda { @ec2.create_image(:instance_id => nil, :name => "fooname") }.should.raise(AWS::ArgumentError)
78
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => nil) }.should.raise(AWS::ArgumentError)
79
+ end
80
+
81
+
82
+ specify "method create_image should raise an exception when called with bad arguments" do
83
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "f"*2) }.should.raise(AWS::ArgumentError)
84
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "f"*129) }.should.raise(AWS::ArgumentError)
85
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "f"*128, :description => "f"*256) }.should.raise(AWS::ArgumentError)
86
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "f"*128, :no_reboot => "true") }.should.raise(AWS::ArgumentError)
87
+ lambda { @ec2.create_image(:instance_id => "fooid", :name => "f"*128, :no_reboot => "false") }.should.raise(AWS::ArgumentError)
88
+ end
89
+
90
+
59
91
  specify "should be able to be registered" do
60
92
  @ec2.stubs(:make_request).with('RegisterImage', {"ImageLocation"=>"mybucket-myimage.manifest.xml"}).
61
93
  returns stub(:body => @register_image_response_body, :is_a? => true)