diff options
author | Dylan Griffith <dyl.griffith@gmail.com> | 2018-11-23 16:15:52 +0100 |
---|---|---|
committer | Dylan Griffith <dyl.griffith@gmail.com> | 2018-11-23 16:15:52 +0100 |
commit | 629b1e6b17d3db2c4f9e3b1405796767440e6bcb (patch) | |
tree | 1e8c35ce6515d0171c4c5ffaf30e268edf4e5d92 /doc | |
parent | 0a42c7cbaae51466a67a4011859726c29bc24da4 (diff) | |
download | gitlab-ce-629b1e6b17d3db2c4f9e3b1405796767440e6bcb.tar.gz |
Correct errors in doc/development/logging.md
Diffstat (limited to 'doc')
-rw-r--r-- | doc/development/logging.md | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/development/logging.md b/doc/development/logging.md index abd08c420da..5c1d96b9e0c 100644 --- a/doc/development/logging.md +++ b/doc/development/logging.md @@ -75,7 +75,7 @@ To create a new file: module Import class Logger < ::Gitlab::JsonLogger def self.file_name_noext - 'importer_json' + 'importer' end end end @@ -105,7 +105,7 @@ To create a new file: ```ruby # GOOD - logger.info("Unable to create project", project_id: project.id) + logger.info(message: "Unable to create project", project_id: project.id) ``` 1. Be sure to create a common base structure of your log messages. For example, @@ -118,13 +118,13 @@ To create a new file: ```ruby # BAD - logger.info("Import error", error: 1) - logger.info("Import error", error: "I/O failure") + logger.info(message: "Import error", error: 1) + logger.info(message: "Import error", error: "I/O failure") ``` ```ruby # GOOD - logger.info("Import error", error_code: 1, error: "I/O failure") + logger.info(message: "Import error", error_code: 1, error: "I/O failure") ``` ## Additional steps with new log files |