Skip to content

IGNITE-26358 DB API Driver: Heartbeats#7528

Merged
isapego merged 15 commits intoapache:mainfrom
isapego:ignite-26358
Feb 17, 2026
Merged

IGNITE-26358 DB API Driver: Heartbeats#7528
isapego merged 15 commits intoapache:mainfrom
isapego:ignite-26358

Conversation

@isapego
Copy link
Contributor

@isapego isapego commented Feb 3, 2026

https://issues.apache.org/jira/browse/IGNITE-26358

  • Added heartbeats;
  • Added heartbeat_interval parameter;
  • Added tests.

@isapego isapego self-assigned this Feb 3, 2026
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

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_interval parameter to the connect() 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.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

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.

@isapego isapego requested a review from ptupitsyn February 17, 2026 09:40
@isapego isapego merged commit 4eb7521 into apache:main Feb 17, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants