explain.depesz.com

PostgreSQL's explain analyze made readable

Result: YNi2

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 8.237 ↓ 0.0 0 1

Nested Loop (cost=97.21..918.51 rows=1 width=150) (actual time=8.237..8.237 rows=0 loops=1)

  • Join Filter: (cluster_groups.cluster_id = clusters.id)
  • Buffers: shared hit=731 read=2
  • I/O Timings: read=0.031
2. 0.000 8.236 ↓ 0.0 0 1

Nested Loop (cost=96.92..917.92 rows=1 width=158) (actual time=8.236..8.236 rows=0 loops=1)

  • Join Filter: (projects.namespace_id = namespaces.id)
  • Buffers: shared hit=731 read=2
  • I/O Timings: read=0.031
3. 0.001 8.236 ↓ 0.0 0 1

Nested Loop (cost=96.49..915.91 rows=1 width=166) (actual time=8.236..8.236 rows=0 loops=1)

  • Buffers: shared hit=731 read=2
  • I/O Timings: read=0.031
4. 0.000 8.235 ↓ 0.0 0 1

Nested Loop (cost=96.06..911.28 rows=1 width=20) (actual time=8.235..8.235 rows=0 loops=1)

  • Buffers: shared hit=731 read=2
  • I/O Timings: read=0.031
5. 0.132 8.235 ↓ 0.0 0 1

Hash Join (cost=95.77..910.51 rows=2 width=16) (actual time=8.235..8.235 rows=0 loops=1)

  • Hash Cond: (projects.namespace_id = cluster_groups.group_id)
  • Buffers: shared hit=731 read=2
  • I/O Timings: read=0.031
6. 6.680 6.680 ↑ 1.1 524 1

Index Scan using projects_pkey on projects (cost=0.43..808.02 rows=570 width=8) (actual time=0.055..6.680 rows=524 loops=1)

  • Index Cond: ((id >= 1) AND (id <= 1000))
  • Buffers: shared hit=461 read=1
  • I/O Timings: read=0.012
7. 0.450 1.423 ↑ 1.0 2,691 1

Hash (cost=61.68..61.68 rows=2,693 width=8) (actual time=1.423..1.423 rows=2,691 loops=1)

  • Buckets: 4096 Batches: 1 Memory Usage: 138kB
  • Buffers: shared hit=267 read=1
  • I/O Timings: read=0.019
8. 0.973 0.973 ↑ 1.0 2,691 1

Index Only Scan using index_cluster_groups_on_cluster_id_and_group_id on cluster_groups (cost=0.28..61.68 rows=2,693 width=8) (actual time=0.047..0.973 rows=2,691 loops=1)

  • Heap Fetches: 1065
  • Buffers: shared hit=267 read=1
  • I/O Timings: read=0.019
9. 0.000 0.000 ↓ 0.0 0

Index Scan using index_clusters_applications_prometheus_on_cluster_id on clusters_applications_prometheus (cost=0.28..0.38 rows=1 width=4) (never executed)

  • Index Cond: (cluster_id = cluster_groups.cluster_id)
  • Filter: (status = ANY ('{3,5}'::integer[]))
10. 0.000 0.000 ↓ 0.0 0

Index Scan using index_services_on_project_id on services (cost=0.43..4.62 rows=1 width=150) (never executed)

  • Index Cond: (project_id = projects.id)
  • Filter: ((NOT active) AND ((type)::text = 'PrometheusService'::text) AND (properties = '{}'::text))
11. 0.000 0.000 ↓ 0.0 0

Index Only Scan using namespaces_pkey on namespaces (cost=0.43..2.00 rows=1 width=4) (never executed)

  • Index Cond: (id = cluster_groups.group_id)
  • Heap Fetches: 0
12. 0.000 0.000 ↓ 0.0 0

Index Scan using clusters_pkey on clusters (cost=0.29..0.58 rows=1 width=4) (never executed)

  • Index Cond: (id = clusters_applications_prometheus.cluster_id)
  • Filter: (cluster_type = 2)
Planning time : 11.207 ms
Execution time : 8.411 ms