Skip to content

Add resource calculators for elasticsearch.kubedb.com and postgres.kubedb.com - #99

Merged
ArnobKumarSaha merged 1 commit into
masterfrom
arnob-es-pg-rm
Sep 17, 2026
Merged

ArnobKumarSaha merged 1 commit into
masterfrom
arnob-es-pg-rm

Conversation

@ArnobKumarSaha

Copy link
Copy Markdown
Member

Adds resource-metrics calculators for the kinds in kubedb.dev/apimachinery/apis/elasticsearch and apis/postgres.

elasticsearch.kubedb.com/v1alpha1

  • ElasticsearchDashboard: replicas from spec.replicas (default 1), app resources from the elasticsearch container in spec.podTemplate, exporter from spec.monitor.prometheus.exporter, UsesTLS keyed on spec.tls presence. Modeled on the existing ConnectCluster calculator.
  • Test + testdata covering replicas, mode, TLS, and total/app resources.

postgres.kubedb.com/v1alpha1

  • Publisher and Subscriber only configure logical replication on an existing Postgres instance — no pods are created for them — so they register zero-resource calculators. This keeps their GVKs resolvable for callers instead of failing on an unregistered kind.

Other

  • calculator.go: blank imports for both new packages.
  • Makefile: added the two new dirs to SRC_PKGS so make fmt covers them. Note kafka.kubedb.com is still missing from that list (pre-existing, left alone here).

…bedb.com

Register ElasticsearchDashboard with replicas from spec.replicas and app
resources from the elasticsearch container in spec.podTemplate, plus the
prometheus exporter sidecar.

Publisher and Subscriber only configure logical replication on an existing
Postgres instance, so they register zero-resource calculators to keep their
GVKs resolvable.

Signed-off-by: Arnob kumar saha <arnob@appscode.com>
@ArnobKumarSaha
ArnobKumarSaha merged commit 65cd4f3 into master Sep 17, 2026
4 checks passed
@ArnobKumarSaha
ArnobKumarSaha deleted the arnob-es-pg-rm branch September 17, 2026 10:18
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.

1 participant