Announcing Crunchy Postgres for Kubernetes 5.5
We're excited to announce the release of Crunchy Postgres for Kubernetes 5.5. Included in this release are great updates to database administration, monitoring, connection pooling and more. Specific highlights include:
- An updated pgAdmin experience, including the ability to deploy one pgAdmin for use with multiple Postgres clusters
- Easier installation of the metrics and monitoring tools, along with the added ability to monitor standby clusters
- Updates to PgBouncer including support for prepared statements and streamlined connectivity to read replicas
We have many updates in this version so see Crunchy Postgres for Kubernetes 5.5 Release Notes for the full list of all changes included.
Updated pgAdmin
Included in the 5.5 release we’ve introduced a new pgAdmin Custom Resource. Designed from the ground-up to put pgAdmin at your fingertips where and when needed, this version lets you:
- Add one or more Postgres clusters to a single pgAdmin deployment
- Deploy the latest and greatest pgAdmin features & releases, including full Postgres 16 support
- Integrate with enterprise authentication methods, such as LDAP
Here is a quick peek at what simple pgAdmin deployment looks like using the new Custom Resource:
apiVersion: postgres-operator.crunchydata.com/v1beta1
kind: PGAdmin
metadata:
name: rhino-admin
spec:
dataVolumeClaimSpec:
accessModes:
- 'ReadWriteOnce'
resources:
requests:
storage: 1Gi
serverGroups:
- name: demand
postgresClusterSelector:
matchLabels:
app: demo
From here I simply need to ensure any of the PostgresClusters I want to connect to have the demo
label.
kubectl label postgrescluster hippo app=demo
That's it! From here, Crunchy Postgres for Kubernetes will handle the rest. This includes configuring a connection to my hippo
PostgresCluster within the rhino-admin
deployment.
Enhanced Metrics & Monitoring
We're always looking for ways to make it easy to get insights from your Postgres clusters and we’ve added a number of features, including these notable ones:
- Helm chart for installing metrics and monitoring
- Easily adding custom queries to the monitor
- Monitoring standby clusters
Additional details on each of these can be found below.
Helm support
With version 5.5, we're excited to announce that Helm support is now available for the monitoring stack. This makes this important day 2 activity of monitoring available to a variety of Helm use cases. The Helm chart is available via OCI registry or the examples repo.
helm install crunchy \
oci://registry.developers.crunchydata.com/crunchydata/crunchy-monitoring
Take a look at our docs for more details:
Custom queries
Crunchy Postgres for Kubernetes monitoring comes with many queries out of the box. You can also create custom queries for additional monitoring of anything within the database itself. In the past, you had to create a large file of all the queries used. Now you can provide custom queries independently of having to re-document the existing monitoring queries. You can enable this feature via the following feature-flag:
PGO_FEATURE_GATES=”AppendCustomQueries”
See the following docs for more details: Append Your Custom Queries to the Defaults.
Monitoring Standby Clusters
Finally, this release provides an important improvement for multi-Kubernetes cluster database architectures. As more databases expand beyond a single cluster, multi-cluster monitoring is also needed. For a PostgresCluster, this means being able to monitor standby clusters. Using version 5.5, you can now set the monitoring password in standby clusters. This, in turn, unlocks the ability to install and use the full monitoring stack with a standby cluster. As a result, you can now get insight into your databases across all your Kubernetes clusters.
Connection Pooling Updates
We're happy to announce updates to connection pooling. PgBouncer v1.21 is now available in Crunchy Postgres for Kubernetes 5.5. This version of PgBouncer introduces support for prepared statements while using transaction mode.
As a quick overview, prepared statements are a query efficiency mechanism in Postgres. If you are running the exact same query multiple times, you can create a prepared statement. Once created, you can execute the prepared statement over and over, removing the parsing and preparing steps of the query. This can dramatically increase query performance. PgBouncer is an important tool for many of our customers scaling out their database operations and PgBouncer recently added support for prepared statements, specifically using the transaction mode.
Note that by default PgBouncer uses session mode (i.e., pool_mode is set to session). Switching to transaction mode only requires a quick update to your PostgresCluster spec:
spec:
proxy:
pgBouncer:
config:
global:
pool_mode: transaction
The updates to Crunchy Postgres for Kubernetes connection pooling don't stop there! Version 5.5 also makes connecting to read replicas via PgBouncer easier than ever before. More specifically, DNS names for the replica service are now added to the TLS certificates created for a PostgresCluster. This makes it easy to leverage connection pooling for a variety of use cases involving connectivity to read replicas.
Upgrading to Crunchy Postgres for Kubernetes 5.5
Upgrading to Crunchy Postgres for Kubernetes 5.5 is typically as simple as running a single command. For instance, if you installed Crunchy Postgres for Kubernetes using the Kustomize installer available in the Postgres Operator examples repository, you would simply issue the following command:
kubectl apply --server-side -k kustomize/install/default
For additional upgrade guidance (e.g. if using Helm or various other installation methods), please see the Crunchy Postgres for Kubernetes Upgrade documentation.
Thanks for diving into some of the great new features included in Crunchy Postgres for Kubernetes 5.5. We look forward to discussing this new release and more out in the Crunchy Data Discord server. If you haven't done so already, we welcome you to join and continue the conversation.
Related Articles
- Sidecar Service Meshes with Crunchy Postgres for Kubernetes
12 min read
- pg_incremental: Incremental Data Processing in Postgres
11 min read
- Smarter Postgres LLM with Retrieval Augmented Generation
6 min read
- Postgres Partitioning with a Default Partition
16 min read
- Iceberg ahead! Analyzing Shipping Data in Postgres
8 min read