Skip to content

database: Add connection pool support(go:database/sql) #23995

@Avey777

Description

@Avey777

Describe the feature

This issue proposes adding a connection pool mechanism to the database module to optimize database interactions.

Configurable pool parameters: pool_size, max_connections, idle_timeout
Thread-safe connection reuse with automatic recycling
Health checks (e.g., ping() validation for stale connections)
Extend Connection interface with release() and reset() methods
Add pool lifecycle management (start/stop during database initialization)

refer to :go:database/sql

Use Case

Image
gorm

Proposed Solution

No response

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

Version used

v4.10.0

Environment details (OS name and version, etc.)

ALL

Note

You can use the 👍 reaction to increase the issue's priority for developers.

Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature/Enhancement RequestThis issue is made to request a feature or an enhancement to an existing one.ORMBugs/feature requests, that are related to the V ORM.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions