Skip to content

Commit 236e793

Browse files
authored
Document how to deprioritize new crates (#389)
1 parent ccf4e6b commit 236e793

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

src/docs-rs/maintenance.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,27 @@ cratesfyi=> INSERT INTO sandbox_overrides (crate_name, max_memory_bytes)
8383
VALUES ('stm32f4', 8589934592), ('stm32h7', 8589934592), ('stm32g4', 8589934592);
8484
```
8585

86+
## Set a group of crates to be automatically de-prioritized
87+
88+
When many crates from the same project are published at once, they take up a
89+
lot of space in the queue. You can de-prioritize groups of crates at once like
90+
this:
91+
92+
```psql
93+
cratesfyi=> INSERT INTO crate_priorities (pattern, priority)
94+
VALUES ('group-%', 1);
95+
```
96+
97+
The `pattern` should be a `LIKE` pattern as documented on
98+
<https://www.postgresql.org/docs/current/functions-matching.html>.
99+
100+
Note that this only sets the default priority for crates with that name.
101+
If there are crates already in the queue, you'll have to update those manually:
102+
103+
```psql
104+
cratesfyi=> UPDATE queue SET priority = 1 WHERE name LIKE 'group-%';
105+
```
106+
86107
## Adding all the crates failed after a date back in the queue
87108

88109
After an outage you might want to add all the failed builds back to the queue.

0 commit comments

Comments
 (0)