Skip to content

[SPARK-52846][SQL] Add a metric in JDBCRDD for how long it takes to fetch the resultset #51536

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

alekjarmov
Copy link
Contributor

@alekjarmov alekjarmov commented Jul 17, 2025

What changes were proposed in this pull request?

  • Create a helper function withTimingNs
  • Use the function to measure how long it takes to fetch data from the JDBC source.

Why are the changes needed?

Provides better observability, for example we have execution time, now we would know if the network is the bottleneck.

Does this PR introduce any user-facing change?

In SparkUI user could see this new metric.

How was this patch tested?

Added a unit test.

Was this patch authored or co-authored using generative AI tooling?

No.

@github-actions github-actions bot added the SQL label Jul 17, 2025
@alekjarmov alekjarmov marked this pull request as draft July 17, 2025 12:51
@alekjarmov alekjarmov changed the title Add withTiming utility to SQLMetrics [SPARK-52846][SQL] Add a metric in JDBCRDD for how long it takes to fetch the resultset Jul 17, 2025
@alekjarmov alekjarmov marked this pull request as ready for review July 17, 2025 14:12
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.

1 participant