django-github-hook icon indicating copy to clipboard operation
django-github-hook copied to clipboard

Hook model vs. signal use cases

Open sheppard opened this issue 11 years ago • 0 comments

As discussed in #3 and #6, there are now two somewhat distinct use cases for this codebase:

  • One case is the "signal-centric" approach, that always sends a signal when a payload is recieved
  • A second case is the "model-centric" approach, which uses the Hook model to evaluate the payload and then either send a signal or execute a shell script (the latter being the original use case).

At one point, I proposed moving the model processing code to an optional signal reciever. However, #6 indicates that there is some value in preserving the model code in the view, as a way to filter incoming requests.

My current proposal is to create two views, one for each of the above use cases. For backwards compatibility, the second view would be the one referenced in github_hook.urls.

sheppard avatar Sep 26 '14 17:09 sheppard