Quader Docs 0.176.0

Download limits and usage

See what every caller downloads, set how much each may take at the instance, a project and a repository, and lift a block.

On this page

The model

Who
admin changes the instance's limits, security-admin and auditor read them; a project's Owner sets the project's own
Where
Admin area › Identity › Download limits and Usage; the project's Usage and Settings

Every request to a repository's address is charged to a caller: a user (sessions and personal tokens together), a technical token, a CI project, a ClamAV installation's client certificate, or an anonymous address (an IPv4 address, or an IPv6 /64).

Figure At the limit
Requests per second (with a burst) and per hour 429 with the time to wait; a refused request does not count
From the cache, MB per second; from the upstream, MB per second The transfer is slowed
From the cache, GB per hour; GB per day 429 before the next download starts
From the upstream, GB per hour; upstream requests per hour What is cached is still served, what needs the upstream is refused
Parallel transfers A further one waits up to 10 seconds, then 429. Each layer of an image or package of an install is one transfer
Refused requests per hour Blocked for the block time. Refusals of access, failed credentials and unknown repositories count; a 429 does not

A profile is a named set of these figures; an empty figure is unlimited. A rule gives a profile to a caller at a place, optionally with single figures changed. Quader tries the repository's rules, then the project's, then the instance's; at each place a rule for the caller, else its groups (users and technical tokens; per figure the most generous), else the rule of its kind. An administrator is decided at the instance alone. A remote repository also has ceilings: what all anonymous and all signed-in callers may fetch from its upstream together.

The built-in profiles

Without other rules a signed-in user gets Standard, a technical token and a CI job Technical, an anonymous caller Anonymous, an administrator Unlimited.

Figure Anonymous Restricted Standard Technical
Requests per second, burst 50, 1,000 100, 1,000 200, 4,000 1,000, 20,000
Requests per hour 20,000 25,000 100,000 1,000,000
From the cache 100 MB/s, 30 GB/h 100 MB/s, 50 GB/h 250 MB/s, 300 GB/h 1,250 MB/s, 3,000 GB/h
From the upstream 50 MB/s, 20 GB/h 50 MB/s, 20 GB/h 125 MB/s, 100 GB/h 250 MB/s, 500 GB/h
Upstream requests per hour 3,000 3,000 20,000 100,000
Parallel transfers 64 64 250 1,000
GB per day 200 200 1,000 30,000
Refused requests per hour 300 300 1,000 5,000

They are sized so that a large company's normal use never meets them. Standard takes a cold install of 4,000 npm packages twice in an hour; Technical takes twenty parallel CI jobs installing 475 packages each on a cold cache.

Warning

No profile gives what a public registry refuses. Docker Hub allows an address without an account 100 pulls in six hours, and each first pull through a remote is one. For a busy Docker Hub remote, give it a paid account, or set its ceilings to what the account allows. An installation that serves the internet lowers Anonymous.

Audit and Enforce

  • Enforce, the default: the limits refuse and slow.
  • Audit: everything is counted and nothing is refused or slowed on the package addresses; the overview shows who Would have been limited. Meanwhile any caller, even an anonymous one of a public remote, sends as many requests as it likes. The rate limits of the management API, the sign-in and the token endpoints hold in both modes.

Switch to Audit… and Switch to Enforce… are the administrator's and ask for a recent sign-in. Switch to Enforce… first shows what the last 24 hours would have been in Enforce: callers limited, requests refused, downloads slowed, callers blocked.

The usage overview

Usage lists every caller of the period with its requests, bytes from the cache and the upstream, upstream requests, refusals and Now, the tightest limit's highest share over the last hour or day. Close to the limit starts at 70 %. Filter by kind, state, project and place, sort every column, and Export CSV. A caller's page shows its limits per place with the rule that applies, Explain for a repository, the last 24 hours, its usage per repository and credential, and Lift block.

A project's Owner sees the same for the project's repositories; Usage of this repository in a repository's settings narrows it. Single callers' usage is kept 30 days, then daily sums per repository and kind of caller.

Set limits

Tab What it holds
Rules The instance's rules in the order tried. Add rule: Applies to (a user, group, token, CI project, an address or range, or every caller of a kind), Profile, Change single figures. The built-in rules change but stay. Block time after too many refused requests, 1 to 1,440 minutes
Profiles Figures in MB and GB (1 GB is 1,000,000,000 bytes). A profile a rule or a maximum uses cannot be deleted
Projects A project's maximum lets its Owners go above the instance's values, up to it
Blocks The callers blocked now, with Lift

An Owner sets limits in the project's Settings › Download limits and in a repository's (with a remote's ceilings). A rule above the allowed value is refused with the most it may be; a lowered maximum lowers the rules above it. A technical token's limit is set on its service account's page (Managing tokens).

The limits bound how much a caller takes, never what it may read (Permissions). A user's own view: Your usage and download limits. Through the API: Management API.