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

Display service name when showing addresses in the span detail element #1114

Merged
merged 2 commits into from
May 15, 2016

Conversation

yurishkuro
Copy link
Contributor

@yurishkuro yurishkuro commented May 13, 2016

Example screenshot:
image

Why: when a request comes from or goes to uninstrumented service, the instrumented part may log CA/SA annotations that include not only the peer IP address, but also the service name. However, the current UI, while it has a special handing for CA/SA annotations, does not display the service name.

@yurishkuro
Copy link
Contributor Author

@adriancole are there unit tests for what gets displayed in the UI?

@codefromthecrypt
Copy link
Member

yeap formatEndpoint has unit tests in traceToMustache.test.js

probably, just test that passing blank has the intended effect. Also I suspect the callsite needs to be updated to actually pass serviceName, right? Otherwise it is dead code.

@codefromthecrypt
Copy link
Member

oh I remember this issue! We discussed and performed no action on this in the past.

Last time we discussed this, we noted that having endpoint information for binary annotations isn't something we expect to carry forward in the model.

Making a UI change to special case when multiple services report the same value formalizes a feature that will look "missing" when we finally get time to fix the model to disallow this.

Next time you are raising an issue we have discussed and took no action on, please make reference to the former discussion and mention what has changed which would lead to us taking different action now.

@codefromthecrypt
Copy link
Member

closing this as the issue itself hasn't changed #989

@yurishkuro
Copy link
Contributor Author

this PR is unrelated to that discussion. It is here to display service name normally encoded in SA/CA/LC, which is otherwise hidden (LC had a special handling, which with this PR becomes unnecessary). The service name in the SA/CA annotations is respected in other parts of the code, specifically in the logic that derives a single service name for a span: https://github.com/openzipkin/zipkin/blob/master/zipkin-ui/js/component_ui/traceSummary.js#L53

@codefromthecrypt
Copy link
Member

@yurishkuro you're right. re-opened and changing the title as this is related to "address" annotations, which are special-cased.

@codefromthecrypt codefromthecrypt changed the title Display service name for endpoint in Binary Annotations Display service name when showing addresses in the span detail element May 14, 2016
@codefromthecrypt
Copy link
Member

codefromthecrypt commented May 14, 2016 via email

@codefromthecrypt
Copy link
Member

ps I caused this to slow down, and am sorry about that. In repentance, I'll add the missing tests etc.

@eirslett
Copy link
Contributor

eirslett commented May 14, 2016

I would rather not show the parentheses at all if serviceName is empty, isn't that better?

@codefromthecrypt
Copy link
Member

@eirslett agreed

@codefromthecrypt codefromthecrypt force-pushed the display-service-name-for-endpoints branch from 8341bfb to c984c9e Compare May 14, 2016 10:56
@codefromthecrypt
Copy link
Member

Added tests and a more complete screen shot. One glitch is that this causes the Annotations pane to show redundant info, as it has service listed already...

screen shot 2016-05-14 at 6 53 13 pm

@codefromthecrypt
Copy link
Member

so I don't think this is shippable without revisions because it looks really chatty now. If this change was isolated to just the bottom part, or we took out the Service column in the top part, it would be shippable imho

@codefromthecrypt
Copy link
Member

I guess another option would be to change the code so that it didn't apply to both sections.

@codefromthecrypt
Copy link
Member

Yet anothet option could be to just add a service column at the bottom like there is at the top

@codefromthecrypt
Copy link
Member

Added a commit with one option, which is to make the top match the bottom. Here's a screenshot

screen shot 2016-05-14 at 7 21 13 pm

@eirslett
Copy link
Contributor

LGTM!

Adrian Cole @adriancole 12:50
@eirslett on endpoint formatting..
150.151.152.153:0 vs 150.151.152.153?
we have a test to show the former, but often zero is absence of a value (at least in code I've noticed)
I can see it both ways, but kindof prefer just dropping port from the label when zero

No strong opinions here. Leaving it as it is (showing the zero) indicates that Zipkin is indeed able to show which port a service answered on - which can be handy for people to know, when they try to improve their instrumentation/pass in more data. (port, in this case)

@yurishkuro
Copy link
Contributor Author

lgtm. Thanks for improvements & tests. I was porting this change from our pre-JS fork where it was only affecting the bottom part.

@codefromthecrypt codefromthecrypt merged commit f307510 into master May 15, 2016
@codefromthecrypt codefromthecrypt deleted the display-service-name-for-endpoints branch May 15, 2016 00:17
codefromthecrypt pushed a commit that referenced this pull request Jun 3, 2016
#1114)

* Displays service name when showing addresses in the span detail element

* Takes out redundant service name column
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants