Skip to content

CDC Polling multiple databases #6036

@kberesfo

Description

@kberesfo

Is your feature request related to a problem? Please describe.
I'm developing a B2B SaaS application where customer data is segregated at the database level, and requests are routed via the session and database driver. However, the current polling mechanism only allows polling from a single database, which creates a limitation for change data capture (CDC).

I need to track events in real time, such as user actions triggering notifications. Since CDC does not work across multiple databases efficiently, I'm forced to use the v5 LTS version of the GraphQL library, which allows me to handle this at the resolver level. While this works for now, it presents scalability concerns as the application grows.

Describe the solution you'd like
I would like a way to support polling across multiple databases natively, ensuring that events from different databases can be captured and processed efficiently. Ideally, this would be done in a way that minimizes performance overhead and ensures real-time event streaming without requiring resolver-level workarounds.

Describe alternatives you've considered
Polling per database instance – This is inefficient and scales poorly.
Using the v5 LTS GraphQL library – Works at the resolver level but is not sustainable long-term.
Event-driven architecture with a separate event bus – Would require significant changes and additional infrastructure, which may not be feasible in the short term.
Additional context
This is a common challenge for multi-tenant applications that segregate data by database. A more efficient CDC mechanism that supports multi-database polling would benefit many SaaS applications following this model.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions