This functionality would be especially useful for harbor-cli, which has several commands, such as auditlog list, where it's natural to have a --limit option to set a limit for how many resources to fetch/print.
Furthermore, limit is a more intuitive interface than the current parameter retrieve_all, which is just a bad name for "follow pagination".
This change should affect all methods that fetch multiple resources, such as get_repositories, get_projects, get_audit_logs, etc. Basically any methods that have page and page_size parameters.
A limit of None and/or 0 should disable the limit and behave as the current retrieve_all.
This functionality would be especially useful for harbor-cli, which has several commands, such as
auditlog list
, where it's natural to have a--limit
option to set a limit for how many resources to fetch/print.Furthermore,
limit
is a more intuitive interface than the current parameterretrieve_all
, which is just a bad name for "follow pagination".This change should affect all methods that fetch multiple resources, such as
get_repositories
,get_projects
,get_audit_logs
, etc. Basically any methods that havepage
andpage_size
parameters.A limit of
None
and/or0
should disable the limit and behave as the currentretrieve_all
.