Skip to content

[SPARK-33463][SQL] Keep Job Id during incremental collect in Spark Thrift Server #30390

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

Closed
wants to merge 4 commits into from

Conversation

gumartinm
Copy link
Contributor

What changes were proposed in this pull request?

When enabling spark.sql.thriftServer.incrementalCollect Job Ids get lost and tracing queries in Spark Thrift Server ends up being too complicated.

Why are the changes needed?

Because it will make easier tracing Spark Thrift Server queries.

Does this PR introduce any user-facing change?

No

How was this patch tested?

The current tests are enough. No need of more tests.

@github-actions github-actions bot added the SQL label Nov 16, 2020
@AmplabJenkins
Copy link

Can one of the admins verify this patch?

@@ -126,6 +126,17 @@ private[hive] class SparkExecuteStatementOperation(
}

def getNextRowSet(order: FetchOrientation, maxRowsL: Long): RowSet = withLocalProperties {
try {
sqlContext.sparkContext.setJobGroup(statementId, statement)
Copy link
Contributor

Choose a reason for hiding this comment

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

minor: in execute substitutorStatement is used as a description of the jobgroup. Maybe pull out substitutorStatement to be a class field and use it here as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You are right!!! Thanks a lot for taking the time of revisioning my code.

I implemented the change, hopefully now it looks better. Looking forward to hearing your thoughts.

Copy link
Contributor

@juliuszsompolski juliuszsompolski left a comment

Choose a reason for hiding this comment

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

LGTM
cc @wangyum

Copy link
Member

@dongjoon-hyun dongjoon-hyun left a comment

Choose a reason for hiding this comment

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

+1, LGTM. Thank you, @gumartinm and @juliuszsompolski .
Merged to master for Apache Spark 3.1.

@dongjoon-hyun dongjoon-hyun changed the title [SPARK-33463][SQL] Spark Thrift Server, keep Job Id when using incremental collect [SPARK-33463][SQL] Keep Job Id during incremental collect in Spark Thrift Server Nov 21, 2020
@dongjoon-hyun
Copy link
Member

@gumartinm . I added you to the Apache Spark contributor group and assigned SPARK-33463 to you.
Thank you for your first contribution again. Welcome to the Apache Spark community.

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.

4 participants