front: add debug interface to access logged data#16301
Conversation
|
67dc239 to
703afe7
Compare
bougue-pe
left a comment
There was a problem hiding this comment.
Major QoL improvement ❤️
|
At first, I had really no opinion (between connecting However, there is still the architecture risk of having 2 different services accessing the S3 concurrently. Today, it’s not entirely a problem since |
I'm not completely sure what you mean? Both
|
|
I rebased and squashed the commits. I didn't really manage to distribute the fixups added during with the reviews over their relevant commits, I spend a couple hours on that and still ended up with invalid states on intermediate commits. As for the s3 connected to core or editoast, I removed the last commit and leave it as it was originally: editoast is connected to the object storage when the env variables are set and it fetches the data. If editoast is missing the s3 config or it hasn't started yet, editoast starts normally, and the endpoint returns an error when accessed. |
flomonster
left a comment
There was a problem hiding this comment.
Thanks for this PR, I reviewed editoast part only.
- I did not find a button to go to
/stdcm/debugis it expected to craft url? - What is the usual size of
output_simulation_data.json. Do we expect ram usage spike?
|
@eckter I tried to test, this feature and I could not find the trace id. Probably because tracing is not enabled for one of my services, do we have to enable something? If so it could be nice to change the default config in docker-compose (can be done in follow-up PR). |
Ah yes,
(edit: all good) |
|
Oh I didn't see this comment
It's missing when the front doesn't know the trace_id, it would be missing from the pdf as well. That's likely because of the
It depends a lot on the path, it technically scales with Of all the 66 simulations I've run locally with telemetry, the largest one is 13MB, second largest 6MB, average 1MB, median 0.3MB |
SharglutDev
left a comment
There was a problem hiding this comment.
Great job ! Didn't have time to test it but looks like enough people did.
All the comments are very nitty and rather there to stick more to the rest of the front codebase but feel free to ignore what you want. You can close the comment as pleased.
Okay
Good to know, it's not that heavy. |
SharglutDev
left a comment
There was a problem hiding this comment.
Thanks for fixing the comments ✅
flomonster
left a comment
There was a problem hiding this comment.
Tested and everything works fine.
warning: vibe coded and not proofread yet, just tested Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Signed-off-by: Eloi Charpentier <eloi.charpentier.42@gmail.com>
Disclamer: the code was mostly LLM generated at first, but I did carefully review everything. And it's just for parts I'm not familiar with, and just the code, this description is written normally.
(for the record, I kind of regret doing it that way for the front-end changes, but it's hard to go back and rewrite it from scratch now)
I recommend reviewing per file and not per commit, as I didn't manage to distribute the review comments over their matching commits. I did try to fix the history and the result was mostly correct but still left a few commits in an invalid state, it would take quite a lot of time to entirely fix it.
Change summary:
/stdcm/debug, with:Minor changes to existing code:
Not included (yet) but could be added later on:
How to test the happy path:
./osrd-compose telemetry ...Link to debug page with more simulation detailslink at the bottom. It's discreet.How to test the not happy paths:
No automated test has been included, it's a POC / MVP and this version is intended for internal use by the OSRD team. Front-end / E2E tests are a bit tedious to setup and would be overkill here (in my opinion at least).
The new page looks like this. It's not fancy but it does its job
Accessing /stdcm/debug directly looks like this: