mirror of
https://github.com/pgvector/pgvector.git
synced 2026-07-13 08:06:54 +08:00
Added link to PgHero [skip ci]
This commit is contained in:
14
README.md
14
README.md
@@ -757,19 +757,7 @@ Scale horizontally with [replicas](https://www.postgresql.org/docs/current/hot-s
|
|||||||
|
|
||||||
## Monitoring
|
## Monitoring
|
||||||
|
|
||||||
Monitor performance with [pg_stat_statements](https://www.postgresql.org/docs/current/pgstatstatements.html) (be sure to add it to `shared_preload_libraries`).
|
Use existing tools like [pg_stat_statements](https://www.postgresql.org/docs/current/pgstatstatements.html) or [PgHero](https://github.com/ankane/pghero) to monitor performance.
|
||||||
|
|
||||||
```sql
|
|
||||||
CREATE EXTENSION pg_stat_statements;
|
|
||||||
```
|
|
||||||
|
|
||||||
Get the most time-consuming queries with:
|
|
||||||
|
|
||||||
```sql
|
|
||||||
SELECT query, calls, ROUND((total_plan_time + total_exec_time) / calls) AS avg_time_ms,
|
|
||||||
ROUND((total_plan_time + total_exec_time) / 60000) AS total_time_min
|
|
||||||
FROM pg_stat_statements ORDER BY total_plan_time + total_exec_time DESC LIMIT 20;
|
|
||||||
```
|
|
||||||
|
|
||||||
Monitor recall by comparing results from approximate search with exact search.
|
Monitor recall by comparing results from approximate search with exact search.
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user