Properly set "identity" in query metrics.#5330
Merged
gianm merged 2 commits intoapache:masterfrom Feb 6, 2018
Merged
Conversation
This patch adds an "identity" field to QueryPlus and sets it in QueryLifecycle when the query starts executing. This is important because it allows it to be used for future QueryMetrics created by that QueryPlus object. We also add "identity" to the request-level QueryMetrics object created in emitLogsAndMetrics.
himanshug
approved these changes
Feb 2, 2018
Contributor
Author
|
Note that with this change, the broker will report the identity of the actual user, but the historicals will report the system identity. This is because once the broker verifies that the query is allowed, it uses its own credentials to talk to historicals, not the credentials of the original user. So the historicals don't know who the original user is. I think it would be nice if they did (maybe an 'impersonation' feature would allow the broker to pass along the original identity) but I also think that is out of scope for this particular PR. |
Contributor
|
Looks like there's a real inspection error: |
Contributor
Author
|
Removed the unused method and pushed again. |
drcrallen
approved these changes
Feb 6, 2018
gianm
added a commit
to implydata/druid-public
that referenced
this pull request
Feb 6, 2018
* Properly set "identity" in query metrics. This patch adds an "identity" field to QueryPlus and sets it in QueryLifecycle when the query starts executing. This is important because it allows it to be used for future QueryMetrics created by that QueryPlus object. We also add "identity" to the request-level QueryMetrics object created in emitLogsAndMetrics. * Remove unused method.
gianm
added a commit
to implydata/druid-public
that referenced
this pull request
May 11, 2018
* Properly set "identity" in query metrics. This patch adds an "identity" field to QueryPlus and sets it in QueryLifecycle when the query starts executing. This is important because it allows it to be used for future QueryMetrics created by that QueryPlus object. We also add "identity" to the request-level QueryMetrics object created in emitLogsAndMetrics. * Remove unused method.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This patch adds an "identity" field to QueryPlus and sets it in
QueryLifecycle when the query starts executing. This is important
because it allows it to be used for future QueryMetrics created
by that QueryPlus object.
We also add "identity" to the request-level QueryMetrics object
created in emitLogsAndMetrics.