logger

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 17, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

View Source
const (
	LoggerConfigInitFailedMsg  = "while initializing configuration got"
	AppLoggerInitFailedMsg     = "application logger could not be initialized, because"
	MoleLoggerInitFailedMsg    = "mole logger could not be initialized, because"
	BuildingZapFieldsFailedMsg = "while compiling logger options"
)

Variables

View Source
var (
	ErrBuildingZapFieldsFailed = errors.New(BuildingZapFieldsFailedMsg)
)

Log is the global logger for Mole

Mole is the logger for matches

Functions

func New

func New() (err error)

New returns a new logger based on the configuration provided

Types

type Config

type Config struct {
	// LogTo where the logger will write to
	LogTo string
	// LogLevel logger level. This can take info, error, warning, and debug
	LogLevel string

	MoleLogger MoleLogger
}

Config logger internal configuration

func InitConfig

func InitConfig() (*Config, error)

InitConfig initializes logger package

type MoleLogger

type MoleLogger struct {
	To     string
	Format string
}

Directories

Path Synopsis
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL