IGNITE-26358 DB API Driver: Heartbeats#7528
Merged
isapego merged 15 commits intoapache:mainfrom Feb 17, 2026
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds heartbeat functionality to the Python DB API driver to keep connections alive during idle periods. The heartbeat mechanism sends periodic probes to the server to prevent connection timeout.
Changes:
- Added
heartbeat_intervalparameter to theconnect()function to control heartbeat frequency - Implemented heartbeat sending logic using a timer thread in the C++ node_connection class
- Added tests for heartbeat enabled and disabled scenarios
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
| modules/platforms/python/tests/test_connect.py | Added tests for heartbeat functionality with various intervals and for disabled heartbeats |
| modules/platforms/python/pyignite_dbapi/init.py | Added documentation for the new heartbeat_interval parameter |
| modules/platforms/python/cpp_module/py_connection.h | Updated function signature to include heartbeat_interval parameter |
| modules/platforms/python/cpp_module/py_connection.cpp | Added heartbeat_interval parameter handling and conversion from seconds to milliseconds |
| modules/platforms/python/cpp_module/node_connection.h | Refactored configuration structure, added heartbeat scheduling and sending logic, made class inherit from enable_shared_from_this |
| modules/platforms/python/cpp_module/module.cpp | Updated argument parsing to accept heartbeat_interval parameter |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
ptupitsyn
reviewed
Feb 17, 2026
ptupitsyn
approved these changes
Feb 17, 2026
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.
https://issues.apache.org/jira/browse/IGNITE-26358
heartbeat_intervalparameter;