Skip to content
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

Trace statistics table is now using antd Table component #1500

Merged
merged 26 commits into from
Jun 19, 2023
Merged

Trace statistics table is now using antd Table component #1500

merged 26 commits into from
Jun 19, 2023

Conversation

GLVSKiriti
Copy link
Contributor

Trace Statistics table is not using antd Table component like Trace span Table so now code is modified such that TraceStatistics table now uses antd Table component

Resolves #1181

@yurishkuro Once review this PR and let me now any changes should I do

@yurishkuro
Copy link
Member

Did you model your code after another code in Jaeger? If so, please point to the existing code.

@GLVSKiriti
Copy link
Contributor Author

GLVSKiriti commented Jun 15, 2023

Did you model your code after another code in Jaeger? If so, please point to the existing code.

Do you mean should I merge the latest changes from "main" into this branch, like by updating the branch

Copy link
Contributor

@yashrsharma44 yashrsharma44 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have made some requests about the implementation. Can you take a look at the CONTRIBUTING.md and run the linter to make sure the variables/code are properly formatted?

@yashrsharma44
Copy link
Contributor

Did you model your code after another code in Jaeger? If so, please point to the existing code.

Do you mean should I merge the latest changes from "main" into this branch, like by updating the branch

You can link the inspiration/source of truth for the structure of the Table that you're using. I can see that we are deriving the changes, framed after the TraceSpan component.

@yashrsharma44
Copy link
Contributor

Thanks for raising this PR 🙂

I have some nits for raising a PR in general.

  • You can make the commit message a bit more descriptive, and make sure that the message depicts the changes made.

For example -
In this commit, you had introduced a sorting function - sorterFunction, so make sure the git commit message describes the changes that you have made. Currently, I can see the same commit message - Look of TraceStatistics and Tracespan tables should be similar , which makes it difficult for someone reviewing the changes to understand at a glance, what changes did you make. You can check this out for learning more about writing good commit messages :)

  • Check the contributing/readme for running the validation checks - e.g. linter/formatter for making sure, the code changes are compliant to the standards we have set.

…lumns

Sorting Indicators added in Trace spans Table and antd Table component is used in trace statistics view

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
… in TraceStatistics table

Now TraceStatistics table is working fine according to selectors in TraceStatisticsHeader and findTablesAccToSelectors
function is added

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
As antd Table component is used MainTableData,DetailedTableData,HeaderTable components are not needed
and sortTable file is also not needed because antd table component has sorter

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
OnCellFunction for showing the background color according to valuenameselector3 value and value of find search
sorter function is modified such a way undefined type row in a subgroup of each span will be always in bottom irrespective of sorting

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
Correcting some typo errors now both TraceStatistics and TracsSpan tables look is similar and both are working fine

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
Code is now reduced and ISorterInput type is used for sorterFunction,validation checks also performed with yarn eslint

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
Copy link
Contributor

@yashrsharma44 yashrsharma44 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, the changes look much better at this point. Some small changes, and once they are addressed, it looks good to me :)

@yashrsharma44
Copy link
Contributor

You can mark the PR ready for review.

Now look of TraceStatistics and TraceSpan tables are similar

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
@GLVSKiriti GLVSKiriti marked this pull request as ready for review June 16, 2023 15:46
Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
@yurishkuro
Copy link
Member

+202 −1,036

I love it that we'll be net-removing ~800 lines of code!

@yurishkuro
Copy link
Member

A minor request: in the existing implementation sorting by column only works if you click on the up/down sort icon. Could we make sure that clicking anywhere in the column header causes the sort?

@GLVSKiriti
Copy link
Contributor Author

GLVSKiriti commented Jun 16, 2023

Yes it is working like that right.clicking anywhere in the column header causes the sort

By drying the function with just one return

Signed-off-by: GLVSKiriti <116095646+GLVSKiriti@users.noreply.github.com>
isDetail is a attribute of ITableSpan type which tells about sub-grouping in a table

Signed-off-by: GLVSKiriti <116095646+GLVSKiriti@users.noreply.github.com>
GLVSKiriti and others added 4 commits June 18, 2023 01:42
Co-authored-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Signed-off-by: GLVSKiriti <116095646+GLVSKiriti@users.noreply.github.com>
type is string before now hasSubgroupValue is boolean in ITableSpan and relevant description is added in it

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
Co-authored-by: Yash Sharma <yashrsharma44@gmail.com>
Signed-off-by: GLVSKiriti <116095646+GLVSKiriti@users.noreply.github.com>
Copy link
Contributor

@yashrsharma44 yashrsharma44 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it looks good to me, let's wait for @yurishkuro's review 🙂

yurishkuro
yurishkuro previously approved these changes Jun 18, 2023
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Signed-off-by: Yuri Shkuro <ysh@meta.com>
@yurishkuro
Copy link
Member

not clear why unit tests are failing, did you run them locally?

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
@GLVSKiriti
Copy link
Contributor Author

GLVSKiriti commented Jun 19, 2023

not clear why unit tests are failing, did you run them locally?

Error is causing because I didn't removed the test cases for the deleted functions in index.tsx
Now I fixed them

yurishkuro
yurishkuro previously approved these changes Jun 19, 2023
@yurishkuro
Copy link
Member

CI still failing. I recommend making sure yarn test and yarn lint are successful locally.

yarn test,yarn lint,yarn eslint,yarn prettier runned with no errors now

Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
@GLVSKiriti
Copy link
Contributor Author

CI still failing. I recommend making sure yarn test and yarn lint are successful locally.

Ok yarn lint also runned locally, Now every thing is working fine locally

@codecov
Copy link

codecov bot commented Jun 19, 2023

Codecov Report

Patch coverage: 82.97% and project coverage change: +0.30 🎉

Comparison is base (beca0a8) 95.63% compared to head (e30ecc6) 95.93%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1500      +/-   ##
==========================================
+ Coverage   95.63%   95.93%   +0.30%     
==========================================
  Files         245      241       -4     
  Lines        7712     7553     -159     
  Branches     2028     1982      -46     
==========================================
- Hits         7375     7246     -129     
+ Misses        337      307      -30     
Impacted Files Coverage Δ
...i/src/components/TracePage/TraceSpanView/index.tsx 89.39% <0.00%> (-4.26%) ⬇️
...mponents/TracePage/TraceStatistics/tableValues.tsx 99.33% <ø> (ø)
...src/components/TracePage/TraceStatistics/index.tsx 86.86% <88.37%> (+9.09%) ⬆️
...racePage/TraceStatistics/generateDropdownValue.tsx 95.55% <100.00%> (ø)

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@yurishkuro yurishkuro merged commit ef41574 into jaegertracing:main Jun 19, 2023
7 of 8 checks passed
@yurishkuro
Copy link
Member

🎉 🎉 🎉 🎉 🎉 🎉

@GLVSKiriti
Copy link
Contributor Author

Yayyy! Finally 😃😃🎉🎉

@GLVSKiriti GLVSKiriti deleted the traceViewsUI branch June 19, 2023 19:43
@yashrsharma44
Copy link
Contributor

❤️ 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: trace statistics and trace span table are using different look & feel
3 participants