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

API links collection for environment machines missing id #4052

Closed
MarkSiedle opened this issue Dec 7, 2017 · 6 comments
Closed

API links collection for environment machines missing id #4052

MarkSiedle opened this issue Dec 7, 2017 · 6 comments
Assignees
Labels
kind/bug This issue represents a verified problem we are committed to solving
Milestone

Comments

@MarkSiedle
Copy link

MarkSiedle commented Dec 7, 2017

When searching for machines in a given environment, the links collection that is returned from the API is missing the environmentId in everything except the "Template". In our web-portal, we load all and then do local-paging ourself (so we don't use these paging links), but other clients may be expecting these to work (E.g. wanting to do this from PowerShell via Octopus.Clients is a very likely case).

Note: the missing /{id}/ and filter parameters for the various Self and Page. links.

{
"ItemType": "Machine",
"IsStale": false,
"TotalResults": 0,
"ItemsPerPage": 20,
"NumberOfPages": 1,
"LastPageNumber": 0,
"Items": [],
"Links": {
"Self": "/api/environments//machines",
"Template": "/api/environments/{id}/machines{?skip,take,partialName,roles,isDisabled,healthStatuses,commStyles,tenantIds,tenantTags}",
"Page.All": "/api/environments//machines?skip=0&take=2147483647",
"Page.Current": "/api/environments//machines?skip=0&take=20",
"Page.Last": "/api/environments//machines?skip=0&take=20"
}
}

We are handling this situation correctly in other other similar endpoints, such as /api/projects/Projects-341/Releases, so we will need to match this Links collection logic for environment machines.

Source: https://help.octopusdeploy.com/discussions/problems/65461
Source: https://help.octopusdeploy.com/discussions/problems/65459
Source: https://help.octopusdeploy.com/discussions/problems/65832
Related: OctopusDeploy/OctopusClients#213

@MarkSiedle MarkSiedle added area/execution kind/bug This issue represents a verified problem we are committed to solving labels Dec 7, 2017
@josepw
Copy link

josepw commented Jan 4, 2018

Is there a patch for this yet? I used these links to auto provision monitoring.

@octoreleasebot
Copy link

Release Note: Fixes for paging parameters in API link collections

@MarkSiedle
Copy link
Author

Hi @josepw, yes a fix for this will be included in the next minor release.

@josepw
Copy link

josepw commented Jan 8, 2018

Which specific version should I look for?

@matt-richardson
Copy link
Contributor

It will be in 4.1.8. The milestone on this issue is the release it's linked to.

@lock
Copy link

lock bot commented Nov 24, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. If you think you've found a related issue, please contact our support team so we can triage your issue, and make sure it's handled appropriately.

@lock lock bot locked as resolved and limited conversation to collaborators Nov 24, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug This issue represents a verified problem we are committed to solving
Projects
None yet
Development

No branches or pull requests

4 participants