Skip to content

Update TxEventQ demo #104

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ dist/
*.key
oci8.pc
*.skip
.vscode
.vscode
**/target/
17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ The exporter includes a set of metrics for monitoring TxEventQ and a pre-built G

> Note: The metrics are written for Oracle Database 21c or later.

### How to create a topic
### How to create some traffic with PL/SQL

If you need to create a topic to monitor, you can use these statements to create and start a topic, and create a subscriber:

Expand Down Expand Up @@ -807,6 +807,19 @@ begin
end;
```

### How to create some traffic with Java (Spring Boot)

A simple load generator is provided in [this directory](./docker-compose/txeventq-load/) which you can use to create some traffic so you can experiment with the sample dashboard.

To run the sample, first update [application.yaml](./docker-compose/txeventq-load/src/main/resources/application.yaml) with the correct IP address for your database, then start the application as follows:

```bash
mvn spring-boot:run
```

The application will create ten queues names TOPIC_0 through TOPIC_9 and randomly produce and consume messages on those queues. The example dashboard shown below was monitoring traffic produced using this application.


### Metrics definitions

The metrics definitions are provided in [this file](./custom-metrics-example/txeventq-metrics.toml). You need to provide this file to the exporter, e.g., by adding it to your container image, or creating a Kubernetes config map containing the file and mounting that config map as a volume in your deployment. You also need to set the `CUSTOM_METRICS` environment variable to the location of this file.
Expand Down Expand Up @@ -835,7 +848,7 @@ A Grafana dashboard for Transactional Event Queues is provided [in this file](./

The dashboard will look like this:

![](./doc/txeventq-dashboard.png)
![](./doc/txeventq-dashboard-v2.png)

## Developer notes

Expand Down
Binary file added doc/txeventq-dashboard-v2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docker-compose/compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ services:
ports:
- 9161:9161
environment:
- DB_USERNAME=system
- DB_USERNAME=pdbadmin
- DB_PASSWORD=Welcome12345
- DB_CONNECT_STRING=free23c:1521/free
- DB_CONNECT_STRING=free23c:1521/freepdb1
- CUSTOM_METRICS=/exporter/txeventq-metrics.toml
volumes:
- ./exporter:/exporter
Expand Down
Loading