Python library for configuring logs in the FIAAS way
Project description
This library configures logging according to the current FIAAS recomended format.
Usage:
from fiaas_logging import init_logging init_logging(format="json")
This would configure your application to emit JSON formatted logs on STDOUT.
Available options (all are keyword arguments to init_logging):
Key |
Possible values |
Meaning |
|---|---|---|
format |
json/plain |
Select either JSON logging, or plain text logging |
debug |
True/False |
Enable debug logging |
The plain format contains the fields timestamp, level name, message, logger name, and thread name. In the json format, there are more fields, with more detail. The fields in the json output are:
Name |
Meaning |
|---|---|
@timestamp |
Timestamp of message |
@version |
Version, legacy field to support ELK stack at FINN (to be removed?) |
LocationInfo |
A structure describing the code location that logged this message |
message |
The actual log message |
extras |
A structure containing extra fields. Used for thread context |
throwable |
A formatted stacktrace if the log message is the result of an exception |
Changes since last version
7d96bdc: Add pip cache to gitignore
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fiaas-logging-0.1.1.tar.gz.
File metadata
- Download URL: fiaas-logging-0.1.1.tar.gz
- Upload date:
- Size: 12.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
436c6448f15307cd79552ef1035f4f69c5fb6e0586ab01d55847b3e6cf2717e5
|
|
| MD5 |
6b6eeea43c9df7a942af65fc175f635e
|
|
| BLAKE2b-256 |
93d34c34df421a5c1cc704175c8547d99c57cc185ef81baaa449b0ae34de73d0
|
File details
Details for the file fiaas_logging-0.1.1-py2.py3-none-any.whl.
File metadata
- Download URL: fiaas_logging-0.1.1-py2.py3-none-any.whl
- Upload date:
- Size: 8.6 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
47bf999d3734f066fe9911bbc65dbae2576790554e22038615f802322f10b9c1
|
|
| MD5 |
3d6b86fbd7a94a06eab2482634f34262
|
|
| BLAKE2b-256 |
3ca4bf2b48bf3c8e8e85521a3660f6c0ac65fa1cf51e7b361b95d5e6618134de
|