-
Notifications
You must be signed in to change notification settings - Fork 941
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
Change Build Triggers to PipelinTriggers. #152
Change Build Triggers to PipelinTriggers. #152
Conversation
See documentation for expected return statuses: https://docs.gitlab.com/ce/api/README.html#status-codes Also change the codes to http library codes.
This is in line with the updated v4 API. See https://docs.gitlab.com/ce/api/pipeline_triggers.html and https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/9713 for more information.
All changed functions tested against a v4 GitLab API. |
@johanbrandhorst the code looks fine, but I would suggest creating a dedicated service for the PipelineTriggers ( FYI I try to follow (more or less) the segmentation Gitlab uses to describe different parts of the API: https://docs.gitlab.com/ce/api/README.html#resources |
OK I will update it. I thought since it was under |
That also makes sense, I just choose to follow the docs and by that also limit the file sizes a bit. Thanks! |
Creates the new service PipelineTriggersService for handling requests to the Pipeline Triggers part of the GitLab API.
Looks great! Thanks 👍 |
* Add StatusNoContent as successful status. See documentation for expected return statuses: https://docs.gitlab.com/ce/api/README.html#status-codes Also change the codes to http library codes. * Change Build Triggers to PipelinTriggers. This is in line with the updated v4 API. See https://docs.gitlab.com/ce/api/pipeline_triggers.html and https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/9713 for more information. * Move Pipeline Triggers to a separate file. Creates the new service PipelineTriggersService for handling requests to the Pipeline Triggers part of the GitLab API.
* Add StatusNoContent as successful status. See documentation for expected return statuses: https://docs.gitlab.com/ce/api/README.html#status-codes Also change the codes to http library codes. * Change Build Triggers to PipelinTriggers. This is in line with the updated v4 API. See https://docs.gitlab.com/ce/api/pipeline_triggers.html and https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/9713 for more information. * Move Pipeline Triggers to a separate file. Creates the new service PipelineTriggersService for handling requests to the Pipeline Triggers part of the GitLab API.
This is in line with the updated v4 API. See https://docs.gitlab.com/ce/api/pipeline_triggers.html and https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/9713 for more information.
Also add StatusNoContent as successful status and update hardcoded status codes to
http.Status*
codes.