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

Provide mechanism for paging #3481

Closed
troydai opened this issue May 26, 2017 · 12 comments
Closed

Provide mechanism for paging #3481

troydai opened this issue May 26, 2017 · 12 comments

Comments

@troydai
Copy link
Contributor

troydai commented May 26, 2017

A paging mechanism is helpful when a command needs to process large operation results. It should reduce the memory pressure and improve UI responsiveness.

@troydai
Copy link
Contributor Author

troydai commented Jul 10, 2017

After investigation I found this feature requires SDK improvement: Azure/azure-sdk-for-python#1296

@troydai troydai added this to the Sprint 19 milestone Jul 10, 2017
@troydai troydai self-assigned this Jul 10, 2017
@lmazuel
Copy link
Member

lmazuel commented Jul 10, 2017

@troydai or not :)

I return an iterator, and you cast it as a list :)

@troydai
Copy link
Contributor Author

troydai commented Jul 10, 2017

Misread the code. You're right.

@lmazuel
Copy link
Member

lmazuel commented Jul 10, 2017

@troydai no problem! You'll get me next time for sure :p

@squillace
Copy link

@troydai, @lmazuel, where are we on this? I need this command to work, as documented.... it appears as if this was just taken on here: #3323. True?

@karungithub
Copy link

Add on to this - I could not find if Azure Storage or compute REST API for some of the listing commands (like VM list) supports paging. If anyone knows the options to use in a REST call to get a paged list of elements, that would be really helpful. Thanks.

@lmazuel
Copy link
Member

lmazuel commented Oct 2, 2017

@karungithub The paging mechanism of ARM is described here:
https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/resource-api-reference.md#get-resource

If you don't have "nextLink" in the documentation or in what you get from Azure. or the "top" parameter, this probably means that the service does not support paging for this operation.

@seanknox
Copy link
Contributor

seanknox commented Apr 6, 2018

Hey folks, this continues to a major problem for customers/Microsoft employees needing to managing many app registrations. Without a viable CLI alternative, the portal experience exposes users to accidentally deleting the wrong app registrations.

@troydai
Copy link
Contributor Author

troydai commented Apr 6, 2018

@seanknox thanks for the feedback. The SDK's paging mechanism acts like a linked list, meaning you can only travel through the entities in one direction page by page. There is no random access. Does this mechanism help the customers?

@seanknox
Copy link
Contributor

seanknox commented Apr 6, 2018

No, unfortunately. See the discussion here: #1150

@troydai
Copy link
Contributor Author

troydai commented Apr 6, 2018

Thank you for pointing to this. Depends on the type of resources, we may provide different solutions. However, the difficult part is to make the change intuitive and usable. We may need to work with service team on this.

@yugangw-msft
Copy link
Contributor

Hey folks, this continues to a major problem for customers/Microsoft employees needing to managing many app registrations

I will fix this through filters such --mine to avoid using unconditional list, which is more or less usage error. Even we have the paging, going through thousands of pages won't really help you find the one you are looking for. See details in #1150

I am closing this, as we will have a different way to fix this

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

No branches or pull requests

8 participants