-
Notifications
You must be signed in to change notification settings - Fork 155
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
Get more than 100 Releases #169
Comments
Thanks for the detailed issue. I will ping the team and see what we can do about this. |
So I have good news and bad news. Good news is there is a thread going internally to get to the bottom of this. Bad news this API call for releases is not implemented correctly at the moment. Once it is corrected we can add support. |
This change is going to take a bit of work. The code currently uses Invoke-RestMethod and only in PowerShell Core does that call give you access to the returned headers. I just did some quick testing and I can change the code to still work in 5.x but you can't get to the headers there. This feature would only be supported in 6 or later. Even with that it will take time to surface the continuation token up the stack so the caller will have access to it to pass to subsequent calls to get the rest of the items. There is a second method of paging at APIs in AzD can support using $Top and $Skip. However, the Release API only supports $Top at the moment and not $Skip. I have an email into the team to see if they plan to add the $Skip parameter support as well. If so that will be a much faster fix. |
any update on that? I can try to implement something if the team was already able to fix the issue. |
I rolled my own Get-VSTSRelease that indirectly calls Invoke-WebRequest as a workaround, but the effort to integrate it with (or conditionally circumvent) vsteam's _callAPI is a bit daunting. |
Agreed. I am looking into other options as well. There have been internal threads on how the API has implemented this. |
Are there any plans to move to PSCore? That would also solve the problem, wouldn't it? |
_Originally posted by @stefanstranger in #35
The REST API includes an x-ms-continuationtoken response header that, unfortunately, is not readily accessible when using Invoke-RestMethod. In order to access the response header(s) it may be necessary to use Invoke-WebRequest (or similar).
Steps to reproduce
Expected behavior
Actual behavior
Environment data
OS
Server
The text was updated successfully, but these errors were encountered: