Skip to content

Added Support For Storage Site API's#2206

Open
vontedduchaithra wants to merge 4 commits into
masterfrom
storagesite
Open

Added Support For Storage Site API's#2206
vontedduchaithra wants to merge 4 commits into
masterfrom
storagesite

Conversation

@vontedduchaithra

Copy link
Copy Markdown
Contributor

No description provided.

@coveralls

coveralls commented Jun 28, 2026

Copy link
Copy Markdown
Collaborator

Coverage Status

coverage: 77.373%. first build — storagesite into master

Signed-off-by: Vonteddu Chaithra <Vonteddu.Chaithra1@ibm.com>
Signed-off-by: Vonteddu Chaithra <Vonteddu.Chaithra1@ibm.com>
@andy-maier andy-maier self-requested a review July 5, 2026 04:36
@andy-maier andy-maier added this to the 1.26.0 milestone Jul 5, 2026
Comment thread tests/end2end/test_storage_site.py Outdated
@@ -0,0 +1,439 @@
# Copyright 2025 IBM Corp. All Rights Reserved.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please change the copyright year to the current year.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved

Comment thread docs/appendix.rst Outdated
within the FICON storage configuration of a DPM-enabled :term:`CPC`.
A primary site (named "Primary Site") exists by default and cannot be
deleted. An alternate site at a remote location can be created and
deleted.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The existing test does not distinguish sufficiently between the real world storage site and the HMC object representing it.

Also, it seems to suggest that the way one can detect the storage site object for the primary site is by name="Primary Site", when it actually should be detected by type="primary". Also, the name property is writeable, so the name is not a reliable way to detect the primary site object.

To address both of that, I suggest to change the two sentences starting at "A primary site (named "Primary Site") exists by default" to:

A Storage Site object with `type="primary"` always exists for the primary
site and cannot be deleted. Additional Storage Site objects can be created
and deleted.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved

@@ -0,0 +1,294 @@
# Copyright 2025 IBM Corp. All Rights Reserved.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please change the copyright year to the current year.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved

Comment thread zhmcclient/_storage_site.py Outdated
@@ -0,0 +1,318 @@
# Copyright 2025 IBM Corp. All Rights Reserved.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please change the copyright year to the current year.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved

Comment thread zhmcclient/_storage_site.py Outdated
A storage site describes a location that houses a set of storage switches and
storage subsystems. A primary site with a default name of "Primary Site",
local to the CPC, exists by default and cannot be deleted. An alternate site,
typically at a remote location, can be created.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The existing test does not distinguish sufficiently between the real world storage site and the HMC object representing it.

Also, it seems to suggest that the way one can detect the storage site object for the primary site is by name="Primary Site", when it actually should be detected by type="primary". Also, the name property is writeable, so the name is not a reliable way to detect the primary site object.

To address both of that, I suggest to change the two sentences starting at "A primary site (named "Primary Site") exists by default" to:

A Storage Site object with `type="primary"` always exists for the primary
site and cannot be deleted. Additional Storage Site objects can be created
and deleted.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved


# Resource properties that are supported as filter query parameters.
query_props = [
'cpc-uris',

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The query parameter for the cpc-uris property is named cpc-uri.
So far, the assumption in the code is that the property has the same name as the query parameter.

That is not the case here, so you need to add special handling of that to the code, and also make sure there is a testcase for that case. The property name here should probably remain cpc-uris because that will be the property that is specified in the filter_args parameter of list(). The special handling is probably in _list_with_operation() or in divide_filter_args(), but these are very generic methods/functions and you don't want to hard code that case there. I think it requires some more class variable in the StorageSiteManager object to provide the necessary data to these functions. You need to work out how you want to handle that, and we can discuss it in the weekly meeting.

# Resource properties that are supported as filter query parameters.
query_props = [
'cpc-uris',
'name',

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is an additional supported query property: type.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolved

Vonteddu Chaithra added 2 commits July 9, 2026 12:37
Signed-off-by: Vonteddu Chaithra <Vonteddu.Chaithra1@ibm.com>
Signed-off-by: Vonteddu Chaithra <Vonteddu.Chaithra1@ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants