#3963 Add indices to standard_buildroot.
Opened 2 years ago by tkopecek. Modified 11 months ago

As this is often queried table, we could add more indices there by default. Potential candidates:

"standard_buildroot_pkey" PRIMARY KEY, btree (buildroot_id)
"standard_buildroot_create_event" btree (create_event)
"standard_buildroot_host_id" btree (host_id)
"standard_buildroot_repo_id" btree (repo_id)
"standard_buildroot_retire_event" btree (retire_event)
"standard_buildroot_task_id" btree (task_id)

Metadata Update from @tkopecek:
- Custom field Size adjusted to None
- Issue set to the milestone: 1.35

2 years ago

Doing 'create index concurrently standard_buildroot_host_id on standard_buildroot(host_id);' here really really helped our load on the fedoraproject koji.

Are we still aiming for this in 1.35?

It's a bit unclear which of these would make the most sense, though. Kojira does call repo_references quite a bit and that could benefit from the repo_id index.

otoh, query_buildroots/listBuildroots could benefit from nearly all of them at least for joins, and is called several places (notably quite regularly by the builders)

buildroot_id is already a primary key though. We don't need to add that one

Well, I've filed #4134 which adds them all. We could always drop some later if we see they aren't getting used

Metadata Update from @tkopecek:
- Issue set to the milestone: 1.36 (was: 1.35)

11 months ago

Log in to comment on this ticket.

Metadata
Related Pull Requests
  • #4134 Last updated 2 months ago