oneview-sdk 5.6.0 → 5.7.0

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 (28) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG.md +18 -1
  3. data/README.md +7 -2
  4. data/endpoints-support.md +23 -10
  5. data/lib/oneview-sdk.rb +1 -1
  6. data/lib/oneview-sdk/resource/api200/volume.rb +3 -2
  7. data/lib/oneview-sdk/resource/api800.rb +66 -0
  8. data/lib/oneview-sdk/resource/api800/c7000.rb +27 -0
  9. data/lib/oneview-sdk/resource/api800/c7000/enclosure_group.rb +22 -0
  10. data/lib/oneview-sdk/resource/api800/c7000/ethernet_network.rb +22 -0
  11. data/lib/oneview-sdk/resource/api800/c7000/hypervisor_cluster_profile.rb +39 -0
  12. data/lib/oneview-sdk/resource/api800/c7000/hypervisor_manager.rb +33 -0
  13. data/lib/oneview-sdk/resource/api800/c7000/scope.rb +22 -0
  14. data/lib/oneview-sdk/resource/api800/c7000/server_hardware_type.rb +22 -0
  15. data/lib/oneview-sdk/resource/api800/c7000/server_profile.rb +22 -0
  16. data/lib/oneview-sdk/resource/api800/c7000/server_profile_template.rb +33 -0
  17. data/lib/oneview-sdk/resource/api800/synergy.rb +27 -0
  18. data/lib/oneview-sdk/resource/api800/synergy/enclosure_group.rb +22 -0
  19. data/lib/oneview-sdk/resource/api800/synergy/ethernet_network.rb +22 -0
  20. data/lib/oneview-sdk/resource/api800/synergy/hypervisor_cluster_profile.rb +22 -0
  21. data/lib/oneview-sdk/resource/api800/synergy/hypervisor_manager.rb +22 -0
  22. data/lib/oneview-sdk/resource/api800/synergy/os_deployment_plan.rb +22 -0
  23. data/lib/oneview-sdk/resource/api800/synergy/scope.rb +22 -0
  24. data/lib/oneview-sdk/resource/api800/synergy/server_hardware_type.rb +22 -0
  25. data/lib/oneview-sdk/resource/api800/synergy/server_profile.rb +25 -0
  26. data/lib/oneview-sdk/resource/api800/synergy/server_profile_template.rb +22 -0
  27. data/lib/oneview-sdk/version.rb +1 -1
  28. metadata +23 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 89a7a5cef6278ff47b14edb0528fcd85385ec26d
4
- data.tar.gz: f2dde091e8be1f8c0c240ebcce1c26ff7165e74d
2
+ SHA256:
3
+ metadata.gz: 60c7874bd15c197837e096eaed6f84325fa0b9573e3a8577f989f432999b929c
4
+ data.tar.gz: 118c6401d3317ffbf7e9523de36dff1dd88ba35d17cc0e40ea9c3f1bfe0e9f77
5
5
  SHA512:
6
- metadata.gz: ac0a41f7b1ef587d2c7ab787bd799f9dee42beaaf5337d6af1f1fe3fc99b7a39c22eba5cf64c889ca5f5fe4624e4c1abba6518313e1b5fe83e35f8fdbff1ce24
7
- data.tar.gz: bd1df4efd63393891d648c27d18ce4564acc8b84f44e37e9bcf2899ae1dad2b22a5e5c22d3dd4cf7b3dce31fb880a6b04f21336237aa2d51751bed2670b5ff5d
6
+ metadata.gz: 88057502465806b2d9b1177c6628e4c092f4f80a0315b61f59c1886efaeb329c0b550e28700e0f950cdc7133e8c1264435f4e0944edd40920e564d5077031c30
7
+ data.tar.gz: b228f8c6adaf9bf7fed3b6bb0c1412c462e68acfe8c4bde6dd02005ead05af25c0b7dc3e4658ca979eae7f0526794570184cd7af3a96fb21737d058a6ac85d55
data/CHANGELOG.md CHANGED
@@ -1,3 +1,20 @@
1
+ ## v5.7.0
2
+
3
+ #### Notes
4
+ Extends support of the SDK to OneView Rest API version 800 (OneView v4.10).
5
+ This release fixes one bug listed below.
6
+
7
+ #### New Resource
8
+ - Hypervisor Cluster Profile
9
+ - Hypervisor Manager
10
+
11
+ #### Features Supported
12
+ This release adds support to OneView Rest API version 800 for the hardware variants C7000 and Synergy to the already existing features:
13
+ - Server Profile Template
14
+
15
+ #### Bug fixes & Enhancements
16
+ - [#366](https://github.com/HewlettPackard/oneview-sdk-ruby/issues/366) Query parameters not working for get_attachable_volumes endpoint
17
+
1
18
  ## v5.6.0
2
19
 
3
20
  #### Notes
@@ -5,7 +22,7 @@ This release fixes few bugs which are listed below.
5
22
 
6
23
  #### New Resource
7
24
  Alerts
8
-
25
+
9
26
  #### Bug fixes & Enhancements
10
27
  - [#362](https://github.com/HewlettPackard/oneview-sdk-ruby/issues/362) Added helper method to change request body for Server Profile for API600.
11
28
  - [#354](https://github.com/HewlettPackard/oneview-sdk-ruby/issues/354) Input data has be to be a part of body, but not the header for import certificate method in enclosure.
data/README.md CHANGED
@@ -167,7 +167,7 @@ You may notice resource classes being accessed in a few different ways; for exam
167
167
  require 'oneview-sdk'
168
168
 
169
169
  # Show defaults:
170
- OneviewSDK::SUPPORTED_API_VERSIONS # [200, 300, 500, 600]
170
+ OneviewSDK::SUPPORTED_API_VERSIONS # [200, 300, 500, 600, 800]
171
171
  OneviewSDK::DEFAULT_API_VERSION # 200
172
172
  OneviewSDK.api_version # 200
173
173
  OneviewSDK.api_version_updated? # false
@@ -183,7 +183,7 @@ OneviewSDK.api_version = 300
183
183
  OneviewSDK.api_version # 300
184
184
  OneviewSDK.api_version_updated? # true
185
185
 
186
- # The API200 module has no variants, but API300, API500 and API600 has 2 (C7000 & Synergy):
186
+ # The API200 module has no variants, but API300 and above has 2 (C7000 & Synergy):
187
187
  OneviewSDK::API300::SUPPORTED_VARIANTS # ['C7000', 'Synergy']
188
188
  OneviewSDK::API300::DEFAULT_VARIANT # 'C7000'
189
189
  OneviewSDK::API300.variant # 'C7000'
@@ -199,6 +199,11 @@ OneviewSDK::API600::DEFAULT_VARIANT # 'C7000'
199
199
  OneviewSDK::API600.variant # 'C7000'
200
200
  OneviewSDK::API600.variant_updated? # false
201
201
 
202
+ OneviewSDK::API800::SUPPORTED_VARIANTS # ['C7000', 'Synergy']
203
+ OneviewSDK::API800::DEFAULT_VARIANT # 'C7000'
204
+ OneviewSDK::API800.variant # 'C7000'
205
+ OneviewSDK::API800.variant_updated? # false
206
+
202
207
  # Therefore, there is 1 more namespace level to the real resource class name
203
208
  OneviewSDK::EthernetNetwork # OneviewSDK::API300::C7000::EthernetNetwork
204
209
  OneviewSDK::API300::EthernetNetwork # OneviewSDK::API300::C7000::EthernetNetwork
data/endpoints-support.md CHANGED
@@ -22,8 +22,8 @@ OneviewSDK::Datacenter.find_by(@client, width: 11000).map(&:remove)
22
22
 
23
23
  ## HPE OneView
24
24
 
25
- | Endpoints | Verb | V200 | V300 | V500 | V600 |
26
- | --------------------------------------------------------------------------------------- | -------- | :------------------: | :------------------: | :------------------: | :------------------: |
25
+ | Endpoints | Verb | V200 | V300 | V500 | V600 | V800
26
+ | --------------------------------------------------------------------------------------- | -------- | :------------------: | :------------------: | :------------------: | :------------------: | :------------------: |
27
27
  | **Alerts** |
28
28
  |<sub>/rest/alerts</sub> |GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
29
29
  |<sub>/rest/alerts</sub> |DELETE | :heavy_multiplication_x: | :heavy_multiplication_x: | :heavy_multiplication_x: | :heavy_multiplication_x: |
@@ -139,6 +139,19 @@ OneviewSDK::Datacenter.find_by(@client, width: 11000).map(&:remove)
139
139
  |<sub>/rest/firmware-drivers</sub> | POST | :white_check_mark: | :white_check_mark: | :white_check_mark: |
140
140
  |<sub>/rest/firmware-drivers/{id}</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: |
141
141
  |<sub>/rest/firmware-drivers/{id}</sub> | DELETE | :white_check_mark: | :white_check_mark: | :white_check_mark: |
142
+ | **Hypervisor Managers** |
143
+ |<sub>/rest/hypervisor-managers</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
144
+ |<sub>/rest/hypervisor-managers</sub> | POST | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
145
+ |<sub>/rest/hypervisor-managers/{id}</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
146
+ |<sub>/rest/hypervisor-managers/{id}</sub> | PUT | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
147
+ |<sub>/rest/hypervisor-managers/{id}</sub> | DELETE | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
148
+ | **Hypervisor Cluster Profiles** |
149
+ |<sub>/rest/hypervisor-cluster-profiles</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
150
+ |<sub>/rest/hypervisor-cluster-profiles</sub> | POST | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
151
+ |<sub>/rest/hypervisor-cluster-profiles/{id}</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
152
+ |<sub>/rest/hypervisor-cluster-profiles/{id}</sub> | PUT | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
153
+ |<sub>/rest/hypervisor-cluster-profiles/{id}/compliance-preview</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
154
+ |<sub>/rest/hypervisor-cluster-profiles/{id}</sub> | DELETE | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: |
142
155
  | **ID Pools** |
143
156
  |<sub>/rest/id-pools/{poolType}</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: |
144
157
  |<sub>/rest/id-pools/{poolType}</sub> | PUT | :white_check_mark: | :white_check_mark: | :white_check_mark: |
@@ -444,14 +457,14 @@ OneviewSDK::Datacenter.find_by(@client, width: 11000).map(&:remove)
444
457
  |<sub>/rest/server-hardware-types/{id}</sub> | PUT | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
445
458
  |<sub>/rest/server-hardware-types/{id}</sub> | DELETE | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
446
459
  | **Server Profile Templates** |
447
- |<sub>/rest/server-profile-templates</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
448
- |<sub>/rest/server-profile-templates</sub> | POST | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
449
- |<sub>/rest/server-profile-templates/{id}</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
450
- |<sub>/rest/server-profile-templates/{id}</sub> | PUT | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
451
- |<sub>/rest/server-profile-templates/{id}</sub> | DELETE | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
452
- |<sub>/rest/server-profile-templates/{id}/new-profile</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
453
- |<sub>/rest/server-profile-templates/{id}/transformation</sub> | GET | :heavy_minus_sign: | :white_check_mark: | :white_check_mark: | :white_check_mark:
454
- |<sub>/rest/server-profile-templates/available-networks | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark:
460
+ |<sub>/rest/server-profile-templates</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
461
+ |<sub>/rest/server-profile-templates</sub> | POST | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
462
+ |<sub>/rest/server-profile-templates/{id}</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
463
+ |<sub>/rest/server-profile-templates/{id}</sub> | PUT | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
464
+ |<sub>/rest/server-profile-templates/{id}</sub> | DELETE | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
465
+ |<sub>/rest/server-profile-templates/{id}/new-profile</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
466
+ |<sub>/rest/server-profile-templates/{id}/transformation</sub> | GET | :heavy_minus_sign: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
467
+ |<sub>/rest/server-profile-templates/available-networks | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | :white_check_mark: |
455
468
  | **Server Profiles** |
456
469
  |<sub>/rest/server-profiles</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
457
470
  |<sub>/rest/server-profiles</sub> | POST | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark:
data/lib/oneview-sdk.rb CHANGED
@@ -26,7 +26,7 @@ module OneviewSDK
26
26
  env_i3s = %w[I3S_URL I3S_SSL_ENABLED]
27
27
  ENV_VARS = env_sdk.concat(env_i3s).freeze
28
28
 
29
- SUPPORTED_API_VERSIONS = [200, 300, 500, 600].freeze
29
+ SUPPORTED_API_VERSIONS = [200, 300, 500, 600, 800].freeze
30
30
  DEFAULT_API_VERSION = 200
31
31
  @api_version = DEFAULT_API_VERSION
32
32
  @api_version_updated = false # Whether or not the API version has been set by the user
@@ -147,8 +147,9 @@ module OneviewSDK
147
147
  # Gets all the attachable volumes managed by the appliance
148
148
  # @param [OneviewSDK::Client] client The client object for the OneView appliance
149
149
  # @return [Array<OneviewSDK::Volume>] Array of volumes
150
- def self.get_attachable_volumes(client)
151
- uri = "#{BASE_URI}/attachable-volumes"
150
+ def self.get_attachable_volumes(client, query = nil)
151
+ query_uri = build_query(query) if query
152
+ uri = "#{BASE_URI}/attachable-volumes#{query_uri}"
152
153
  find_by(client, {}, uri)
153
154
  end
154
155
 
@@ -0,0 +1,66 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ module OneviewSDK
13
+ # Module for API v800
14
+ module API800
15
+ SUPPORTED_VARIANTS = %w[C7000 Synergy].freeze
16
+ DEFAULT_VARIANT = 'C7000'.freeze
17
+ @variant = DEFAULT_VARIANT
18
+ @variant_updated = false # Whether or not the API variant has been set by the user
19
+
20
+ # Get resource class that matches the type given
21
+ # @param [String] type Name of the desired class type
22
+ # @param [String] variant Variant (C7000 or Synergy)
23
+ # @return [Class] Resource class or nil if not found
24
+ def self.resource_named(type, variant = @variant)
25
+ raise "API800 variant '#{variant}' is not supported! Try one of #{SUPPORTED_VARIANTS}" unless SUPPORTED_VARIANTS.include?(variant.to_s)
26
+ new_type = type.to_s.downcase.gsub(/[ -_]/, '')
27
+ api_module = OneviewSDK::API800.const_get(variant)
28
+ api_module.constants.each do |c|
29
+ klass = api_module.const_get(c)
30
+ next unless klass.is_a?(Class)
31
+ name = klass.name.split('::').last.downcase.delete('_').delete('-')
32
+ return klass if new_type =~ /^#{name}[s]?$/
33
+ end
34
+ nil
35
+ end
36
+
37
+ # Get the current API800 variant
38
+ def self.variant
39
+ @variant
40
+ end
41
+
42
+ # Has the API800 variant been set by the user?
43
+ # @return [TrueClass, FalseClass]
44
+ def self.variant_updated?
45
+ @variant_updated
46
+ end
47
+
48
+ # Sets the API800 variant
49
+ def self.variant=(variant)
50
+ raise "API800 variant '#{variant}' is not supported! Try one of #{SUPPORTED_VARIANTS}" unless SUPPORTED_VARIANTS.include?(variant)
51
+ @variant_updated = true
52
+ @variant = variant
53
+ end
54
+
55
+ # Helps redirect resources to the correct API800 variant
56
+ def self.const_missing(const)
57
+ api800_module = OneviewSDK::API800.const_get(@variant.to_s)
58
+ api800_module.const_get(const)
59
+ rescue NameError
60
+ raise NameError, "The #{const} method or resource does not exist for OneView API800 variant #{@variant}."
61
+ end
62
+ end
63
+ end
64
+
65
+ # Load all API800-specific resources:
66
+ Dir[File.dirname(__FILE__) + '/api800/*.rb'].each { |file| require file }
@@ -0,0 +1,27 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ module OneviewSDK
13
+ module API800
14
+ # Module for API800 C7000
15
+ module C7000
16
+ # Get resource class that matches the type given
17
+ # @param [String] type Name of the desired class type
18
+ # @return [Class] Resource class or nil if not found
19
+ def self.resource_named(type)
20
+ OneviewSDK::API800.resource_named(type, 'C7000')
21
+ end
22
+ end
23
+ end
24
+ end
25
+
26
+ # Load all API-specific resources:
27
+ Dir[File.dirname(__FILE__) + '/c7000/*.rb'].each { |file| require file }
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/enclosure_group'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Enclosure group resource implementation on API800 C7000
18
+ class EnclosureGroup < OneviewSDK::API600::C7000::EnclosureGroup
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/ethernet_network'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Ethernet network resource implementation for API800 C7000
18
+ class EthernetNetwork < OneviewSDK::API600::C7000::EthernetNetwork
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,39 @@
1
+ # (C) Copyright 2016 Hewlett Packard Enterprise Development LP
2
+ #
3
+ ## Licensed under the Apache License, Version 2.0 (the "License");
4
+ ## You may not use this file except in compliance with the License.
5
+ ## You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ ##
7
+ ## Unless required by applicable law or agreed to in writing, software distributed
8
+ ## under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ ## CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ ## language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../../resource'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Hypervisor Cluster profile resource implementation
18
+ class HypervisorClusterProfile < OneviewSDK::Resource
19
+ BASE_URI = '/rest/hypervisor-cluster-profiles'.freeze
20
+
21
+ # Create a resource object, associate it with a client, and set its properties.
22
+ # @param [OneviewSDK::Client] client The client object for the OneView appliance
23
+ # @param [Hash] params The options for this resource (key-value pairs)
24
+ # @param [Integer] api_ver The api version to use when interracting with this resource.
25
+ def initialize(client, params = {}, api_ver = nil)
26
+ super
27
+ # Default values
28
+ @data['type'] ||= 'HypervisorClusterProfileListV3'
29
+ end
30
+
31
+ # Gets the preview of manual and automatic updates required to make the cluster profile consistent with its template.
32
+ def compliance_preview
33
+ ensure_client && ensure_uri
34
+ @client.response_handler(@client.rest_get(@data['uri'] + '/compliance-preview', {}, @api_version))
35
+ end
36
+ end
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,33 @@
1
+ # (C) Copyright 2018 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+ require_relative '../../../resource'
12
+
13
+ module OneviewSDK
14
+ module API800
15
+ module C7000
16
+ # Hypervisor Manager resource implementation
17
+ class HypervisorManager < OneviewSDK::Resource
18
+ BASE_URI = '/rest/hypervisor-managers'.freeze
19
+
20
+ # Create a resource object, associate it with a client, and set its properties.
21
+ # @param [OneviewSDK::Client] client The client object for the OneView appliance
22
+ # @param [Hash] params The options for this resource (key-value pairs)
23
+ # @param [Integer] api_ver The api version to use when interracting with this resource.
24
+ def initialize(client, params = {}, api_ver = nil)
25
+ super
26
+ # Default values
27
+ @data['hypervisorType'] ||= 'Vmware'
28
+ @data['type'] ||= 'HypervisorManagerV2'
29
+ end
30
+ end
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/scope'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Scope resource implementation for API800 C7000
18
+ class Scope < OneviewSDK::API600::C7000::Scope
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/server_hardware_type'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Server hardware type resource implementation for API800 C7000
18
+ class ServerHardwareType < OneviewSDK::API600::C7000::ServerHardwareType
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/server_profile'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Server Profile resource implementation on API800 C7000
18
+ class ServerProfile < OneviewSDK::API600::C7000::ServerProfile
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,33 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/c7000/server_profile_template'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module C7000
17
+ # Server Profile Template resource implementation on API800 C7000
18
+ class ServerProfileTemplate < OneviewSDK::API600::C7000::ServerProfileTemplate
19
+
20
+ # Create a resource object, associate it with a client, and set its properties.
21
+ # @param [OneviewSDK::Client] client The client object for the OneView appliance
22
+ # @param [Hash] params The options for this resource (key-value pairs)
23
+ # @param [Integer] api_ver The api version to use when interracting with this resource.
24
+ def initialize(client, params = {}, api_ver = nil)
25
+ @data ||= {}
26
+ # Default values
27
+ @data['type'] ||= 'ServerProfileTemplateV5'
28
+ super
29
+ end
30
+ end
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,27 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ module OneviewSDK
13
+ module API800
14
+ # Module for API800 Synergy
15
+ module Synergy
16
+ # Get resource class that matches the type given
17
+ # @param [String] type Name of the desired class type
18
+ # @return [Class] Resource class or nil if not found
19
+ def self.resource_named(type)
20
+ OneviewSDK::API800.resource_named(type, 'Synergy')
21
+ end
22
+ end
23
+ end
24
+ end
25
+
26
+ # Load all API-specific resources:
27
+ Dir[File.dirname(__FILE__) + '/synergy/*.rb'].each { |file| require file }
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/synergy/enclosure_group'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Enclosure group resource implementation on API800 Synergy
18
+ class EnclosureGroup < OneviewSDK::API600::Synergy::EnclosureGroup
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/synergy/ethernet_network'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Ethernet network resource implementation for API800 Synergy
18
+ class EthernetNetwork < OneviewSDK::API600::Synergy::EthernetNetwork
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../c7000/hypervisor_cluster_profile'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Hypervisor cluster profile resource implementation for API800 Synergy
18
+ class HypervisorClusterProfile < OneviewSDK::API800::C7000::HypervisorClusterProfile
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2018 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../c7000/hypervisor_manager'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Hypervisor Manager resource implementation
18
+ class HypervisorManager < OneviewSDK::API800::C7000::HypervisorManager
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api300/synergy/os_deployment_plan'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Network set resource implementation for API800 Synergy
18
+ class OSDeploymentPlan < OneviewSDK::API300::Synergy::OSDeploymentPlan
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../c7000/scope'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Scope resource implementation for API800 Synergy
18
+ class Scope < OneviewSDK::API800::C7000::Scope
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api600/synergy/server_hardware_type'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Server hardware type resource implementation for API800 Synergy
18
+ class ServerHardwareType < OneviewSDK::API600::Synergy::ServerHardwareType
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,25 @@
1
+ # (c) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../../api300/synergy/server_profile'
13
+ require_relative '../c7000/server_profile'
14
+
15
+ module OneviewSDK
16
+ module API800
17
+ module Synergy
18
+ # Server profile resource implementation for API800 Synergy
19
+ class ServerProfile < OneviewSDK::API600::C7000::ServerProfile
20
+ extend OneviewSDK::API300::Synergy::SASLogicalJBODHelper
21
+ include OneviewSDK::API300::Synergy::ServerProfileHelper
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,22 @@
1
+ # (C) Copyright 2017 Hewlett Packard Enterprise Development LP
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # You may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ #
7
+ # Unless required by applicable law or agreed to in writing, software distributed
8
+ # under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9
+ # CONDITIONS OF ANY KIND, either express or implied. See the License for the specific
10
+ # language governing permissions and limitations under the License.
11
+
12
+ require_relative '../c7000/server_profile_template'
13
+
14
+ module OneviewSDK
15
+ module API800
16
+ module Synergy
17
+ # Server Profile Template resource implementation for API800 Synergy
18
+ class ServerProfileTemplate < OneviewSDK::API800::C7000::ServerProfileTemplate
19
+ end
20
+ end
21
+ end
22
+ end
@@ -11,5 +11,5 @@
11
11
 
12
12
  # Gem version defined here
13
13
  module OneviewSDK
14
- VERSION = '5.6.0'.freeze
14
+ VERSION = '5.7.0'.freeze
15
15
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oneview-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.6.0
4
+ version: 5.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henrique Diomede
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2018-06-15 00:00:00.000000000 Z
14
+ date: 2019-02-22 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: thor
@@ -590,6 +590,26 @@ files:
590
590
  - lib/oneview-sdk/resource/api600/synergy/volume_snapshot.rb
591
591
  - lib/oneview-sdk/resource/api600/synergy/volume_template.rb
592
592
  - lib/oneview-sdk/resource/api600/synergy/web_server_certificate.rb
593
+ - lib/oneview-sdk/resource/api800.rb
594
+ - lib/oneview-sdk/resource/api800/c7000.rb
595
+ - lib/oneview-sdk/resource/api800/c7000/enclosure_group.rb
596
+ - lib/oneview-sdk/resource/api800/c7000/ethernet_network.rb
597
+ - lib/oneview-sdk/resource/api800/c7000/hypervisor_cluster_profile.rb
598
+ - lib/oneview-sdk/resource/api800/c7000/hypervisor_manager.rb
599
+ - lib/oneview-sdk/resource/api800/c7000/scope.rb
600
+ - lib/oneview-sdk/resource/api800/c7000/server_hardware_type.rb
601
+ - lib/oneview-sdk/resource/api800/c7000/server_profile.rb
602
+ - lib/oneview-sdk/resource/api800/c7000/server_profile_template.rb
603
+ - lib/oneview-sdk/resource/api800/synergy.rb
604
+ - lib/oneview-sdk/resource/api800/synergy/enclosure_group.rb
605
+ - lib/oneview-sdk/resource/api800/synergy/ethernet_network.rb
606
+ - lib/oneview-sdk/resource/api800/synergy/hypervisor_cluster_profile.rb
607
+ - lib/oneview-sdk/resource/api800/synergy/hypervisor_manager.rb
608
+ - lib/oneview-sdk/resource/api800/synergy/os_deployment_plan.rb
609
+ - lib/oneview-sdk/resource/api800/synergy/scope.rb
610
+ - lib/oneview-sdk/resource/api800/synergy/server_hardware_type.rb
611
+ - lib/oneview-sdk/resource/api800/synergy/server_profile.rb
612
+ - lib/oneview-sdk/resource/api800/synergy/server_profile_template.rb
593
613
  - lib/oneview-sdk/resource_helper.rb
594
614
  - lib/oneview-sdk/rest.rb
595
615
  - lib/oneview-sdk/scmb.rb
@@ -616,7 +636,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
616
636
  version: '0'
617
637
  requirements: []
618
638
  rubyforge_project:
619
- rubygems_version: 2.6.11
639
+ rubygems_version: 2.7.6
620
640
  signing_key:
621
641
  specification_version: 4
622
642
  summary: Gem to interact with the HPE OneView API