Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/reugn/micrometer-registry-aerospike
A Micrometer MeterRegistry for Aerospike
https://github.com/reugn/micrometer-registry-aerospike
aerospike metrics micrometer
Last synced: about 2 months ago
JSON representation
A Micrometer MeterRegistry for Aerospike
- Host: GitHub
- URL: https://github.com/reugn/micrometer-registry-aerospike
- Owner: reugn
- License: apache-2.0
- Created: 2022-06-04T12:19:35.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-06-05T16:35:01.000Z (over 2 years ago)
- Last Synced: 2024-04-18T11:23:21.985Z (9 months ago)
- Topics: aerospike, metrics, micrometer
- Language: Java
- Homepage:
- Size: 70.3 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# micrometer-registry-aerospike
[![Build](https://github.com/reugn/micrometer-registry-aerospike/actions/workflows/build.yml/badge.svg)](https://github.com/reugn/micrometer-registry-aerospike/actions/workflows/build.yml)## Library tools
* A [Micrometer](https://micrometer.io/) registry implementation for sending metrics to [Aerospike](https://aerospike.com/).
* A metric-aware [Aerospike Java Client](https://github.com/aerospike/aerospike-client-java) to collect miscellaneous activity information using one of the Micrometer registries.## Build
```sh
./gradlew clean build
```## Examples
* Create an Aerospike Micrometer registry. Use `AerospikeConfig` for configuration.
```java
AerospikeConfig config = new AerospikeConfig() {
@Override
public String get(@Nonnull String key) {
return null;
}@Override
@Nonnull
public Duration step() {
return Duration.ofSeconds(1);
}
};
MeterRegistry registry = new AerospikeMeterRegistry(config, Clock.SYSTEM);
```* Create a metric aware Aerospike client. See the previous example for the `config` and `registry` variables.
```java
IAerospikeClient client = new AerospikeClientMicrometer(
new AerospikeClient(config.clientPolicy(), config.hosts()),
registry
);
```More examples can be found in the tests section.