The Traces tab in traces which displays root spans only seems to always be sorted by the root durati...
d
The Traces tab in traces which displays root spans only seems to always be sorted by the root duration? This makes it quite useless as a general exploration tool. Is this a bug or is this intended?
s
This is intended behaviour. Can you please help us understand how would you like to use it and what would be most useful for you?
d
Sure: I basically want a list where I see only traces. So not a list of individual spans like the default view.
s
I basically want a list where I see only traces. So not a list of individual spans like the default view
To put it into a list, we need to pick something to represent a trace. We chose the root span to represent it and used the duration as a way to order if there are more than one trace matching the criteria. They are not really individual spans. Can you help me understand what you have in mind with a bit more specific detail?
d
So, my understanding of a trace is this: All spans with the same trace-ID, see screenshot. In a list of traces, I would have a single entry for this trace. But in the normal view (the "List View" tab, not the "Traces" tab), I have one entry per individual span. So there is an entry for the EntryPoint span, one for the Metrics span etc. So, I think, my requirement could be fulfilled by a simple filter for the List View that displays only root spans.
s
So, I think, my requirement could be fulfilled by a simple filter for the List View that displays only root spans.
This is what Traces tab does
d
But Traces tab is not ordered by timestamp. It is ordered by duration and there is no way to change this
Also, the Traces tab doesn't allow me to display additional columns. Ideally, the traces tab would allow arbitrary ordering, they way the List View tab does and would also allow me to specify the columns / attributes to be displayed, ideally allowing attributes not only from the root span but from all spans
s
ideally allowing attributes not only from the root span but from all spans
Please give more detail on this. If there is no attribute on the root span. Which span attribute should be shown? What are you trying to get out of this?
d
I'm not sure why this is hard to understand. Am I missing something? I want a view on my traces (the requests into my system) in the order they happened but I don't want to be overloaded by every individual span. The root span usually contains enough info to decide whether it needs further investigation. What if no attribute is on the root span? Handle it the same as in the "List View" tab when a span has no attributes.
s
I am dumb, so please bear with me to help me understand things better.
would also allow me to specify the columns / attributes to be displayed, ideally allowing attributes not only from the root span but from all spans
You mentioned you would like to see attributes from all spans. Say an attribute "my.attribute" didn't exist on root span but exists in 10 child spans of a trace. In list view what would you expect to see and what are you trying to get out of it.
d
I'm absolutely certain that you are not dumb, that's why I'm asking if I'm missing something 🙂
see, I misunderstood your question.
So, what I want out of displaying attributes from child spans: Maybe not all relevant info is on the root span, so it might be good to display info from a child span. But I do understand the challenge
s
Not being restricted to duration order and the ability to arbitrarily add attributes are very valid requirements. Today neither list view nor the Trace tab does it. I am going to create a ticket for this and pass on feedback so that it can be addressed in the trace improvement effort.
Maybe not all relevant info is on the root span, so it might be good to display info from a child span. But I do understand the challenge
We will brainstorm about it and see if we can come up with something. If you have any ideas please share.
d
Yes, I would be happy with these first two requirements. Displaying info from a child span is a nice-to-have. I think the list view already allows arbitrary sorting as well as adding arbitrary attributes:
We will brainstorm about it and see if we can come up with something. If you have any ideas please share.
I will. Everything I came up so far is either super complex - allow specifying rules from which span to take if multiple has the attribute - or super simplistic - take the value from the first span that has the attribute
Although I think that the simplistic approach would probably handle 80% of use-cases
Thanks for taking the time to discuss this with me, it's much appreciated