Skip to content

Commit 4ab52e3

Browse files
committed
add README
1 parent fc6934f commit 4ab52e3

File tree

1 file changed

+28
-0
lines changed
  • client-java-contrib/prometheus-operator

1 file changed

+28
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Cert-Manager Model Classes
2+
This module contains the Java model classes generated from the release version of [prometheus operator](https://github.com/prometheus-operator/prometheus-operator) CRDs.
3+
4+
It makes it possible to CRUD custom resources defined by `prometheus operator` in a strong-typed manner in your Java application, such as create a prometheus instance, write a prometheus rule, etc.
5+
## Usage
6+
To use this library, include the following maven dependency
7+
```xml
8+
<dependency>
9+
<groupId>io.kubernetes</groupId>
10+
<artifactId>client-java-prometheus-operator-models</artifactId>
11+
<version>0.38.1-SNAPSHOT</version>
12+
</dependency>
13+
```
14+
Please refer to the [PromOpExample](../../examples/src/main/java/io/kubernetes/client/examples/PromOpExample.java), which demonstrates how to create a minimal prometheus instance with the model class and Kubernetes Java client generic API.
15+
## Compatibility
16+
Artifact Version|Cert-Manager Release Version|CRD Source
17+
----------------|----------------------------|----------
18+
0.38.1-SNAPSHOT|0.38.1|[Here](https://github.com/prometheus-operator/prometheus-operator/tree/master/example/prometheus-operator-crd)
19+
## Code Generation
20+
There is a utility script [update.sh](update.sh) to help with the code generation.
21+
22+
* The only prerequisites required is Docker installed on the host
23+
24+
Under the `prometheus-operator` directory, execute:
25+
```shell script
26+
./update.sh
27+
```
28+
It will generate the model classes from the CRDs hosted at the URL specified via the `-u` options in the [update.sh](update.sh) script. If newer version of CRDs becomes available, just update the `-u` options accordingly.

0 commit comments

Comments
 (0)