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

Set Limit for /services GET to be at most 100 results #39

Merged
merged 1 commit into from
Sep 28, 2017

Conversation

ashmckenzie
Copy link
Contributor

We have a lot of services (75) in our PagerDuty account. I noticed when performing an import I kept getting the error message Could not locate a service ID for the integration.

The root cause of the error was that the provider was only returning max 25 (default) services. I added a limit of 100 to the /services GET. A more complete solution would be to correctly handling pagination however.

@heimweh
Copy link
Collaborator

heimweh commented Sep 26, 2017

Hi @ashmckenzie,

huge thanks for this PR! pagination would indeed be nicer here, but for now this LGTM 👍

Thanks again!

Best,
Alexander

@heimweh heimweh merged commit 8def19d into PagerDuty:master Sep 28, 2017
@ashmckenzie ashmckenzie deleted the list-more-services branch October 1, 2017 22:04
@ashmckenzie
Copy link
Contributor Author

Hi @heimweh - any chance of a 0.1.3 release? Keen to see this plus the https://github.com/terraform-providers/terraform-provider-pagerduty/pull/38 GA 🙏

@pdecat
Copy link
Contributor

pdecat commented Nov 6, 2017

Note that this prevents importing services which are not returned in the first hundred page.

I think I've got a better solution in https://github.com/terraform-providers/terraform-provider-pagerduty/pull/47

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

Successfully merging this pull request may close these issues.

3 participants