-
Notifications
You must be signed in to change notification settings - Fork 115
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
[Oracle] Add logs #2528
base: main
Are you sure you want to change the base?
[Oracle] Add logs #2528
Conversation
buildkite test this |
@moxarth-elastic example log file that you've attached is actually for OneDrive, can you provide proper log file? |
The most useful connector logs are - which queries were actually executed by the connectors. Can you add debug logs that state which exact queries were executed? A good addition to it would be to also debug log the number of records returned by the query. |
Oops! My bad. I've updated the link. |
connectors/sources/oracle.py
Outdated
row_count = await self.oracle_client.get_table_row_count(table=table) | ||
if row_count > 0: | ||
# Query to get the table's primary key | ||
self._logger.debug(f"Total '{row_count}' rows found in '{table}' table") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
self._logger.debug(f"Total '{row_count}' rows found in '{table}' table") | |
self._logger.debug(f"Total {row_count} rows found in table \"{table}\"") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@artem-shelkovnikov these changes are causing the linting error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not automatically fixable by make autoformat
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I already tried to do that but it was reformatting the log to the previous one. It's not accepting the current logs you suggested.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It cannot reformat to previous one, because I've changed wording of the log slightly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it complain at \"
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it removes the escaping
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can do that, it's okay, as long as it's consistent.
Co-authored-by: Artem Shelkovnikov <artem.shelkovnikov@elastic.co>
@moxarth-elastic why did you revert the whole change? The only problem was the escaping? Now I see that log lines are inconsistent - some say |
Oh, I see. Let me update it. |
d4ff143
to
40b07f1
Compare
@artem-shelkovnikov I've made the logs consistent and fixed the linter error. |
Part Of #2299
Adding more logs in Oracle connector.
Log file: https://drive.google.com/file/d/1eqC6FRfm4IicdMNt2Z1Hivw6x3G-g_JC/view?usp=drive_link
Checklists
Pre-Review Checklist
config.yml.example
)v7.13.2
,v7.14.0
,v8.0.0
)