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
| Prisma (Node) | :material-check-circle-outline: | Generates a lot of unique prepared statements, consider limiting the [prepared statements cache](#prisma). |
22
22
| Sequelize (Node) | :material-check-circle-outline: | Uses `node-postgres` under the hood, no limitations. |
We benchmarked this to be 5 times faster than normal `pg_query` parsing, which should help.
59
59
60
-
### Postgres.js
61
-
62
-
`postgres` Node driver uses a combination of named and unnamed prepared statements. For [load balancing](features/load-balancer/index.md) or [sharding](features/sharding/index.md) to work correctly, PgDog needs to cache all prepared statements, including unnamed ones (we call them "anonymous"). This is not the default behavior and requires the following setting:
63
-
64
-
```toml
65
-
[general]
66
-
prepared_statements = "extended_anonymous"
67
-
```
68
-
69
60
### Prisma
70
61
71
62
Prisma doesn't correctly use the `IN` clause with arrays, causing it to generate a very large number of unique prepared statements. This is not a big problem, but if left unchecked, can cause heavy memory usage in PgDog. Consider setting a lower prepared statements [cache limit](features/prepared-statements.md#cache-limit):
@@ -74,12 +65,3 @@ Prisma doesn't correctly use the `IN` clause with arrays, causing it to generate
74
65
[general]
75
66
prepared_statements_limit = 1_000
76
67
```
77
-
78
-
### lib/pq
79
-
80
-
`lib/pq` (Go) uses unnamed prepared statements which PgDog has to cache for [load balancing](features/load-balancer/index.md) or [sharding](features/sharding/index.md) to work correctly. This is not the default behavior and requires the following setting:
Some OpenMetrics implementations don't support special characters in the metric name (e.g., periods, commas, etc.). In that case,
65
66
you can use an underscore (`_`) instead.
66
67
68
+
## OTEL
69
+
70
+
OTEL is a standard for publishing metrics to compatible systems, like Grafana, Prometheus and other providers like Datadog. PgDog can export metrics to a configured endpoint on an interval, making metrics collection work out of the box.
71
+
72
+
### Configuration
73
+
74
+
OTEL export is disabled by default. To enable it, configure the collector endpoint and the necessary credentials. If you're using Datadog, you can set the API key as a separate setting:
All metrics by default will be pushed to the `pgdog` namespace. For example, `sv_active` will be reported as `pgdog.sv_active`. The namespace is configurable, for example:
0 commit comments