Update 13.4.md

typographical errors and improved readability
This commit is contained in:
Jimmy99
2016-04-06 20:54:32 +02:00
parent c909856abb
commit b77caaaff8

View File

@@ -4,11 +4,11 @@
Previously in the book, we saw that event logging plays a very important role in application development. With adequate logging, we can record crucial information that can later be dissected for debugging and optimization purposes. In the section where we looked at the seelog logging utility, we saw that it had settings for various log level gradations, which can be essential for program development and deployment; we can set the logging level lower in a development environment, while setting it high in production so that we can mask extraneous information when we are trying to debug our application.
Setting up server configuration module for deploying an application involves a number of different server settings. For example, we typically need to provide information regarding database configuration, listening ports, etc., via the configuration file. Setting up a centralized configuration file allows us the flexibility of deploying on different machines and connecting to remote databases, if needed.
Setting up the server configuration module for deploying an application involves a number of different server settings. For example, we typically need to provide information regarding database configuration, listening ports, etc., via the configuration file. Setting up a centralized configuration file allows us the flexibility of deploying the application to different machines and connecting to remote databases, if needed.
## The Beego logging system
The Beego logger's design borrows ideas from seelog provides similar functionality in terms of setting logging levels. Beego's system is, however, more lightweight and makes use of the Go's `log.Logger` interface. By default, logs are outputted to os.Stdout, but users can implement this interface through `beego.SetLogger` to customize this. A detailed example of an implemented interface can be seen below:
The Beego logger's design borrows ideas from seelog and provides similar functionality in terms of setting logging levels. Beego's system is, however, more lightweight and makes use of the Go's `log.Logger` interface. By default, logs are output to os.Stdout, but users can implement this interface through `beego.SetLogger` to customize this. A detailed example of an implemented interface can be seen below:
// Log levels for controlling the logging output.
const (