You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+24-4
Original file line number
Diff line number
Diff line change
@@ -2,13 +2,14 @@
2
2
3
3
This project aims to provide observability for the Oracle Database so that users can understand performance and diagnose issues easily across applications and database. Over time, this project will provide not just metrics, but also logging and tracing support, and integration into popular frameworks like Spring Boot. The project aims to deliver functionality to support both cloud and on-premises databases, including those running in Kubernetes and containers.
4
4
5
-
In the first production release, v1.0, this project provides a [Prometheus](https://prometheus.io/) exporter for Oracle Database that is based in part on a Prometheus exporter created by [Seth Miller](https://github.com/iamseth/oracledb_exporter) with changes to comply with various Oracle standards and policies.
5
+
From the first production release, v1.0, onwards, this project provides a [Prometheus](https://prometheus.io/) exporter for Oracle Database that is based in part on a Prometheus exporter created by [Seth Miller](https://github.com/iamseth/oracledb_exporter) with changes to comply with various Oracle standards and policies.
6
6
7
7
Contributions are welcome - please see [contributing](CONTRIBUTING.md).
- The query for the standard metric `wait_class` has been updated so that it will work in both container databases
34
+
and pluggable databases, including in Oracle Autonomous Database instances. Note that this query will not return
35
+
any data unless the database instance is under load.
36
+
- Support for reading the database password from OCI Vault has been added (see [details](#using-oci-vault))
37
+
- Log messages have been improved
38
+
- Some dependencies have been updated
39
+
40
+
### Version 1.0, September 13, 2023
29
41
30
42
The first production release, v1.0, includes the following features:
31
43
@@ -41,7 +53,7 @@ Note that this exporter uses a different Oracle Database driver which in turn us
41
53
42
54
The interfaces for this version have been kept as close as possible to those of earlier alpha releases in this repository to assist with migration. However, it should be expected that there may be breaking changes in future releases.
43
55
44
-
### Plans
56
+
##Roadmap
45
57
46
58
We always welcome input on features you would like to see supported. Please open an issue in this repository with your suggestions.
47
59
@@ -355,6 +367,14 @@ Usage of oracledb_exporter:
355
367
Path to configuration file that can enable TLS or authentication.
356
368
```
357
369
370
+
### Using OCI Vault
371
+
372
+
The exporter will read the password from a secret stored in OCI Vault if you set these two environment
373
+
variables:
374
+
375
+
-`VAULT_ID` should be set to the OCID of the OCI vault that you wish to use
376
+
-`VAULT_SECRET_NAME` should be set to the name of the secret in the OCI vault which contains the database password
377
+
358
378
## Custom metrics
359
379
360
380
The exporter allows definition of arbitrary custom metrics in a TOML file. To specify this file to the
level.Error(e.logger).Log(fmt.Sprintf("there was an issue while loading specified default metrics file at: "+e.config.DefaultMetricsFile+", proceeding to run with default metrics."), err)
83
+
level.Error(e.logger).Log("msg", fmt.Sprintf("there was an issue while loading specified default metrics file at: "+e.config.DefaultMetricsFile+", proceeding to run with default metrics."),
Copy file name to clipboardExpand all lines: default-metrics.toml
+10-8
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,10 @@ request = "SELECT status, type, COUNT(*) as value FROM v$session GROUP BY status
8
8
context = "resource"
9
9
labels = [ "resource_name" ]
10
10
metricsdesc = { current_utilization= "Generic counter metric from v$resource_limit view in Oracle (current value).", limit_value="Generic counter metric from v$resource_limit view in Oracle (UNLIMITED: -1)." }
11
-
request="SELECT resource_name,current_utilization,CASE WHEN TRIM(limit_value) LIKE 'UNLIMITED' THEN '-1' ELSE TRIM(limit_value) END as limit_value FROM v$resource_limit"
11
+
request = '''
12
+
SELECT resource_name, current_utilization, CASE WHEN TRIM(limit_value) LIKE 'UNLIMITED' THEN '-1' ELSE TRIM(limit_value) END as limit_value
13
+
FROM v$resource_limit
14
+
'''
12
15
13
16
[[metric]]
14
17
context = "asm_diskgroup"
@@ -33,14 +36,13 @@ context = "wait_time"
33
36
metricsdesc = { value="Generic counter metric from v$waitclassmetric view in Oracle." }
34
37
fieldtoappend= "wait_class"
35
38
request = '''
36
-
SELECT
37
-
n.wait_class as WAIT_CLASS,
38
-
round(m.time_waited/m.INTSIZE_CSEC,3) as VALUE
39
-
FROM
40
-
v$waitclassmetric m, v$system_wait_class n
41
-
WHERE
42
-
m.wait_class_id=n.wait_class_id AND n.wait_class != 'Idle'
39
+
SELECT wait_class as WAIT_CLASS, sum(time_waited) as VALUE
0 commit comments