-
Notifications
You must be signed in to change notification settings - Fork 192
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
Move the functionality of aiida.cmdline.utils.common.get_database_summary
to StorageBackend.get_info
#5384
Comments
I would be more specific here and say, after #5331, |
aiida.cmdline.utils.common.get_database_summary
to StorageBackend.get_info
aiida.cmdline.commands.cmd_storage.storage_info
and PsqlDosBackend.get_info
In the end the docstring is correct and the method was adapted, so we can remove the bug tag. But thanks for the "specificity" and the preemptive concern, I guess. |
aiida.cmdline.commands.cmd_storage.storage_info
and PsqlDosBackend.get_info
aiida.cmdline.utils.common.get_database_summary
to StorageBackend.get_info
(quote from the original PR) @sphuber anyways this is not a priority right now for 2.0 no? Since this is mostly internal re-organization. |
It is not, but it is easy enough that I will do it soon anyway I think |
Ok, I still think there might be some merit in discussing how to balance the prospect of having this command output more "unpredictable" information specific to the backend and more "reliable" and backend agnostic statistics. For example, the current stats that the summary outputs are the aiida nodes, which is a general concept that is independent of the backend, so I don't think it is a bad idea to also get this information in an agnostic way (even though, as you mentioned elsewhere, it might not be the most ideally performant way). |
@ramirezfranciscof makes sense. See #5387 for a suggestion. I think this possibly addresses your concerns. |
The
get_database_summary
is currently used inverdi storage info
andverdi archive inspect
. Both of these essentially give an overview of the storage contents. For historical reason, the functionality of getting the info was split in the database and repository, but these are now unified in theStorageBackend
. The functionality ofget_database_summary
should therefore be moved intoStorageBackend.get_info
.Note that
get_database_summary
currently just uses the ORM and so is technically already independent of theStorageBackend
, but there might still be an advantage to put it inStorageBackend.get_info
anyway, because certain backends may have more efficient ways of retrieving the information other than going through the ORM which might be adding unnecessary overhead.The text was updated successfully, but these errors were encountered: