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

Do not skip service/operation indexing for firehose spans #2242

Merged
merged 3 commits into from
May 13, 2020

Conversation

yurishkuro
Copy link
Member

PR #2090 allowed recording of service and operations in the services/operations tables, but did not index traces by service & operation. This actually made UI even more confusing since the Operations dropdown shows a lot more operations, yet no traces can be found for them.

This change re-enables indexing of firehose traces by service and operation for real. It's a compromise, which brings 3x write amplification for each span (writes from PR #2090 are cached so don't happen often). However, it significantly improves usability and is still much cheaper than indexing all of the span tags.

Signed-off-by: Yuri Shkuro <ys@uber.com>
@yurishkuro yurishkuro requested a review from a team as a code owner May 12, 2020 21:22
@yurishkuro yurishkuro requested a review from vprithvi May 12, 2020 21:22
@vprithvi
Copy link
Contributor

vprithvi commented May 12, 2020

Could you add/update tests to ensure that the service name / operation name to traceID indexes are populated?

I think adding indexing to firehose spans makes user experience rather confusing.
While previously, users expect firehose spans to be unindexed, now certain fields are indexed. There is no communication to the UI user on which fields are indexed. This will lead to situations where users would try to adjust things like duration on partially indexed firehose spans and find that the search doesn't work.

I feel that perhaps disabling the input fields for tag based search and duration based search when services/operations with firehose spans are selected could lead to better user experience.

Signed-off-by: Yuri Shkuro <ys@uber.com>
@yurishkuro
Copy link
Member Author

I feel that perhaps disabling the input fields for tag based search and duration based search when services/operations with firehose spans are selected could lead to better user experience.

This would require much more extensive changes. We can think about it, but I think the current fix is a compromise - yes, you cannot find those traces by tags, but doing that requires a roundtrip to first find the trace, then confirm that it has a tag, and then fail to find by that tag. Where as the current situation is you get operation name in the dropdown, but no traces are found for it - much easier to run into.

@codecov
Copy link

codecov bot commented May 12, 2020

Codecov Report

Merging #2242 into master will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2242   +/-   ##
=======================================
  Coverage   96.16%   96.16%           
=======================================
  Files         219      219           
  Lines       10640    10640           
=======================================
  Hits        10232    10232           
  Misses        352      352           
  Partials       56       56           
Impacted Files Coverage Δ
plugin/storage/cassandra/spanstore/writer.go 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e55cc6e...6dc1d76. Read the comment docs.

@yurishkuro yurishkuro added this to the Release 1.18 milestone May 12, 2020
@yurishkuro yurishkuro mentioned this pull request May 12, 2020
durationNoOperationQuery := &mocks.Query{}
durationNoOperationQuery.On("Bind", matchEverything()).Return(durationNoOperationQuery)
durationNoOperationQuery.On("Exec").Return(testCase.durationNoOperationQueryError)
durationNoOperationQuery.On("String").Return("select from duration_index")

// Define expected order of queries
Copy link
Contributor

Choose a reason for hiding this comment

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

This comment is rather misleading because one might assume that the expected ordering is enforced on asserts. I think we should remove it.

AssertExpectations asserts that everything specified with On and Return was in fact called as expected. Calls may have occurred in any order.

I'm not sure whether this is possible with testify/mock, but gomock provides InOrder which does enforce ordering of expectations.

@vprithvi
Copy link
Contributor

I agree that it is a compromise and that we should get this in right now.

I think it's confusing to not communicate these compromise to UI users who don't get any indication that only certain parts of search work for services setting the firehose tag. In fact, even if they end up on an initial firehose trace (via service/operation search), there is no indication that they are viewing a firehose trace and that there are implications wrt search.

Signed-off-by: Yuri Shkuro <ys@uber.com>
@yurishkuro
Copy link
Member Author

I booked a ticket for UI change: jaegertracing/jaeger-ui#575

@yurishkuro yurishkuro merged commit f9c78d9 into jaegertracing:master May 13, 2020
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.

2 participants