Move project hook code into Git::{Base,Branch,Tag}HooksService
The following discussion from gitlab-ce!26726 should be addressed:
-
@nick.thomas started a discussion: (+1 comment) In a follow-up issue, I'd like to look at how much of the code we call here can be moved into
HooksService. It's not obviously model code.
Currently, we call, e.g., project.execute_hooks and project.execute_services from the Git push service.
I'm hopeful that we can move most of this dependent code out of the model and into the service, especially for cases that are only called from other services.
The benefits here are in making the code more obvious, and reducing the total size of app/models/project.rb (in particular)
Edited by 🤖 GitLab Bot 🤖