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 JSON"/"Trace JSON (unadjusted)" open outside Jaeger UI application #680

Open
th3M1ke opened this issue Jan 18, 2021 · 9 comments
Open

Comments

@th3M1ke
Copy link
Contributor

th3M1ke commented Jan 18, 2021

Requirement - what kind of business use case are you trying to solve?

Screenshot 2021-01-13 at 22 04 21

"Trace JSON"/"Trace JSON (unadjusted)" open outside Jaeger UI application. For this case, we have no ability to manage auth tokens in HTTP headers via iframe

Problem - what in Jaeger blocks you from solving the requirement?

"Trace JSON"/"Trace JSON (unadjusted)" use a direct API call to get JSON from the backend. No ability to handle HTTP headers

Proposal - what do you suggest to solve the problem or improve the existing situation?

The solution is to create a react component, which makes a call to the backend via JaegerAPI. Also, this component can deprecate "Trace JSON (unadjusted)" in the trace page's dropdown. This functionality can be performed by these components. Also, we can make some progress here #197

@yurishkuro
Copy link
Member

Sorry, I don't fully follow what is being proposed. Are you suggesting a dedicated component to manually render JSON without leaving the UI? Currently View JSON buttons double as a means to download the trace JSON, not only view it.

@th3M1ke
Copy link
Contributor Author

th3M1ke commented Jan 18, 2021

Correct! I suggest a custom component for render/download raw traces.

The reason for that is once you open "Trace JSON" its go out of UI app control and fire direct API query, which is under control of iframe in our case... 😞

@yurishkuro
Copy link
Member

I think we may already have some form of JSON rendering for tag values, so perhaps it's not too bad to implement it for full trace JSON. The only concern I have is to make sure that the component scales up for very large traces, since the current method just relies on the browser file rendering with minimal overhead.

@th3M1ke
Copy link
Contributor Author

th3M1ke commented Jan 20, 2021

What is the max size of trace have you face? BTW, you have mentioned form of JSON rendering for tag values can you help to find it?

@yurishkuro
Copy link
Member

@th3M1ke
Copy link
Contributor Author

th3M1ke commented Mar 1, 2021

@yurishkuro json-markup almost ok on chrome with hotROD data, but it renders more than 10 seconds in safari... Can you share some examples of trace for 100,000 spans, or just say its approximate size?

@yurishkuro
Copy link
Member

Sorry I don't have examples, it was with Uber's production data.

Do you mean the size in bytes? For 100,000 spans it would be 50-100Mb.

@nofar9792
Copy link
Contributor

Hi @yurishkuro :)
I would like to fix it.
Just want to be sure about the solution:

  1. remove "Trace JSON (unadjusted)"

  2. show the JSON on the same page (and not a new tab)
    image

  3. maybe we can add a lib to show the JSON in an interactive way? for example https://www.npmjs.com/package/react-json-view

WDYT?

@yurishkuro
Copy link
Member

This ticket looks like a duplicate of #1211, which has an in-progress PR solving it.

@nofar9792 As for your specific suggestions:

  1. No, we won't remove unadjusted, it's valuable in debugging
  2. I don't believe embedding the JSON view is a good solution. It prevents one from downloading the result as JSON, which is currently possible.

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

No branches or pull requests

4 participants