Skip to content

Commit

Permalink
Log errors in UpdatePagesService
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrgn committed Mar 31, 2017
1 parent 47cc1fe commit b700a84
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/services/base_service.rb
Expand Up @@ -24,6 +24,10 @@ def log_info(message)
Gitlab::AppLogger.info message
end

def log_error(message)
Gitlab::AppLogger.error message
end

def system_hook_service
SystemHooksService.new
end
Expand Down
1 change: 1 addition & 0 deletions app/services/projects/update_pages_service.rb
Expand Up @@ -46,6 +46,7 @@ def success
end

def error(message, http_status = nil)
log_error("Projects::UpdatePagesService: #{message}")
@status.allow_failure = !latest?
@status.description = message
@status.drop
Expand Down
4 changes: 4 additions & 0 deletions changelogs/unreleased/pages-debug-log.yml
@@ -0,0 +1,4 @@
---
title: Log errors during generating of Gitlab Pages to debug log
merge_request: 10335
author: Danilo Bargen

0 comments on commit b700a84

Please sign in to comment.