deltacloud-core 1.0.3 → 1.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (180) hide show
  1. data/LICENSE +23 -0
  2. data/NOTICE +3 -0
  3. data/Rakefile +32 -20
  4. data/bin/deltacloudd +1 -1
  5. data/config.ru +25 -32
  6. data/deltacloud-core.gemspec +1 -1
  7. data/lib/cimi/collections.rb +4 -1
  8. data/lib/cimi/collections/address_templates.rb +2 -2
  9. data/lib/cimi/collections/addresses.rb +1 -1
  10. data/lib/cimi/collections/base.rb +64 -0
  11. data/lib/cimi/collections/{machine_admins.rb → credentials.rb} +12 -12
  12. data/lib/cimi/collections/{vsp_templates.rb → forwarding_group_templates.rb} +12 -16
  13. data/lib/cimi/collections/{vsp_configurations.rb → forwarding_groups.rb} +12 -13
  14. data/lib/cimi/collections/machine_configurations.rb +2 -2
  15. data/lib/cimi/collections/machine_images.rb +1 -1
  16. data/lib/cimi/collections/machines.rb +8 -2
  17. data/lib/cimi/collections/network_configurations.rb +2 -2
  18. data/lib/cimi/collections/{routing_groups.rb → network_port_configurations.rb} +12 -12
  19. data/lib/cimi/collections/{routing_group_templates.rb → network_port_templates.rb} +15 -12
  20. data/lib/cimi/collections/{vsps.rb → network_ports.rb} +33 -32
  21. data/lib/cimi/collections/network_templates.rb +2 -2
  22. data/lib/cimi/collections/networks.rb +17 -2
  23. data/lib/cimi/collections/{entity_metadata.rb → resource_metadata.rb} +10 -10
  24. data/lib/cimi/collections/volume_configurations.rb +1 -1
  25. data/lib/cimi/collections/volume_images.rb +1 -1
  26. data/lib/cimi/collections/volumes.rb +1 -2
  27. data/lib/cimi/dependencies.rb +1 -1
  28. data/lib/cimi/helpers.rb +3 -84
  29. data/lib/cimi/helpers/cimi_helper.rb +15 -14
  30. data/lib/cimi/models.rb +20 -36
  31. data/lib/cimi/models/address.rb +32 -4
  32. data/lib/cimi/models/address_template.rb +2 -2
  33. data/lib/cimi/models/base.rb +24 -5
  34. data/lib/cimi/models/cloud_entry_point.rb +4 -9
  35. data/lib/cimi/models/collection.rb +101 -0
  36. data/lib/cimi/models/{machine_admin.rb → credential.rb} +6 -4
  37. data/lib/cimi/models/disk_collection.rb +1 -2
  38. data/lib/cimi/models/{routing_group_template.rb → forwarding_group.rb} +5 -3
  39. data/lib/cimi/models/{routing_group.rb → forwarding_group_template.rb} +5 -3
  40. data/lib/cimi/models/machine.rb +9 -7
  41. data/lib/cimi/models/machine_configuration.rb +2 -0
  42. data/lib/cimi/models/machine_image.rb +2 -0
  43. data/lib/cimi/models/machine_template.rb +3 -1
  44. data/lib/cimi/models/machine_volume_collection.rb +1 -1
  45. data/lib/cimi/models/network.rb +2 -0
  46. data/lib/cimi/models/network_configuration.rb +4 -8
  47. data/lib/cimi/models/{vsp.rb → network_port.rb} +7 -11
  48. data/lib/cimi/models/{network_configuration_collection.rb → network_port_collection.rb} +25 -8
  49. data/lib/cimi/models/{vsp_configuration.rb → network_port_configuration.rb} +6 -10
  50. data/lib/cimi/models/{network_collection.rb → network_port_configuration_collection.rb} +9 -9
  51. data/lib/cimi/models/{vsp_template.rb → network_port_template.rb} +6 -4
  52. data/lib/cimi/models/{network_template_collection.rb → network_port_template_collection.rb} +10 -8
  53. data/lib/cimi/models/network_template.rb +3 -1
  54. data/lib/cimi/models/{entity_metadata.rb → resource_metadata.rb} +16 -15
  55. data/lib/cimi/models/schema.rb +23 -12
  56. data/lib/cimi/models/volume.rb +2 -0
  57. data/lib/cimi/models/volume_configuration.rb +2 -0
  58. data/lib/cimi/models/volume_image.rb +2 -0
  59. data/lib/cimi/models/volume_template.rb +2 -0
  60. data/lib/cimi/server.rb +10 -6
  61. data/lib/deltacloud/collections.rb +7 -2
  62. data/lib/deltacloud/collections/addresses.rb +3 -1
  63. data/lib/deltacloud/collections/base.rb +64 -0
  64. data/lib/deltacloud/collections/buckets.rb +14 -4
  65. data/lib/deltacloud/collections/drivers.rb +1 -1
  66. data/lib/deltacloud/collections/firewalls.rb +1 -1
  67. data/lib/deltacloud/collections/instances.rb +5 -1
  68. data/lib/deltacloud/collections/keys.rb +1 -1
  69. data/lib/deltacloud/collections/load_balancers.rb +2 -0
  70. data/lib/deltacloud/collections/storage_volumes.rb +3 -5
  71. data/lib/deltacloud/core_ext.rb +1 -0
  72. data/lib/deltacloud/core_ext/hash.rb +8 -0
  73. data/lib/deltacloud/core_ext/ordered_hash.rb +222 -0
  74. data/lib/deltacloud/core_ext/string.rb +9 -0
  75. data/lib/deltacloud/drivers/aruba/aruba_driver.rb +0 -9
  76. data/lib/deltacloud/drivers/base_driver.rb +22 -4
  77. data/lib/deltacloud/drivers/ec2/ec2_driver.rb +0 -4
  78. data/lib/deltacloud/drivers/exceptions.rb +30 -13
  79. data/lib/deltacloud/drivers/features.rb +7 -0
  80. data/lib/deltacloud/drivers/fgcp/fgcp_driver.rb +1 -9
  81. data/lib/deltacloud/drivers/google/google_driver.rb +13 -0
  82. data/lib/deltacloud/drivers/mock/data/addresses/192.168.0.1.yml +3 -0
  83. data/lib/deltacloud/drivers/mock/data/addresses/192.168.0.2.yml +3 -0
  84. data/lib/deltacloud/drivers/mock/data/addresses/192.168.0.3.yml +3 -0
  85. data/lib/deltacloud/drivers/mock/data/addresses/192.168.0.4.yml +3 -0
  86. data/lib/deltacloud/drivers/mock/mock_driver.rb +65 -1
  87. data/lib/deltacloud/drivers/mock/mock_driver_cimi_methods.rb +55 -32
  88. data/lib/deltacloud/drivers/openstack/openstack_driver.rb +18 -6
  89. data/lib/deltacloud/helpers.rb +0 -75
  90. data/lib/deltacloud/helpers/deltacloud_helper.rb +66 -28
  91. data/lib/deltacloud/helpers/driver_helper.rb +7 -0
  92. data/lib/deltacloud/helpers/rabbit_helper.rb +51 -0
  93. data/lib/deltacloud/server.rb +12 -14
  94. data/lib/deltacloud/version.rb +1 -1
  95. data/lib/deltacloud_rack.rb +26 -2
  96. data/lib/ec2/query_parser.rb +18 -3
  97. data/lib/sinatra/rack_accept.rb +7 -2
  98. data/lib/sinatra/rack_matrix_params.rb +14 -14
  99. data/public/javascripts/cmwgapp.js +2 -2
  100. data/tests/cimi/collections/cloud_entry_point_test.rb +3 -3
  101. data/tests/cimi/collections/machine_images_test.rb +2 -2
  102. data/tests/cimi/collections/machines_test.rb +1 -1
  103. data/tests/cimi/collections/url_helper_test.rb +31 -0
  104. data/tests/cimi/spec/cimi/model/{machine_admin_spec.rb → credential_spec.rb} +4 -4
  105. data/tests/deltacloud/base_collection_test.rb +0 -5
  106. data/tests/deltacloud/collections/buckets_collection_test.rb +1 -1
  107. data/tests/deltacloud/collections/drivers_collection_test.rb +1 -1
  108. data/tests/deltacloud/collections/hardware_profiles_collection_test.rb +1 -1
  109. data/tests/deltacloud/collections/images_collection_test.rb +1 -1
  110. data/tests/deltacloud/collections/instance_states_collection_test.rb +1 -1
  111. data/tests/deltacloud/collections/instances_collection_test.rb +1 -1
  112. data/tests/deltacloud/collections/keys_collection_test.rb +1 -4
  113. data/tests/deltacloud/deltacloud_helper_test.rb +0 -9
  114. data/tests/deltacloud/server_test.rb +1 -1
  115. data/tests/drivers/base/base_driver_test.rb +30 -0
  116. data/tests/drivers/base/common.rb +14 -0
  117. data/tests/drivers/base/exceptions_test.rb +64 -0
  118. data/tests/drivers/ec2/buckets_test.rb +45 -0
  119. data/tests/drivers/ec2/keys_test.rb +1 -1
  120. data/tests/drivers/google/buckets_test.rb +2 -2
  121. data/tests/drivers/google/common.rb +3 -3
  122. data/tests/test_helper.rb +28 -0
  123. data/views/api/show.html.haml +2 -2
  124. data/views/api/show.xml.haml +1 -1
  125. data/views/buckets/index.html.haml +1 -1
  126. data/views/cimi/cloudEntryPoint/index.xml.haml +1 -1
  127. data/views/cimi/collection/index.html.haml +3 -3
  128. data/views/cimi/collection/response.xml.haml +1 -1
  129. data/views/cimi/error.html.haml +1 -1
  130. data/views/cimi/errors/500.xml.haml +1 -1
  131. data/views/cimi/layout.html.haml +1 -1
  132. data/views/cimi/machine_configurations/show.html.haml +2 -2
  133. data/views/cimi/machine_configurations/show.xml.haml +1 -1
  134. data/views/cimi/machine_images/show.html.haml +2 -2
  135. data/views/cimi/machine_images/show.xml.haml +1 -1
  136. data/views/cimi/machines/show.html.haml +2 -2
  137. data/views/cimi/machines/show.xml.haml +1 -1
  138. data/views/cimi/volumes/show.html.haml +2 -2
  139. data/views/cimi/volumes/show.xml.haml +1 -1
  140. data/views/docs/collection.html.haml +1 -1
  141. data/views/docs/collection.xml.haml +2 -2
  142. data/views/docs/index.html.haml +1 -1
  143. data/views/docs/index.xml.haml +1 -1
  144. data/views/docs/operation.xml.haml +1 -1
  145. data/views/error.html.haml +1 -1
  146. data/views/errors/500.html.haml +7 -4
  147. data/views/firewalls/index.html.haml +1 -1
  148. data/views/firewalls/show.html.haml +1 -1
  149. data/views/images/show.html.haml +2 -2
  150. data/views/index.html.haml +9 -0
  151. data/views/instance_states/show.html.haml +1 -1
  152. data/views/instances/run_command.html.haml +1 -1
  153. data/views/instances/show.html.haml +2 -2
  154. data/views/keys/index.html.haml +1 -1
  155. data/views/layout.html.haml +1 -1
  156. data/views/load_balancers/index.html.haml +1 -1
  157. data/views/load_balancers/show.html.haml +3 -3
  158. data/views/storage_snapshots/show.html.haml +1 -1
  159. data/views/storage_volumes/attach.html.haml +1 -1
  160. data/views/storage_volumes/index.html.haml +1 -1
  161. data/views/storage_volumes/show.html.haml +4 -4
  162. metadata +40 -43
  163. data/lib/cimi/models/address_collection.rb +0 -34
  164. data/lib/cimi/models/address_template_collection.rb +0 -34
  165. data/lib/cimi/models/entity_metadata_collection.rb +0 -31
  166. data/lib/cimi/models/machine_admin_collection.rb +0 -34
  167. data/lib/cimi/models/machine_collection.rb +0 -37
  168. data/lib/cimi/models/machine_configuration_collection.rb +0 -36
  169. data/lib/cimi/models/machine_image_collection.rb +0 -36
  170. data/lib/cimi/models/machine_template_collection.rb +0 -36
  171. data/lib/cimi/models/routing_group_collection.rb +0 -34
  172. data/lib/cimi/models/routing_group_template_collection.rb +0 -35
  173. data/lib/cimi/models/volume_collection.rb +0 -36
  174. data/lib/cimi/models/volume_configuration_collection.rb +0 -36
  175. data/lib/cimi/models/volume_image_collection.rb +0 -36
  176. data/lib/cimi/models/volume_template_collection.rb +0 -36
  177. data/lib/cimi/models/vsp_collection.rb +0 -34
  178. data/lib/cimi/models/vsp_configuration_collection.rb +0 -34
  179. data/lib/cimi/models/vsp_template_collection.rb +0 -34
  180. data/lib/deltacloud/helpers/url_helper.rb +0 -115
@@ -1,5 +1,5 @@
1
1
  =header "Load balancers" do
2
- %a{ :href => api_url_for('load_balancers/new'), :'data-icon' => :plus, :'data-role' => :button, :class => 'ui-btn-right'} Create new load balancer
2
+ %a{ :href => url_for('load_balancers/new'), :'data-icon' => :plus, :'data-role' => :button, :class => 'ui-btn-right'} Create new load balancer
3
3
  =subheader "#{Thread::current[:provider] || ENV['API_PROVIDER'] || 'default'}"
4
4
 
5
5
  %div{ :'data-role' => :content, :'data-theme' => 'c'}
@@ -20,16 +20,16 @@
20
20
  %li
21
21
  %a{ :href => instance_url(instance[:id]), :'data-ajax' => 'false'}
22
22
  %h3=instance[:name]
23
- =link_to_action "UnRegister", api_url_for("load_balancers/#{@load_balancer.id}/unregister?instance_id=#{instance[:id]}"), :post
23
+ =link_to_action "UnRegister", url_for("load_balancers/#{@load_balancer.id}/unregister?instance_id=#{instance[:id]}"), :post
24
24
  %li{ :'data-role' => 'list-divider'} UnRegistered Instances
25
25
  - @unregistered_instances.each do |instance|
26
26
  %li
27
27
  %a{:href => instance_url(instance[:id]), :'data-ajax' => 'false'}
28
28
  %h3=instance[:name]
29
- =link_to_action "Register", api_url_for("load_balancers/#{@load_balancer.id}/register?instance_id=#{instance[:id]}"), :post
29
+ =link_to_action "Register", url_for("load_balancers/#{@load_balancer.id}/register?instance_id=#{instance[:id]}"), :post
30
30
  %li{ :'data-role' => 'list-divider'} Actions
31
31
  %li
32
- =link_to_action "Destroy", api_url_for("load_balancers/#{@load_balancer.id}"), :delete
32
+ =link_to_action "Destroy", url_for("load_balancers/#{@load_balancer.id}"), :delete
33
33
 
34
34
  =header "Listeners", :back => 'false'
35
35
  %ul{ :'data-role' => :listview , :'data-inset' => :true, :'data-divider-theme' => 'd'}
@@ -19,4 +19,4 @@
19
19
  %li
20
20
  %div{ :'data-role' => 'controlgroup', :'data-type' => "horizontal" }
21
21
  - if driver.respond_to?(:destroy_storage_snapshot)
22
- =link_to_action "Delete", api_url_for("storage_snapshots/#{@storage_snapshot.id}"), :delete
22
+ =link_to_action "Delete", url_for("storage_snapshots/#{@storage_snapshot.id}"), :delete
@@ -1,6 +1,6 @@
1
1
  %h1 Attach storage volume
2
2
 
3
- %form{ :action => api_url_for("storage_volumes/#{params[:id]}/attach"), :method => :post }
3
+ %form{ :action => url_for("storage_volumes/#{params[:id]}/attach"), :method => :post }
4
4
  %p
5
5
  %label
6
6
  Instance ID:
@@ -1,5 +1,5 @@
1
1
  =header "Storage volumes" do
2
- %a{ :href => api_url_for('storage_volumes/new'), :'data-icon' => :plus, :'data-role' => :button, :class => 'ui-btn-right'} Create new volume
2
+ %a{ :href => url_for('storage_volumes/new'), :'data-icon' => :plus, :'data-role' => :button, :class => 'ui-btn-right'} Create new volume
3
3
 
4
4
  %div{ :'data-role' => :content, :'data-theme' => 'c'}
5
5
  %ul{ :'data-role' => :listview , :'data-inset' => :true, :'data-divider-theme' => 'a'}
@@ -35,9 +35,9 @@
35
35
  %li
36
36
  %div{ :'data-role' => 'controlgroup', :'data-type' => "horizontal" }
37
37
  - if ["AVAILABLE", "IN-USE"].include?(@storage_volume.state)
38
- =link_to_action "Snapshot", api_url_for("storage_snapshots/new?volume_id=#{@storage_volume.id}"), :get
38
+ =link_to_action "Snapshot", url_for("storage_snapshots/new?volume_id=#{@storage_volume.id}"), :get
39
39
  - unless @storage_volume.instance_id
40
- =link_to_action "Delete", api_url_for("storage_volumes/#{@storage_volume.id}"), :delete
41
- =link_to_action "Attach", api_url_for("storage_volumes/#{@storage_volume.id}/attach_instance"), :get
40
+ =link_to_action "Delete", url_for("storage_volumes/#{@storage_volume.id}"), :delete
41
+ =link_to_action "Attach", url_for("storage_volumes/#{@storage_volume.id}/attach_instance"), :get
42
42
  - if @storage_volume.instance_id
43
- =link_to_action "Detach", api_url_for("storage_volumes/#{@storage_volume.id}/detach"), :post
43
+ =link_to_action "Detach", url_for("storage_volumes/#{@storage_volume.id}/detach"), :post
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: deltacloud-core
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 31
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 3
10
- version: 1.0.3
9
+ - 4
10
+ version: 1.0.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - The Apache Software Foundation
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-09-07 00:00:00 Z
18
+ date: 2012-10-08 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  requirement: &id001 !ruby/object:Gem::Requirement
@@ -71,12 +71,12 @@ dependencies:
71
71
  requirements:
72
72
  - - ">="
73
73
  - !ruby/object:Gem::Version
74
- hash: 3
74
+ hash: 1
75
75
  segments:
76
76
  - 1
77
77
  - 0
78
- - 10
79
- version: 1.0.10
78
+ - 11
79
+ version: 1.0.11
80
80
  version_requirements: *id004
81
81
  name: sinatra-rabbit
82
82
  prerelease: false
@@ -433,73 +433,58 @@ files:
433
433
  - support/condor/config/50condor_cloud_node.config
434
434
  - support/condor/config/condor-cloud
435
435
  - lib/cimi/collections/machine_images.rb
436
- - lib/cimi/collections/vsps.rb
437
- - lib/cimi/collections/machine_admins.rb
438
436
  - lib/cimi/collections/addresses.rb
439
- - lib/cimi/collections/routing_group_templates.rb
437
+ - lib/cimi/collections/credentials.rb
440
438
  - lib/cimi/collections/network_templates.rb
441
439
  - lib/cimi/collections/volume_configurations.rb
442
- - lib/cimi/collections/vsp_configurations.rb
440
+ - lib/cimi/collections/network_ports.rb
443
441
  - lib/cimi/collections/machines.rb
444
442
  - lib/cimi/collections/machine_configurations.rb
445
443
  - lib/cimi/collections/cloud_entry_point.rb
444
+ - lib/cimi/collections/network_port_templates.rb
446
445
  - lib/cimi/collections/volume_images.rb
447
- - lib/cimi/collections/vsp_templates.rb
446
+ - lib/cimi/collections/forwarding_groups.rb
448
447
  - lib/cimi/collections/networks.rb
449
- - lib/cimi/collections/routing_groups.rb
450
- - lib/cimi/collections/entity_metadata.rb
448
+ - lib/cimi/collections/network_port_configurations.rb
451
449
  - lib/cimi/collections/volumes.rb
452
450
  - lib/cimi/collections/network_configurations.rb
451
+ - lib/cimi/collections/resource_metadata.rb
452
+ - lib/cimi/collections/forwarding_group_templates.rb
453
453
  - lib/cimi/collections/address_templates.rb
454
+ - lib/cimi/collections/base.rb
454
455
  - lib/cimi/models/action.rb
455
456
  - lib/cimi/models/network.rb
457
+ - lib/cimi/models/network_port_template_collection.rb
456
458
  - lib/cimi/models/address_template.rb
457
459
  - lib/cimi/models/disk_collection.rb
458
- - lib/cimi/models/machine_collection.rb
459
- - lib/cimi/models/entity_metadata_collection.rb
460
+ - lib/cimi/models/network_port_configuration_collection.rb
460
461
  - lib/cimi/models/volume.rb
462
+ - lib/cimi/models/forwarding_group_template.rb
461
463
  - lib/cimi/models/machine_template.rb
462
- - lib/cimi/models/vsp_collection.rb
464
+ - lib/cimi/models/network_port_template.rb
463
465
  - lib/cimi/models/errors.rb
464
- - lib/cimi/models/network_collection.rb
465
466
  - lib/cimi/models/disk.rb
466
- - lib/cimi/models/routing_group_collection.rb
467
- - lib/cimi/models/vsp_template_collection.rb
467
+ - lib/cimi/models/network_port_collection.rb
468
+ - lib/cimi/models/credential.rb
468
469
  - lib/cimi/models/address.rb
469
- - lib/cimi/models/routing_group_template.rb
470
470
  - lib/cimi/models/machine_volume.rb
471
- - lib/cimi/models/routing_group.rb
472
- - lib/cimi/models/vsp_configuration.rb
473
- - lib/cimi/models/volume_image_collection.rb
474
- - lib/cimi/models/machine_admin_collection.rb
471
+ - lib/cimi/models/collection.rb
475
472
  - lib/cimi/models/cloud_entry_point.rb
476
- - lib/cimi/models/routing_group_template_collection.rb
477
473
  - lib/cimi/models/network_template.rb
478
474
  - lib/cimi/models/volume_configuration.rb
479
475
  - lib/cimi/models/volume_template.rb
480
- - lib/cimi/models/vsp_configuration_collection.rb
481
476
  - lib/cimi/models/machine_image.rb
482
- - lib/cimi/models/machine_template_collection.rb
483
- - lib/cimi/models/machine_admin.rb
484
- - lib/cimi/models/vsp_template.rb
485
477
  - lib/cimi/models/network_configuration.rb
486
478
  - lib/cimi/models/schema.rb
487
479
  - lib/cimi/models/machine.rb
488
- - lib/cimi/models/entity_metadata.rb
489
- - lib/cimi/models/network_template_collection.rb
480
+ - lib/cimi/models/network_port_configuration.rb
490
481
  - lib/cimi/models/volume_image.rb
491
- - lib/cimi/models/machine_image_collection.rb
482
+ - lib/cimi/models/network_port.rb
483
+ - lib/cimi/models/forwarding_group.rb
492
484
  - lib/cimi/models/machine_volume_collection.rb
493
- - lib/cimi/models/machine_configuration_collection.rb
494
- - lib/cimi/models/address_template_collection.rb
495
- - lib/cimi/models/volume_template_collection.rb
496
- - lib/cimi/models/network_configuration_collection.rb
497
- - lib/cimi/models/volume_collection.rb
498
- - lib/cimi/models/address_collection.rb
499
- - lib/cimi/models/vsp.rb
485
+ - lib/cimi/models/resource_metadata.rb
500
486
  - lib/cimi/models/base.rb
501
487
  - lib/cimi/models/machine_configuration.rb
502
- - lib/cimi/models/volume_configuration_collection.rb
503
488
  - lib/cimi/models.rb
504
489
  - lib/cimi/server.rb
505
490
  - lib/cimi/collections.rb
@@ -520,6 +505,7 @@ files:
520
505
  - lib/deltacloud/collections/drivers.rb
521
506
  - lib/deltacloud/collections/firewalls.rb
522
507
  - lib/deltacloud/collections/realms.rb
508
+ - lib/deltacloud/collections/base.rb
523
509
  - lib/deltacloud/models/firewall_rule.rb
524
510
  - lib/deltacloud/models/realm.rb
525
511
  - lib/deltacloud/models/image.rb
@@ -543,6 +529,7 @@ files:
543
529
  - lib/deltacloud/server.rb
544
530
  - lib/deltacloud/api.rb
545
531
  - lib/deltacloud/core_ext/array.rb
532
+ - lib/deltacloud/core_ext/ordered_hash.rb
546
533
  - lib/deltacloud/core_ext/proc.rb
547
534
  - lib/deltacloud/core_ext/string.rb
548
535
  - lib/deltacloud/core_ext/integer.rb
@@ -554,7 +541,6 @@ files:
554
541
  - lib/deltacloud/helpers/driver_helper.rb
555
542
  - lib/deltacloud/helpers/blob_stream_helper.rb
556
543
  - lib/deltacloud/helpers/deltacloud_helper.rb
557
- - lib/deltacloud/helpers/url_helper.rb
558
544
  - lib/deltacloud/helpers/rabbit_helper.rb
559
545
  - lib/deltacloud/helpers.rb
560
546
  - lib/deltacloud/runner.rb
@@ -622,6 +608,10 @@ files:
622
608
  - lib/deltacloud/drivers/mock/data/storage_snapshots/snap1.yml
623
609
  - lib/deltacloud/drivers/mock/data/storage_snapshots/snap3.yml
624
610
  - lib/deltacloud/drivers/mock/data/storage_snapshots/snap2.yml
611
+ - lib/deltacloud/drivers/mock/data/addresses/192.168.0.2.yml
612
+ - lib/deltacloud/drivers/mock/data/addresses/192.168.0.3.yml
613
+ - lib/deltacloud/drivers/mock/data/addresses/192.168.0.4.yml
614
+ - lib/deltacloud/drivers/mock/data/addresses/192.168.0.1.yml
625
615
  - lib/deltacloud/drivers/mock/data/blobs/blob1.yml
626
616
  - lib/deltacloud/drivers/mock/data/blobs/blob2.yml
627
617
  - lib/deltacloud/drivers/mock/data/blobs/blob4.yml
@@ -644,14 +634,15 @@ files:
644
634
  - tests/cimi/collections/cloud_entry_point_test.rb
645
635
  - tests/cimi/collections/machines_test.rb
646
636
  - tests/cimi/collections/common.rb
637
+ - tests/cimi/collections/url_helper_test.rb
647
638
  - tests/cimi/collections/machine_images_test.rb
648
639
  - tests/cimi/spec/cimi/model/machine_template_spec.rb
649
640
  - tests/cimi/spec/cimi/model/machine_spec.rb
650
641
  - tests/cimi/spec/cimi/model/machine_configuration_spec.rb
651
642
  - tests/cimi/spec/cimi/model/volume_configuration_spec.rb
652
643
  - tests/cimi/spec/cimi/model/volume_template_spec.rb
653
- - tests/cimi/spec/cimi/model/machine_admin_spec.rb
654
644
  - tests/cimi/spec/cimi/model/volume_spec.rb
645
+ - tests/cimi/spec/cimi/model/credential_spec.rb
655
646
  - tests/cimi/spec/cimi/model/volume_image_spec.rb
656
647
  - tests/cimi/spec/cimi/model/schema_spec.rb
657
648
  - tests/cimi/spec/cimi/model/machine_image_spec.rb
@@ -699,6 +690,7 @@ files:
699
690
  - tests/drivers/rhevm/instance_test.rb
700
691
  - tests/drivers/rhevm/provider_test.rb
701
692
  - tests/drivers/base/common.rb
693
+ - tests/drivers/base/exceptions_test.rb
702
694
  - tests/drivers/base/base_driver_test.rb
703
695
  - tests/drivers/base/library_test.rb
704
696
  - tests/drivers/openstack/images_test.rb
@@ -720,6 +712,7 @@ files:
720
712
  - tests/drivers/ec2/realms_test.rb
721
713
  - tests/drivers/ec2/instance_test.rb
722
714
  - tests/drivers/ec2/storage_snapshots_test.rb
715
+ - tests/drivers/ec2/buckets_test.rb
723
716
  - tests/drivers/gogrid/images_test.rb
724
717
  - tests/drivers/gogrid/common.rb
725
718
  - tests/drivers/gogrid/hardware_profiles_test.rb
@@ -811,6 +804,7 @@ files:
811
804
  - views/storage_volumes/index.html.haml
812
805
  - views/storage_volumes/show.xml.haml
813
806
  - views/storage_volumes/new.html.haml
807
+ - views/index.html.haml
814
808
  - views/storage_snapshots/index.xml.haml
815
809
  - views/storage_snapshots/show.html.haml
816
810
  - views/storage_snapshots/index.html.haml
@@ -938,6 +932,7 @@ summary: Deltacloud REST API
938
932
  test_files:
939
933
  - tests/cimi/collections/cloud_entry_point_test.rb
940
934
  - tests/cimi/collections/machines_test.rb
935
+ - tests/cimi/collections/url_helper_test.rb
941
936
  - tests/cimi/collections/machine_images_test.rb
942
937
  - tests/deltacloud/server_test.rb
943
938
  - tests/deltacloud/collections/instances_collection_test.rb
@@ -975,6 +970,7 @@ test_files:
975
970
  - tests/drivers/rhevm/realms_test.rb
976
971
  - tests/drivers/rhevm/instance_test.rb
977
972
  - tests/drivers/rhevm/provider_test.rb
973
+ - tests/drivers/base/exceptions_test.rb
978
974
  - tests/drivers/base/base_driver_test.rb
979
975
  - tests/drivers/base/library_test.rb
980
976
  - tests/drivers/openstack/images_test.rb
@@ -993,6 +989,7 @@ test_files:
993
989
  - tests/drivers/ec2/realms_test.rb
994
990
  - tests/drivers/ec2/instance_test.rb
995
991
  - tests/drivers/ec2/storage_snapshots_test.rb
992
+ - tests/drivers/ec2/buckets_test.rb
996
993
  - tests/drivers/gogrid/images_test.rb
997
994
  - tests/drivers/gogrid/hardware_profiles_test.rb
998
995
  - tests/drivers/gogrid/instances_test.rb
@@ -1,34 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one or more
2
- # contributor license agreements. See the NOTICE file distributed with
3
- # this work for additional information regarding copyright ownership. The
4
- # ASF licenses this file to you under the Apache License, Version 2.0 (the
5
- # "License"); you may not use this file except in compliance with the
6
- # License. You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13
- # License for the specific language governing permissions and limitations
14
- # under the License.
15
-
16
- class CIMI::Model::AddressCollection < CIMI::Model::Base
17
-
18
- act_as_root_entity :address
19
-
20
- array :addresses do
21
- scalar :href
22
- end
23
-
24
- def self.default(context)
25
- self.new(
26
- :id => context.addresses_url,
27
- :name => 'default',
28
- :created => Time.now,
29
- :description => "#{context.driver.name.capitalize} AddressCollection",
30
- :addresses => CIMI::Model::Address.all(context).map { |addr| { :href => addr.id } }
31
- )
32
- end
33
-
34
- end
@@ -1,34 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one or more
2
- # contributor license agreements. See the NOTICE file distributed with
3
- # this work for additional information regarding copyright ownership. The
4
- # ASF licenses this file to you under the Apache License, Version 2.0 (the
5
- # "License"); you may not use this file except in compliance with the
6
- # License. You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13
- # License for the specific language governing permissions and limitations
14
- # under the License.
15
-
16
- class CIMI::Model::AddressTemplateCollection < CIMI::Model::Base
17
-
18
- act_as_root_entity :address_template
19
-
20
- array :address_templates do
21
- scalar :href
22
- end
23
-
24
- def self.default(context)
25
- self.new(
26
- :id => context.address_templates_url,
27
- :name => 'default',
28
- :created => Time.now,
29
- :description => "#{context.driver.name.capitalize} AddressTemplateCollection",
30
- :address_templates => CIMI::Model::AddressTemplate.all(context).map { |addr| { :href => addr.id } }
31
- )
32
- end
33
-
34
- end
@@ -1,31 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one or more
2
- # contributor license agreements. See the NOTICE file distributed with
3
- # this work for additional information regarding copyright ownership. The
4
- # ASF licenses this file to you under the Apache License, Version 2.0 (the
5
- # "License"); you may not use this file except in compliance with the
6
- # License. You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13
- # License for the specific language governing permissions and limitations
14
- # under the License.
15
-
16
- class CIMI::Model::EntityMetadataCollection < CIMI::Model::Base
17
-
18
- array :entity_metadata do
19
- scalar :href
20
- end
21
-
22
- def self.default(context)
23
- self.new(
24
- :id => context.entity_metadata_url,
25
- :name => 'default',
26
- :created => Time.now,
27
- :entity_metadata => CIMI::Model::EntityMetadata.all_uri(context)
28
- )
29
- end
30
-
31
- end
@@ -1,34 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one or more
2
- # contributor license agreements. See the NOTICE file distributed with
3
- # this work for additional information regarding copyright ownership. The
4
- # ASF licenses this file to you under the Apache License, Version 2.0 (the
5
- # "License"); you may not use this file except in compliance with the
6
- # License. You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13
- # License for the specific language governing permissions and limitations
14
- # under the License.
15
-
16
- class CIMI::Model::MachineAdminCollection < CIMI::Model::Base
17
-
18
- act_as_root_entity :machine_admin
19
-
20
- array :machine_admins do
21
- scalar :href
22
- end
23
-
24
- def self.default(context)
25
- self.new(
26
- :id => context.machine_admins_url,
27
- :name => 'default',
28
- :created => Time.now,
29
- :description => "#{context.driver.name.capitalize} MachineAdminCollection",
30
- :machine_admins => CIMI::Model::MachineAdmin.all_uri(context)
31
- )
32
- end
33
-
34
- end
@@ -1,37 +0,0 @@
1
- # Licensed to the Apache Software Foundation (ASF) under one or more
2
- # contributor license agreements. See the NOTICE file distributed with
3
- # this work for additional information regarding copyright ownership. The
4
- # ASF licenses this file to you under the Apache License, Version 2.0 (the
5
- # "License"); you may not use this file except in compliance with the
6
- # License. You may obtain a copy of the License at
7
- #
8
- # http://www.apache.org/licenses/LICENSE-2.0
9
- #
10
- # Unless required by applicable law or agreed to in writing, software
11
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13
- # License for the specific language governing permissions and limitations
14
- # under the License.
15
-
16
- class CIMI::Model::MachineCollection < CIMI::Model::Base
17
-
18
- act_as_root_entity :machine
19
-
20
- text :count
21
-
22
- #add machines array:
23
- self.schema.add_collection_member_array(CIMI::Model::Machine)
24
-
25
- def self.default(context)
26
- machines = CIMI::Model::Machine.all(context)
27
- self.new(
28
- :id => context.machines_url,
29
- :name => 'default',
30
- :created => Time.now,
31
- :description => "#{context.driver.name.capitalize} MachineCollection",
32
- :count => machines.size,
33
- :machines => machines
34
- )
35
- end
36
-
37
- end