Hi, I need structured logging with a slightly diff...
# http4k
d
Hi, I need structured logging with a slightly different format 😕 It should look like:
Copy code
{
   "@timestamp": "2022-06-02T12:00:00.0Z",
   "metadata": {...},
   "event": {...}
}
What would be the best approach? Basically copying whole
events.kt
file and adopt it with a customized
MetadataEvent
? Or is there a better option?
d
You could use a filter to wrap the metadata event at the end of the chain?
(and use a custom event which copies the data from it and has the 3 fields you need
d
Cool, haven’t thought about that option. Thanks for this idea 🎉