3.5 KiB
title, generated_by, generated_at, human_edited, source_entity, source_repo
| title | generated_by | generated_at | human_edited | source_entity | source_repo |
|---|---|---|---|---|---|
| Petclinic | documentor-agent | 2026-05-05T11:02:41+00:00 | false | Component/default/petclinic | https://gitea.kyndemo.live/validate/petclinic-demo-jonathan-scaf-2 |
Petclinic
A Spring Boot–based application for managing veterinary clinic operations, including scheduling, customer management, and pet records.
Overview
The Petclinic service is a Java-based application built using Spring Boot. It provides a comprehensive platform for managing veterinary clinic operations, including scheduling appointments, managing customer and pet records, and handling clinic workflows. Originally sourced from the Spring Petclinic project, this service has been adapted and deployed using Backstage templates to integrate with modern observability and deployment tools.
The application supports multiple database configurations, including in-memory H2, MySQL, and PostgreSQL, and is designed to be easily deployable in containerized environments. It includes OpenTelemetry instrumentation for enhanced observability and integrates with Grafana for monitoring and alerting. The service is part of the broader petclinic-demo-jonathan-scaf-2 system and is managed via ArgoCD for continuous deployment.
Repository
| Field | Value |
|---|---|
| Source Repo | Petclinic Repository |
| Branch | main |
| ArgoCD App | petclinic-demo-jonathan-scaf-2 |
| Namespace | demo-apps |
Architecture
- The Petclinic service is scaffolded using the Backstage Application Migration Factory template.
- Deployment flow:
- Source code cloned from the original Spring Petclinic repository.
- Backstage overlays applied for CI workflows and catalog entity creation.
- OpenTelemetry auto-instrumentation injected via Kustomize overlays.
- ArgoCD application created targeting the
demo-appsnamespace. - Continuous sync from the
mainbranch ensures up-to-date deployments.
- Observability is enabled with OpenTelemetry, exporting traces, metrics, and logs to the OTel Collector, visualized in Grafana.
Configuration
| Configuration | Description |
|---|---|
spring.profiles.active |
Specifies the active Spring profile (mysql, postgres, or default H2). |
| Database URLs | JDBC URLs for H2, MySQL, and PostgreSQL databases. |
| Docker Compose | Predefined services for MySQL and PostgreSQL databases. |
| OTel Collector Endpoint | http://otel-collector.monitoring.svc.cluster.local:4318 |
Operations
-
Local Development:
- Clone the repository:
git clone https://gitea.kyndemo.live/validate/petclinic-demo-jonathan-scaf-2.git - Start the application using Maven or Gradle:
./mvnw spring-boot:runor./gradlew bootRun. - Access the application at
http://localhost:8080.
- Clone the repository:
-
Deployment:
- ArgoCD monitors the repository and automatically syncs changes to the
demo-appsnamespace. - Rollback can be performed via the ArgoCD UI or by reverting commits in Git.
- ArgoCD monitors the repository and automatically syncs changes to the
Observability
- Grafana Dashboard: OpenTelemetry Application Observability
- Alerts: Configured via Grafana with label selector
app=petclinic. - Instrumentation: OpenTelemetry auto-instrumentation enabled.
Dependencies
component:default/argocd-serviceresource:default/k6-operatorresource:default/otel-collectorresource:default/veterinary-platform