DroppedNeedle looks up artists, albums and tracks on MusicBrainz. One source answers those lookups at a time. A new install starts on BrainzMash and needs no setup. An upgrade from v2 keeps the source v2 used. DroppedNeedle never moves to another source by itself: when the chosen one fails, you see its errors.
| Source | What it is | Pace |
|---|---|---|
| BrainzMash (Recommended) | A read-only public pool of MusicBrainz copies, no account needed | Fixed at 10 requests a second |
| Official | The public musicbrainz.org service | Fixed at 1 request a second |
| Self-hosted mirror | Your own full copy of the MusicBrainz database | Up to 500 a second, or Unlimited |
| Community / external server | Somebody else’s server answering MusicBrainz queries | Up to 500 a second, or Unlimited |
Before you start#
- For a self-hosted mirror, have it running and loaded. MusicBrainz sources and mirrors covers setting one up.
- For a community server, find out who runs it: its operator sees your queries and controls how fresh its data is.
Warning
Keep a mirror off the internet. Its /ws/2 reads need no sign-in, so anyone who can reach the port can query it. See Keep it off the internet.
Steps#
Open the MusicBrainz settings#
Go to Settings › MusicBrainz.
Pick a source#
Under MusicBrainz data source, choose a card. Choosing changes nothing until you save. More info: followed by the card’s name opens notes on that source.
Result: while your choice differs from the source in use, a note reads “Active source:” with its name, and “It stays active until the pending source is saved or activated.”
Enter the server’s address#
For a mirror, fill in Mirror API Endpoint URL, such as
http://mirror-host:5000/ws/2. For a community server, fill in Community Server API Endpoint URL. Give the full address of its MusicBrainz API,/ws/2included. Official has a fixed address and nothing to fill in.Set the rate limit#
Rate Limit (requests/sec) takes up to 500 for a mirror or community server, and 0 means Unlimited. Moving from BrainzMash or Official sets it back to 1, so raise it for a mirror you run. Be polite with servers you do not own. Official stays at 1.
Accept the risk notice, for a community server#
Tick “I understand the risks of routing identity data through a server I do not control.” Saving stays off until you do.
Test the connection#
Press Test Connection.
Result:
MusicBrainz connection verified.While BrainzMash is the source in use, the test is off for the other sources: “Test Connection is unavailable while BrainzMash is active because no non-Brainz provider traffic may run before this source switch.” Go on to save.Save#
Press Save Settings.
Result: the status reads
MusicBrainz settings saved.and lookups go to the new source from then on. For a mirror or community server, an info box notes that search results depend on that server’s reindex schedule, and how fresh its data is on its operator’s replication.
Go back to BrainzMash
Choose the BrainzMash card. The BrainzMash setup panel shows the built-in endpoint, https://api.brainzmash.cc/ws/2. Press Stage BrainzMash.
Result: “BrainzMash is active. No provider request was made.” Lookups use BrainzMash straight away. Reset to Defaults does the same.
The panel then offers three optional steps that record that you read BrainzMash’s privacy notice and checked that it answers: tick “I understand the risks of routing MusicBrainz query data through BrainzMash.”, press Test Connection, then Activate BrainzMash. BrainzMash keeps serving lookups while you do. These steps are held in memory, so a restart drops them and you stage again.
Give MusicBrainz a contact address
Outbound requests carry a contact address in their User-Agent, [email protected] by default. MusicBrainz asks for one, so if you run many lookups, set your own with CONTACT_EMAIL in the compose file’s environment.
Check it worked#
- Settings › MusicBrainz no longer shows the “Active source:” note, and your card is the selected one.
- Search for an artist: results come back without a banner saying MusicBrainz or the mirror is unavailable.
- The top bar has no Service status icon naming MusicBrainz, BrainzMash or the MusicBrainz mirror. See Check health and read the logs.
- For a mirror, Checking how fresh your data is shows how far behind musicbrainz.org it is.
If something went wrong#
Each heading below is the message DroppedNeedle shows.
Test the connection before saving.
Between Official, a mirror and a community server, Save Settings stays off until Test Connection passes for the address you entered. Check the address ends in /ws/2 and that the container can reach it.
Acknowledge the risk notice to enable saving.
A community server can only be saved once you tick the risk notice (step 5).
Connected, but the server returned 503 (busy).
On a mirror this usually means the search index is still building or the service is starting up. It is not a rate-limit problem, so there is nothing to lower. Wait and test again.
Values were clamped to the conservative Official 1 request/second, capacity-1 local policy.
The address points at musicbrainz.org, which DroppedNeedle always holds to 1 request a second, so a higher saved rate was brought down to 1.
Lookups fail after switching away from BrainzMash
The new source couldn’t be tested before the switch, so its errors show from the first lookup on. Fix the address or the server, then test and save again, or go back to BrainzMash (above). DroppedNeedle won’t fall back to another source on its own.