-
Notifications
You must be signed in to change notification settings - Fork 585
Add sample graph data when in dev mode #2698
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: Hariom Gupta <[email protected]>
|
There might be a slight coverage drop because this dynamic import thing is kinda tricky to test. |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2698 +/- ##
=======================================
Coverage 96.67% 96.67%
=======================================
Files 255 255
Lines 7817 7853 +36
Branches 1965 2026 +61
=======================================
+ Hits 7557 7592 +35
Misses 260 260
- Partials 0 1 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Will try adding some sort of test for these lines? Or can we use |
yurishkuro
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please mention the capability in the README somewhere where we describe how to run in dev.
Signed-off-by: Hariom Gupta <[email protected]>
| const selectedLayout = data.length > dagMaxNumServices ? 'sfdp' : 'dot'; | ||
| this.setState({ selectedLayout }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't this logic be in a more generic place? It's not specific to the samples.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makes sense
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is required at this place as changing the graph data wouldn't supply the graph length information to the graph layout selector
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The way I see the workflow is:
- user picks which data to use (including from backend when just navigating to the tab)
- the data load happens
- once the data is loaded/available, but before it's displayed, a check is made for its size and the layout is modified as necessary (or disabled and user is forced to make a focal service selection)
All of the sample datasets should only happen in step 1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently there is this dropdown:
user picks which data to use (including from backend when just navigating to the tab)
If we go with this flow, wouldn't the user (in dev mode) be forced to select an initial dataset, even if they want to just see backend data?
As far as I understand, this is about moving backend data also to this dataset selection dropdown
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, just clicking on the tab should always go to the server first, no forced user selection (although it doesn't matter much since it's in dev only)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
got it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
user is forced to make a focal service selection
Added to this ticket to track progress for this one
For the 1st one, I have centralized the layout selection logic
scripts/utils/parse-traces.js
Outdated
| * results to an output JSON file. | ||
| * | ||
| * Instructions to run this script: | ||
| * 1. Prepare a directory containing OLTP trace JSON files. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
did any of the public data sets already come in OTLP format? The comments could point to it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, will add a link
Signed-off-by: Hariom Gupta <[email protected]>
Signed-off-by: Hariom Gupta <[email protected]>
Signed-off-by: Hariom Gupta <[email protected]>
This, I haven't yet mentioned in README. Can you please confirm all sections that we should mention? Like, one section about how to run |
yurishkuro
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noticed one issue. When the backend does not return any dependency data, the screen just shows the error No service dependencies found, but the DAG Options are not visible so I can't select the sample dataset.
Otherwise lgtm, with minor tweaks. I booked another issue #2700
Signed-off-by: Hariom Gupta <[email protected]>
Yes, this thing I noticed and left intentionally because there are 2 error states on that screen:
|
sorry, I didn't follow. When there is no backend at all the UI throws internal errors. But when there is a backend, just no data for SDG, it's then this error about "no data" shows, but the same error also disables the options. |
I got your point, but I mean to say that "no data" error isn't persistent in dev mode, as dependency data eventually shows up after some seconds (and that enables the options again). |




Which problem is this PR solving?
Description of the changes
npm run start:with-datascript that dynamically imports the dependencies array from json file built by parsing the publicly available dataset on https://zenodo.org/records/13956078 using the parse-traces.js script.How was this change tested?
Checklist
jaeger:make lint testjaeger-ui:npm run lintandnpm run test