Skip to content

Conversation

@joyhaldar
Copy link
Contributor

@joyhaldar joyhaldar commented Aug 30, 2025

Description

The existing log statement in ReadRowsHelper logs the full ReadRowsResponse object, which can contain large and unreadable serialized Arrow batches. This clutters the logs and makes debugging difficult.

Example:

2025-03-25T15:37:20.578+0900	DEBUG	bigquery-bigquery-5	io.trino.plugin.bigquery.ReadRowsHelper	ReadRowsResponse from BigQuery: stats {
  progress {
    at_response_end: 0.001469222130253911
  }
}
arrow_record_batch {
  serialized_record_batch: "\377\377\377\377\360\a\000\000\024\000\000\000\000\000\000\000\f\000\030\000\006\000\005\000\b\000\f\000\f\000\000\000\000\003\004\000\034\000\000\0000)\001\000\000\000\000\000\000\000\000\000\f\000\036\000\020\000\004\000\b\000\f\000\f\000\000\000\320\005\000\000$\000\000\000\030\000\000\000\300\003\000\000\000\000\000\000\000\000\000\000\000\000\006\000\b\000\a\000\006\000\000\000\000\000\000\001Z\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\310\t\000\000\000\000\000\000\310\t\000\000\000\000\000\000\036\000\000\000\000\000\000\000\350\t\000\000\000\000\000\000\000\000\000\000\000\000\000\000\350\t\000\000\000\000\000\000\310\t\000\000\000\000\000\000\260\023\000\000\000\000\000\000\036\000\000\000\000\000\000\000\320\023\000\000\000\000\000\000\000\000\000\000\000\000\000\000\320\023\000\000\000\000\000\000\310\t\000\000\000\000\000\000\230\035\000\000\000\000\000\000\036\000\000\000\000\000\000\000\270\035\000\000\000\000\000\000\000\000\000\000\000\000\000\000\270\035\000\000\000\000\000\000\310\t\000\000\000\000\000\000\200\'\000\000\000\000\000\000\036\000\000\000\000\000\000\000\240\'\000\000\000\000\000\000\000\000\000\000\000\000\000\000\240\'\000\000\000\000\000\000\310\t\000\000\000\000\000\000h1\000\000\000\000\000\000\036\000\000\000\000\000\000\000\2101\000\000\000\000\000\000\000\000\000\000\000\000\000\000\2101\000\000\000\000\000\000\310\t\000\000\000\000\000\000P;\000\000\000\000\000\000\036\000\000\000\000\000\000\000p;\000\000\000\000\000\000\000\000\000\000\000\000\000\000p;\000\000\000\000\000\000\310\t\000\000\000\000\000\0008E\000\000\000\000\000\000\036\000\000\000\000\000\000\000XE\000\000\000\000\000\000\000\000\000\000\000\000\000\000XE\000\000\000\000\000\000\310\t\000\000\000\000\000\000 O\000\000\000\000\000\000\036\000\000\000\000\000\000\000@O\000\000\000\000\000\000\000\000\000\000\000\000\000\000@O\000\000\000\000\000\000\310\t\000\000\000\000\000\000\bY\000\000\000\000\000\000\036\000\000\000\000\000\000\000(Y\000\000\000\000\000\000\000\000\000\000\000\000\000\000
...
...
...

This change updates the log to:

log.debug("ReadRowsResponse from BigQuery stream: %s at offset: %s", helper.streamName, nextOffset);

This preserves useful logging for monitoring progress while avoiding unnecessary output of serialized record data.

Additional context and related issues

Fixes #25409 by replacing a verbose debug log that printed the entire ReadRowsResponse with a concise message logging only the stream name and offset.

Screenshot (local run)

Trino running locally and logging expected debug message:
Screenshot 2025-08-31 at 11 43 17 AM

Release notes

(x) This is not user-visible or is docs only, and no release notes are required.
( ) Release notes are required. Please propose a release note for me.
( ) Release notes are required, with the following suggested text:

@cla-bot
Copy link

cla-bot bot commented Aug 30, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@github-actions github-actions bot added the bigquery BigQuery connector label Aug 30, 2025
@joyhaldar
Copy link
Contributor Author

I have emailed a signed copy of the Trino Foundation Individual CLA.

@raunaqmorarka raunaqmorarka requested a review from ebyhr August 30, 2025 16:53
@cla-bot
Copy link

cla-bot bot commented Aug 31, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@ebyhr ebyhr force-pushed the log-readrowsresponse-offset-only branch from 86a91de to 7f0be6d Compare August 31, 2025 06:29
@cla-bot
Copy link

cla-bot bot commented Aug 31, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@joyhaldar
Copy link
Contributor Author

Hello @raunaqmorarka , @ebyhr, any chance you might have information on my signed copy of the Trino Foundation Individual CLA being on record?

@raunaqmorarka
Copy link
Member

@cla-bot check

@cla-bot
Copy link

cla-bot bot commented Sep 16, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@cla-bot
Copy link

cla-bot bot commented Sep 16, 2025

The cla-bot has been summoned, and re-checked this pull request!

@joyhaldar joyhaldar force-pushed the log-readrowsresponse-offset-only branch from 7f0be6d to 765a6c1 Compare September 16, 2025 09:12
@cla-bot
Copy link

cla-bot bot commented Sep 16, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@joyhaldar
Copy link
Contributor Author

I've just received an email stating that my signed CLA has been received.

@martint
Copy link
Member

martint commented Sep 17, 2025

@cla-bot check

@cla-bot
Copy link

cla-bot bot commented Sep 17, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@cla-bot
Copy link

cla-bot bot commented Sep 17, 2025

The cla-bot has been summoned, and re-checked this pull request!

@raunaqmorarka
Copy link
Member

@cla-bot check

@cla-bot
Copy link

cla-bot bot commented Sep 17, 2025

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Joy Haldar.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email [email protected]
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@cla-bot
Copy link

cla-bot bot commented Sep 17, 2025

The cla-bot has been summoned, and re-checked this pull request!

@ebyhr ebyhr force-pushed the log-readrowsresponse-offset-only branch from 765a6c1 to 3bd9fa3 Compare September 17, 2025 20:46
@cla-bot cla-bot bot added the cla-signed label Sep 17, 2025
@ebyhr
Copy link
Member

ebyhr commented Sep 17, 2025

@cla-bot check

@cla-bot
Copy link

cla-bot bot commented Sep 17, 2025

The cla-bot has been summoned, and re-checked this pull request!

@ebyhr ebyhr merged commit 39da6f4 into trinodb:master Sep 17, 2025
3 of 12 checks passed
@github-actions github-actions bot added this to the 477 milestone Sep 17, 2025
@joyhaldar joyhaldar deleted the log-readrowsresponse-offset-only branch September 20, 2025 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bigquery BigQuery connector cla-signed

Development

Successfully merging this pull request may close these issues.

Low readability of debug log in BigQuery ReadRowsHelper

5 participants