Event API for structured logging? #417
Replies: 3 comments 6 replies
-
Hello @holgerbrandl. I see your point and I like the idea. It would also come some way towards solving another pain point, #399. I think there's currently no reliable other way to get at this data from code. We'll have to think about this a bit more, consider any downsides and impacts on other parts of the codebase, but at the moment I think that this should be relatively easy to do. |
Beta Was this translation helpful? Give feedback.
-
Good point. I wonder if the move info alone is enough. Probably the event needs to have the working solution too:
And it probably needs step events too. But what do you do with this data? I have a gut feeling that if we implement move streams (huge RFE), the needs for this will change. |
Beta Was this translation helpful? Give feedback.
-
Indeed @ge0ffrey , the event from above was just an example. Currently, we separate the log into different event-streams, build parsers to ingest the various string representations (moves, planning entities, scores), and bring it all back together in R/python to better understand/visualize the solver-process. Having dedicated events would help to streamline this process significantly. We have not thought about any technical implications, it's just an idea we wanted to share/discuss. |
Beta Was this translation helpful? Give feedback.
-
Hi,
I guess as everyone here, we sometimes increase the log level to see what's really happing during construction and search. However, the sheer volume of log data emitted by the engine is often not easy to process. Having multiple data scientists in our team, we could in theory parse the log to study why the solver does not yet perform as intended. We're thinking here about statistics and timelines from various perspectives and angles which are all in the log but not visible by eye/without aggregation.
However, as the log is quite dense and diverse I wonder if these events could also be exposed as structured log? So instead of
timefold-solver/core/core-impl/src/main/java/ai/timefold/solver/core/impl/localsearch/decider/LocalSearchDecider.java
Lines 126 to 129 in 4415f4d
it could do something like
with this structured logging in place, it would be very easy to collect these and write them into csv for analysis. And thus develop solvers with timefold faster and more efficiently.
How do you feel about such an idea? Are there alternatives to collect details move properties and timelines as currently displayed in the unstructured log?
Thanks & Kind regards.
Beta Was this translation helpful? Give feedback.
All reactions