CloudNativePG Interface (CNPG-I)
Status: Experimental
The CloudNativePG Interface (CNPG-I) introduces a modular and extensible
approach to integrating plugins with the
CloudNativePG operator for PostgreSQL,
enabling greater flexibility and ease of feature development in the
CloudNativePG ecosystem.
What is CNPG-I?
The CloudNativePG Interface is a gRPC-based protocol that defines a
standardized interface between the CloudNativePG operator and external plugins.
This approach empowers developers and organizations to extend the operator's
functionality without the need to fork its codebase.
For a detailed protocol specification, refer to the protocol.md file.
Why CNPG-I?
Over the years, CloudNativePG's codebase has grown significantly, creating
challenges for developers contributing to the project and increasing the time
required to deliver new features.
To address this, CNPG-I provides a modular plugin architecture inspired by
the success of Kubernetes' Container Storage Interface (CSI).
CNPG-I fosters a thriving ecosystem by making it easier to integrate new
capabilities through independent plugins, allowing for faster innovation and
simplified maintenance.
Key Benefits
- Reduced Complexity: Delegate responsibilities to external plugins,
reducing the cognitive load and size of the CloudNativePG core codebase.
- Faster Feature Delivery: Accelerate development by fostering independent
plugin creation, prototyping, and ecosystem growth.
- Standardized gRPC API:
Provide a robust, gRPC-based API specification for customizing operator and
operand behavior, complete with compliance testing tools.
- Ecosystem Expansion: Encourage innovation by enabling developers to
create enhancements as separate projects, avoiding forks and lowering barriers
to entry.
- Ease of Adoption: Simplify the move to CloudNativePG for Postgres and
Kubernetes users by facilitating custom enhancements and integrations.
Use Cases for Plugins
CNPG-I enables the creation of plugins for diverse use cases, such as:
- WAL Management
- Backup and Recovery
- Logging and Auditing
- Metrics Export
- Authentication and Authorization
- Extension Management
- Instance Lifecycle Management
- Configuration Management
By leveraging plugins, developers can extend CloudNativePG’s functionality
without modifying its core code.
Projects Built with CNPG-I
Explore real-world applications of CNPG-I:
Third-Party Plugins
Disclaimer:
The plugins listed in this section are developed and maintained by
independent third parties. CloudNativePG and the CNPG-I project
(both licensed under Apache-2.0) do not endorse, guarantee, or assume
responsibility for their functionality, maintenance, support, or security.
For usage, troubleshooting, or updates, please refer to the plugin’s own
documentation, source repository, or other channels indicated on its pages.
- CNPG-I Scale-to-Zero Plugin:
A plugin that automatically hibernates inactive CloudNativePG clusters to
optimize resource usage and reduce costs.
Trademarks
Postgres, PostgreSQL and the Slonik Logo
are trademarks or registered trademarks of the PostgreSQL Community Association
of Canada, and used with their permission.