Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ListVolumeQoSHistograms should probably ignore invalid requests #63

Open
scaleoutsean opened this issue May 3, 2024 · 0 comments
Open

Comments

@scaleoutsean
Copy link
Contributor

Asking for QoS histograms for 2 volumes, I get 32 back:

>>> params= {"VolumeIDs": [1]}
>>> qosh = sfe.invoke_sfapi("ListVolumeQoSHistograms", parameters=params)['qosHistograms']
2024-05-03 13:52:19,323 - solidfire.Element - INFO - {"method": "ListVolumeQoSHistograms", "id": 58, "params": {"VolumeIDs": [1]}}
>>> len(qosh)
32

After 2 hours of digging from the app to logic to API, another try:

>>> params = {"volumeIDs": [1, 2]}
>>> qosh = sfe.invoke_sfapi("ListVolumeQoSHistograms", parameters=params)['qosHistograms']
2024-05-03 13:52:01,419 - solidfire.Element - INFO - {"method": "ListVolumeQoSHistograms", "id": 57, "params": {"volumeIDs": [1, 2]}}
>>> len(qosh)
2

If you specify VolumeIDs instead of volumeIDs, you get all histograms back.

The API should probably warn or outright reject invalid params. Even if it's not a "bug" (SolidFire Python SDK docs don't say anything on this behavior and especially in this case it's invoke_sfapi and not some specific function), some users who come across this issue on Github may save time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant