Setup pulp metrics catalog for preprod
Similar to packagecloud metrics-catalog setup, this MR is to set up metrics for pulp
service in the preprod
instance.
- LB is a pulp-specific nginx ingress service
pulp-ingress-nginx-controller
- The CloudSQL instance: https://console.cloud.google.com/sql/instances/pulp-ce6e8d88/overview?hl=en&project=gitlab-pre
- GCS bucket: https://console.cloud.google.com/storage/browser/packages-pre;tab=monitoring?forceOnBucketsSortingFiltering=true&hl=en&project=gitlab-pre&prefix=&forceOnObjectsSortingFiltering=false
- Redis instance: https://console.cloud.google.com/memorystore/redis/locations/us-east1/instances/pulp-redis/details/monitoring?hl=en&project=gitlab-pre
The deployments are in the pulp
namespace, in the pre
k8s cluster (where I got the containers names from)
The api names that were used for gauge
s were from the google api like https://cloud.google.com/monitoring/api/metrics_gcp_c#gcp-cloudsql for stackdriver_cloudsql_database_cloudsql_googleapis_com_database_postgresql_statements_executed_count
(database/postgresql/statements_executed_count
on that api doc)
I just wanted to get the metrics in, but various pipeline jobs prevented me from not having files for a dashboard, so that's also included in this.
More context for reviewers
For reviewers who are less familiar with this setup, I recommend starting from metrics-catalog/services/pulp.jsonnet
file, as that's the main file that has the metrics, then everything came after, as more or less dependencies and/or automatically generated files.
For those who are unfamiliar with Pulp, the infra architecture diagram is here: https://ops.gitlab.net/gitlab-com/gl-infra/terraform-modules/applications/pulp/-/blob/main/ARCHITECTURE.md?ref_type=heads
The key difference from the packagecloud infra relevant to this MR is that packagecloud uses an external GCP loadbalancer, where as in for pulp, it uses a pulp-dedicated nginx ingress load balancer svc in k8s namespace pulp
.
Ref: https://gitlab.com/gitlab-org/build/team-tasks/-/issues/52