docs: documentation for validate/petclinic-argo-doc #28

Merged
demo-bot merged 8 commits from documentor-validate-petclinic-argo-doc-ee3ddfc8 into main 2026-06-08 16:23:51 +00:00
8 changed files with 320 additions and 27 deletions

View File

@@ -0,0 +1,104 @@
---
title: "demo-db"
generated_by: documentor-agent
generated_at: "2026-06-08T16:23:01+00:00"
human_edited: false
source_entity: "Component/default/demo-db"
source_repo: "https://gitea.kyndemo.live/validate/petclinic"
---
## Overview
The `demo-db` service is a critical component of the Spring PetClinic application, providing database functionality for the broader system. It supports both in-memory (H2) and persistent database configurations (MySQL and PostgreSQL), enabling flexibility for development and production environments. The service is part of the `petclinic` system and integrates with other platform tools such as OpenTelemetry for observability, K6 for load testing, and Chaos Mesh for chaos engineering.
This service plays a key role in ensuring data persistence and retrieval for the application, supporting features like user management, veterinary records, and appointment scheduling. It is deployed and managed via ArgoCD in the `demo-apps` namespace, with observability and testing capabilities integrated into the deployment pipeline.
## Repository
| Field | Value |
|----------------|-----------------------------------------------------------------------------------------------------------------|
| **Source Repo**| [https://gitea.kyndemo.live/validate/petclinic](https://gitea.kyndemo.live/validate/petclinic) |
| **Branch** | `main` |
| **ArgoCD App** | [petclinic](https://argocd.kyndemo.live/applications/petclinic) |
| **Namespace** | `demo-apps` |
## Architecture
The `demo-db` service is designed to support multiple database configurations, including H2 (in-memory), MySQL, and PostgreSQL. It uses Spring Boot profiles to switch between database types, ensuring flexibility for different deployment scenarios. The service integrates with the following platform tools:
- **OpenTelemetry**: Provides instrumentation for tracing, metrics, and logs, enabling detailed observability.
- **K6**: Facilitates load testing to ensure the service can handle high traffic scenarios.
- **Chaos Mesh**: Enables chaos engineering experiments to test the resilience of the service.
Data flows from the application layer to the database, with Spring Boot managing the connection and configuration. Persistent databases are supported via Docker containers or local installations, with profiles enabling seamless switching.
## Configuration
| Configuration Option | Description |
|----------------------------|-------------------------------------------------------------------------------------------------|
| `spring.profiles.active` | Specifies the active profile (`mysql`, `postgres`, or default for H2). |
| `MYSQL_USER` | MySQL username for the database. |
| `MYSQL_PASSWORD` | MySQL password for the database. |
| `POSTGRES_USER` | PostgreSQL username for the database. |
| `POSTGRES_PASSWORD` | PostgreSQL password for the database. |
| `POSTGRES_DB` | PostgreSQL database name. |
## Operations
### Running Locally
1. Clone the repository:
```bash
git clone https://gitea.kyndemo.live/validate/petclinic.git
cd petclinic
```
2. Start the application:
- Using Maven:
```bash
./mvnw spring-boot:run
```
- Using Gradle:
```bash
./gradlew bootRun
```
3. Access the application at [http://localhost:8080](http://localhost:8080).
### Persistent Database Setup
- **MySQL**:
```bash
docker run -e MYSQL_USER=petclinic -e MYSQL_PASSWORD=petclinic -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=petclinic -p 3306:3306 mysql:9.6
```
- **PostgreSQL**:
```bash
docker run -e POSTGRES_USER=petclinic -e POSTGRES_PASSWORD=petclinic -e POSTGRES_DB=petclinic -p 5432:5432 postgres:18.3
```
### Rollback
1. Open the [ArgoCD UI](https://argocd.kyndemo.live/applications/petclinic).
2. Click **History and Rollback**.
3. Select the desired revision and click **Rollback**.
Alternatively, revert the commit in Git and push — ArgoCD will auto-sync the rollback.
## Observability
This service is configured with OpenTelemetry instrumentation. Observability data is exported to the OTel Collector and visualized in Grafana.
- **Grafana Dashboard**: [View Dashboard](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-service=demo-db)
- **Alerting**: Alerts are configured via Grafana with the label selector `app=demo-db`.
## Dependencies
- `component:default/argocd-service`
- `resource:default/k6-operator`
- `resource:default/otel-collector`
- `resource:default/veterinary-platform`
## Links
- [Live Application](https://petclinic.kyndemo.live)
- [Repository](https://gitea.kyndemo.live/validate/petclinic)
- [ArgoCD App](https://argocd.kyndemo.live/applications/petclinic)
- [Grafana Dashboard](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-service=demo-db)

View File

@@ -0,0 +1,12 @@
{
"sourceShas": {
"catalog-info.yaml": "586b5ecff098a3a746c23e87a9d234513ae13e8b",
"README.md": "ef9b745ac26efecf8340b75eea18b8151ba7a86e",
"docs/adr/index.md": "5672a7b1dfe92a2575152cdaeb01b447c8616288",
"docs/index.md": "e616ef832396cf7283ebed71f0a9ab7bb919e8ab",
"docs/runbooks/index.md": "52e30a9d4507ec6159c6ea8800341c4c18816ad7"
},
"promptVersion": "1.0",
"generatedAt": "2026-06-08T16:23:13+00:00",
"contentHash": "9596a63155c3afd35def3f8a6f9e9acb4db84e08be42d07f6534380638ef2a59"
}

View File

@@ -0,0 +1,92 @@
---
title: "Petclinic Argo Documentation"
generated_by: documentor-agent
generated_at: "2026-06-08T16:22:39+00:00"
human_edited: false
source_entity: "Component/default/petclinic-argo-doc"
source_repo: "https://gitea.kyndemo.live/validate/petclinic-argo-doc"
---
## Overview
The **Petclinic Argo Documentation** service is a deployment of the Spring PetClinic application, managed via ArgoCD and deployed into the `demo-apps` namespace. It serves as a demonstration of modern application deployment practices, including continuous delivery, observability, and chaos engineering. The service integrates OpenTelemetry for tracing and metrics, supports load testing with k6, and enables chaos experiments using Chaos Mesh.
This service is part of the broader **petclinic-argo-doc** system, showcasing how legacy applications can be modernized and deployed using cloud-native tools. It is designed to provide a reference implementation for teams adopting ArgoCD and OpenTelemetry in their workflows.
## Repository
| Field | Value |
|------------------|------------------------------------------------------------------------------------------------|
| **Source Repo** | [Petclinic Argo Documentation](https://gitea.kyndemo.live/validate/petclinic-argo-doc) |
| **Branch** | `main` |
| **ArgoCD App** | [petclinic-argo-doc](https://argocd.kyndemo.live/applications/petclinic-argo-doc) |
| **Namespace** | `demo-apps` |
## Architecture
The **Petclinic Argo Documentation** service is built on the Spring Boot framework and deployed using ArgoCD. Key architectural components include:
- **Source Repository**: The application is cloned from the [Spring PetClinic GitHub repository](https://github.com/spring-projects/spring-petclinic) and customized for deployment.
- **Continuous Delivery**: ArgoCD monitors the `main` branch for changes and automatically syncs updates to the Kubernetes cluster.
- **Observability**: OpenTelemetry instrumentation is applied via Kustomize overlays, exporting traces and metrics to a centralized OTel Collector.
- **Load Testing**: k6 is configured for performance testing, targeting the `frontend` service.
- **Chaos Engineering**: Chaos Mesh is enabled to simulate failure scenarios and improve system resilience.
Data flows through the application using an in-memory H2 database by default, with options for MySQL or PostgreSQL for persistent storage.
## Configuration
| Configuration Item | Description |
|-----------------------------|-----------------------------------------------------------------------------|
| `spring.profiles.active` | Sets the active profile (`mysql`, `postgres`, or default `h2`). |
| `k6/test-configmap` | ConfigMap for k6 load testing (`k6-test-petclinic-argo-doc`). |
| `k6/test-namespace` | Namespace for k6 tests (`demo-apps`). |
| `chaos-mesh/enabled` | Enables Chaos Mesh for chaos experiments (`true`). |
| `grafana/dashboard-selector` | Selector for Grafana dashboards (`uid == 'otel-app-observability-v2'`). |
## Operations
### Deployment
1. Clone the repository:
```bash
git clone https://gitea.kyndemo.live/validate/petclinic-argo-doc.git
cd petclinic-argo-doc
```
2. Make changes and push:
```bash
git add . && git commit -m "your change" && git push origin main
```
3. ArgoCD will automatically sync changes to the `demo-apps` namespace.
### Rollback
1. Open the [ArgoCD UI](https://argocd.kyndemo.live/applications/petclinic-argo-doc).
2. Click **History and Rollback**.
3. Select the desired revision and click **Rollback**.
Alternatively, revert the commit in Git and push — ArgoCD will auto-sync the rollback.
## Observability
This service is fully instrumented with OpenTelemetry. Observability features include:
- **Grafana Dashboard**: [View Dashboard](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-app=petclinic-argo-doc)
- **Alerting**: Alerts are configured in Grafana and can be filtered by `app=petclinic-argo-doc`.
- **OTel Collector Endpoint**: `http://otel-collector.monitoring.svc.cluster.local:4318`
_Additional observability details can be found in the platform observability documentation._
## Dependencies
- `component:default/argocd-service`
- `resource:default/k6-operator`
- `resource:default/otel-collector`
- `resource:default/veterinary-platform`
## Links
- [Live Application](https://petclinic-argo-doc.kyndemo.live)
- [Repository](https://gitea.kyndemo.live/validate/petclinic-argo-doc)
- [ArgoCD App](https://argocd.kyndemo.live/applications/petclinic-argo-doc)
- [Grafana Dashboard](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-app=petclinic-argo-doc)

View File

@@ -0,0 +1,12 @@
{
"sourceShas": {
"catalog-info.yaml": "586b5ecff098a3a746c23e87a9d234513ae13e8b",
"README.md": "ef9b745ac26efecf8340b75eea18b8151ba7a86e",
"docs/adr/index.md": "5672a7b1dfe92a2575152cdaeb01b447c8616288",
"docs/index.md": "e616ef832396cf7283ebed71f0a9ab7bb919e8ab",
"docs/runbooks/index.md": "52e30a9d4507ec6159c6ea8800341c4c18816ad7"
},
"promptVersion": "1.0",
"generatedAt": "2026-06-08T16:22:53+00:00",
"contentHash": "0d14ed6c390b032af7ca93aff5729d1b0f737598354c88dfda33e43674824e56"
}

View File

@@ -1,7 +1,7 @@
---
title: "Petclinic Service"
generated_by: documentor-agent
generated_at: "2026-06-08T16:14:03+00:00"
generated_at: "2026-06-08T16:23:20+00:00"
human_edited: false
source_entity: "Component/default/petclinic"
source_repo: "https://gitea.kyndemo.live/validate/petclinic"
@@ -9,11 +9,9 @@ source_repo: "https://gitea.kyndemo.live/validate/petclinic"
## Overview
The Petclinic service is a Spring Boot application designed to manage veterinary clinic operations, including scheduling appointments, managing pet records, and handling customer information. It serves as a foundational component of the broader Petclinic system, providing essential functionality for veterinary platforms.
The Petclinic service is a Spring Boot application designed to manage veterinary clinic operations, including scheduling appointments, managing pet records, and handling customer information. It serves as a foundational component of the broader Petclinic system, providing essential business logic and data management capabilities.
This service is built using Java 17 and leverages Spring Boot for rapid development and deployment. It supports multiple database configurations, including in-memory H2, MySQL, and PostgreSQL, making it adaptable to various environments. Observability is integrated via OpenTelemetry, enabling detailed monitoring and performance analysis.
Petclinic plays a critical role in the system by ensuring reliable and scalable management of veterinary clinic data, while also serving as a demonstration of modern application development practices.
This service is deployed in the `demo-apps` namespace and managed via ArgoCD. It integrates with OpenTelemetry for observability, supports load testing via k6, and includes chaos engineering capabilities through Chaos Mesh. The application is built using Java 17 and can be run locally or deployed in containerized environments.
## Repository
@@ -26,25 +24,25 @@ Petclinic plays a critical role in the system by ensuring reliable and scalable
## Architecture
The Petclinic service is a Spring Boot application deployed via ArgoCD in the `demo-apps` namespace. It integrates OpenTelemetry for observability and supports multiple database configurations, including H2, MySQL, and PostgreSQL. The deployment process involves continuous synchronization from the `main` branch of the source repository.
The Petclinic service is a Spring Boot application that communicates with an in-memory H2 database by default. It supports integration with MySQL and PostgreSQL for persistent storage, configurable via Spring profiles. The service is instrumented with OpenTelemetry for tracing and metrics, and its deployment is managed by ArgoCD, ensuring continuous synchronization with the source repository.
Key architectural components:
- **Spring Boot Framework**: Provides the core application structure and dependency management.
- **Database Configurations**: Supports H2 (default), MySQL, and PostgreSQL, with profiles for switching between them.
- **OpenTelemetry Integration**: Enables tracing, metrics, and logging for detailed observability.
- **ArgoCD Deployment**: Ensures continuous delivery and synchronization of application updates.
- **Spring Boot Framework**: Provides the application runtime and dependency management.
- **Database Options**: Default H2 database, with optional MySQL or PostgreSQL configurations.
- **Observability**: OpenTelemetry instrumentation for metrics, traces, and logs.
- **Deployment**: Managed via ArgoCD in the `demo-apps` namespace.
<!-- TODO: FILL IN -->
## Configuration
| Configuration Option | Description |
|-------------------------------|-------------------------------------------------------------------------------------------------|
| `spring.profiles.active` | Sets the active profile for database configuration (`mysql`, `postgres`, or default `h2`). |
| `MYSQL_USER` | MySQL username for database authentication. |
| `MYSQL_PASSWORD` | MySQL password for database authentication. |
| `POSTGRES_USER` | PostgreSQL username for database authentication. |
| `POSTGRES_PASSWORD` | PostgreSQL password for database authentication. |
|----------------------------|-------------------------------------------------------------------------------------------------|
| `spring.profiles.active` | Sets the active Spring profile (`mysql`, `postgres`, or default for H2). |
| `MYSQL_USER` | MySQL username for database connection. |
| `MYSQL_PASSWORD` | MySQL password for database connection. |
| `POSTGRES_USER` | PostgreSQL username for database connection. |
| `POSTGRES_PASSWORD` | PostgreSQL password for database connection. |
## Operations
@@ -75,21 +73,23 @@ Key architectural components:
docker run -p 8080:8080 docker.io/library/spring-petclinic:latest
```
### Rollback
1. Open the [ArgoCD UI](https://argocd.kyndemo.live/applications/petclinic).
2. Click **History and Rollback**.
3. Select the desired revision and click **Rollback**.
Alternatively, revert the commit in Git and push — ArgoCD will auto-sync the rollback.
### Database Configuration
- Default: In-memory H2 database.
- MySQL:
```bash
docker run -e MYSQL_USER=petclinic -e MYSQL_PASSWORD=petclinic -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=petclinic -p 3306:3306 mysql:9.6
```
- PostgreSQL:
```bash
docker run -e POSTGRES_USER=petclinic -e POSTGRES_PASSWORD=petclinic -e POSTGRES_DB=petclinic -p 5432:5432 postgres:18.3
```
## Observability
This service is configured with OpenTelemetry instrumentation. Metrics, traces, and logs are exported to the OTel Collector and visualized in Grafana.
The Petclinic service is fully instrumented with OpenTelemetry for observability. Metrics, traces, and logs are exported to the OTel Collector and visualized in Grafana.
- **Grafana Dashboard**: [Petclinic Observability](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-service=petclinic)
- **Alerting**: Alerts are configured via Grafana and can be filtered by `app=petclinic`.
_Additional observability details are available in the platform observability documentation._
- **Alerting**: Configured via Grafana with label selector `app=petclinic`.
## Dependencies

View File

@@ -0,0 +1,12 @@
{
"sourceShas": {
"catalog-info.yaml": "586b5ecff098a3a746c23e87a9d234513ae13e8b",
"README.md": "ef9b745ac26efecf8340b75eea18b8151ba7a86e",
"docs/adr/index.md": "5672a7b1dfe92a2575152cdaeb01b447c8616288",
"docs/index.md": "e616ef832396cf7283ebed71f0a9ab7bb919e8ab",
"docs/runbooks/index.md": "52e30a9d4507ec6159c6ea8800341c4c18816ad7"
},
"promptVersion": "1.0",
"generatedAt": "2026-06-08T16:23:32+00:00",
"contentHash": "a8718f85b0735a2c24e944370da8c7f87641596f3d381667a8406ecb8a353b17"
}

View File

@@ -0,0 +1,53 @@
---
title: "Petclinic Argo Documentation System"
generated_by: documentor-agent
generated_at: "2026-06-08T16:22:23+00:00"
human_edited: false
source_entity: "System/default/petclinic-argo-doc"
source_repo: "https://gitea.kyndemo.live/validate/petclinic-argo-doc"
---
## Overview
The **Petclinic Argo Documentation System** is a deployment system managed via ArgoCD, designed to support the **demo-apps** namespace. It integrates observability tools like OpenTelemetry and Grafana, along with load testing capabilities using K6 and chaos engineering via Chaos Mesh. This system is part of the broader **apps** domain and serves as a foundational platform for deploying and managing services such as **petclinic**, **demo-db**, and other related components.
The system is owned by the **platform-engineering** team and is configured to ensure high reliability and performance for applications deployed in the **demo-apps** namespace. It leverages Kubernetes for orchestration and includes monitoring and alerting capabilities to maintain operational excellence.
## Ownership
| Owner | Domain | Namespace | Labels |
|----------------------|--------|-----------|-------------------------------------|
| platform-engineering | apps | default | backstage.io/environment: dev<br>app.kubernetes.io/managed-by: backstage |
## Components
- **petclinic-argo-doc**: The main service deployed via ArgoCD.
- **demo-db**: A database service that is part of the system.
- **petclinic**: A Java-based service included in the system.
## APIs
_No APIs declared._
## Resources
- **k6-operator**: Load testing operator for K6.
- **otel-collector**: OpenTelemetry collector for observability.
- **otel-operator**: OpenTelemetry operator for managing observability configurations.
- **veterinary-platform**: A resource supporting the petclinic ecosystem.
## Relationships
- **Depends On**:
- **argocd-service**: A service for managing ArgoCD deployments.
- **k6-operator**: For load testing.
- **otel-collector**: For observability data collection.
- **otel-operator**: For managing observability configurations.
- **veterinary-platform**: Supporting resources for the petclinic ecosystem.
## Links
- [Live Application](https://petclinic-argo-doc.kyndemo.live)
- [Repository](https://gitea.kyndemo.live/validate/petclinic-argo-doc)
- [ArgoCD App](https://argocd.kyndemo.live/applications/petclinic-argo-doc)
- [Grafana Dashboard](https://grafana.kyndemo.live/d/otel-app-observability-v2/opentelemetry-application-observability?orgId=1&var-app=petclinic-argo-doc)

View File

@@ -0,0 +1,8 @@
{
"sourceShas": {
"catalog-info.yaml": "586b5ecff098a3a746c23e87a9d234513ae13e8b"
},
"promptVersion": "1.0",
"generatedAt": "2026-06-08T16:22:32+00:00",
"contentHash": "0038c5f87e64150770719113186bd41d0f4cddbd4680475dd1ffa3a27cfed250"
}