Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kazuhiko Shiozaki
gitlab-ce
Commits
99760edc
Commit
99760edc
authored
Feb 20, 2013
by
Andrew8xx8
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Method moved to service
parent
aa1780d0
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
app/models/system_hook.rb
app/models/system_hook.rb
+0
-3
app/services/system_hooks_service.rb
app/services/system_hooks_service.rb
+5
-1
No files found.
app/models/system_hook.rb
View file @
99760edc
...
...
@@ -12,7 +12,4 @@
#
class
SystemHook
<
WebHook
def
async_execute
(
data
)
Sidekiq
::
Client
.
enqueue
(
SystemHookWorker
,
id
,
data
)
end
end
app/services/system_hooks_service.rb
View file @
99760edc
...
...
@@ -7,10 +7,14 @@ class SystemHooksService
def
self
.
execute_hooks
(
data
)
SystemHook
.
all
.
each
do
|
sh
|
sh
.
async_execute
data
async_execute_hook
sh
,
data
end
end
def
self
.
async_execute_hook
(
hook
,
data
)
Sidekiq
::
Client
.
enqueue
(
SystemHookWorker
,
hook
,
data
)
end
def
self
.
build_event_data
(
model
,
event
)
data
=
{
event_name:
build_event_name
(
model
,
event
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment