elastic / elastic/ecs-logging-python

how to prefix structlog log value with "custom." or route them to a certain ecs field

オープン
#52 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
agent-python
主要言語
Python
スター
74
フォーク
33
平均マージ
9時間 3分
マージ済み PR(30日)
1

説明

Hi,
according to the ecs documentation non ecs standard fields should go under "custom."
Also I might log data that should go to a certain ecs field

but i'm not sure how to configure something like this in structlog/ecs-logging.

for example this:
```python
req_id = uuid()
...
logger.info("something happend", foo="123", request_id=req_id)

```
should end up being something like this:
```json
{
"http.request.id" : "",
"message": "something happend",
"custom.foo" : 123
...
}
```

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。