[Improvement] Question about the JSON Event Log
- Dominant language
- Scala
- Stars
- 2.4k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
### Code of Conduct
- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
### Search before asking
- [X] I have searched in the [issues](https://github.com/apache/kyuubi/issues?q=is%3Aissue) and found no similar issues.
### What would you like to be improved?
https://github.com/apache/kyuubi/blob/6fc7552ef05c83cfb8a2cd56d80c02c6e8a033c7/kyuubi-events/src/main/scala/org/apache/kyuubi/events/handler/JsonLoggingEventHandler.scala#L94
In some cases, the current JSON event will not append files when writing, but will clear the file content to continue writing. For example, after the start event of kyuubi server is triggered, server - ${ip}. json will be cleared, resulting in the loss of previous event logs.
Is this design because the eventlog cannot automatically expire and delete?
### How should we improve?
Can configuration be added to control whether the event needs to append file writing.
### Are you willing to submit PR?
- [X] Yes. I would be willing to submit a PR with guidance from the Kyuubi community to improve.
- [ ] No. I cannot submit a PR at this time.
Contributor guide
Research direction
Start with kyuubi-events/src/main/scala/org/apache/kyuubi/events/handler/JsonLoggingEventHandler.scala around line 94 and inspect how the server event log file is opened and written. Trace the related event-log configuration and tests, then define completion as a configuration-controlled append behavior that prevents existing JSON event content from being lost.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- scala
- Domain
- observability-sre
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100