Skip to content

[Bug] Admin Dashboard library times out after importing versions #444

Closed

Description

@NilsMoller

I'm using v0.4.0-rc4

I'm hitting a timeout when going to the library page in the admin dashboard. The client's library page works fine (both web and app).
This timeout only occurs after adding versions. Adding games works and the admin library is fine after that. Once a version is added, the admin library times out.

Using top, it seems like clicking on the Library button in the admin dashboard causes postgres processes to use 100%, spawning more over time. Eventually, the request times out and the server recovers. Until then, the store pages also don't work (presumably because the db is saturated), game downloads become very slow on clients, etc.

Docker logs:

drop  | [Drop] performing migrations...
drop  | [dotenv@17.2.3] injecting env (0) from .env -- tip: :closed_lock_with_key: encrypt with Dotenvx: https://dotenvx.com
drop  | Loaded Prisma config from prisma.config.ts.
drop  | 
drop  | Prisma schema loaded from prisma.
drop  | Datasource "db": PostgreSQL database "drop", schema "public" at "drop-postgres:5432"
drop  | 
drop  | 118 migrations found in prisma/migrations
drop  | 
drop  | 
drop  | No pending migrations to apply.
drop  | Listening on http://[::]:4000
drop  | [16:10:01.752] INFO (84): enabled metadata provider: Steam
drop  | [16:10:01.752] INFO (84): enabled metadata provider: PCGamingWiki
drop  | [16:10:01.938] INFO (84): enabled metadata provider: IGDB
drop  | [16:10:01.945] INFO (service-torrential/84): service launched
drop  | [16:10:01.982] INFO (service-nginx/84): service launched
drop  | [16:10:02.002] WARN (84): failed to enable auth OpenID: Error: Missing all necessary OIDC configuration: 
drop  |   OIDC_AUTHORIZATION: undefined
drop  |   OIDC_TOKEN: undefined
drop  |   OIDC_USERINFO: undefined
drop  |   OIDC_SCOPES: undefined
drop  |   OIDC_ISSUER: undefined
drop  |   OIDC_JWKS: undefined
drop  | [16:10:02.004] INFO (84): enabled auth: Simple
drop  | [16:10:02.004] INFO (84): AuthManager initialized
drop  | [16:10:02.401] INFO (service-torrential/84): INFO  [torrential] using 8 threads
drop  | [16:10:02.401] INFO (service-torrential/84): INFO  [torrential::server] created client subroutine
drop  | [16:10:02.402] ERROR (service-nginx/84): nginx: [alert] could not open error log file: open() "/data/nginx/logs/error.log" failed (2: No such file or directory)
drop  | [16:10:02.403] INFO (service-torrential/84): connected to torrential socket
drop  | [16:10:02.403] INFO (service-torrential/84): service healthy
drop  | [16:10:02.417] INFO (service-torrential/84): INFO  [torrential] started depot server
drop  | [16:10:02.516] INFO (84): initialised the ca
drop  | [16:16:14.252] ERROR (service-nginx/84): 2026/07/15 16:16:14 [error] 103#103: *1 upstream timed out (110: Operation timed out) while reading response header from upstream, client: 192.168.1.76, server: localhost, request: "GET /api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters HTTP/1.1", upstream: "http://[::1]:4000/api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters", host: "192.168.1.72:30032"
drop  | [16:17:14.312] ERROR (service-nginx/84): 2026/07/15 16:17:14 [error] 103#103: *1 upstream timed out (110: Operation timed out) while reading response header from upstream, client: 192.168.1.76, server: localhost, request: "GET /api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters HTTP/1.1", upstream: "http://127.0.0.1:4000/api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters", host: "192.168.1.72:30032"
drop  | [16:18:14.380] ERROR (service-nginx/84): 2026/07/15 16:18:14 [error] 103#103: *1 upstream timed out (110: Operation timed out) while reading response header from upstream, client: 192.168.1.76, server: localhost, request: "GET /api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters HTTP/1.1", upstream: "http://[::1]:4000/api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters", host: "192.168.1.72:30032"
drop  | [16:19:14.442] ERROR (service-nginx/84): 2026/07/15 16:19:14 [error] 103#103: *1 upstream timed out (110: Operation timed out) while reading response header from upstream, client: 192.168.1.76, server: localhost, request: "GET /api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters HTTP/1.1", upstream: "http://127.0.0.1:4000/api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters", host: "192.168.1.72:30032"
drop  | [16:19:14.568] ERROR (service-nginx/84): 2026/07/15 16:19:14 [error] 103#103: *18 no live upstreams while connecting to upstream, client: 192.168.1.76, server: localhost, request: "GET /api/v1/task HTTP/1.1", upstream: "http://localhost/api/v1/task", host: "192.168.1.72:30032"

Depending on how I navigated there, I can either get an nginx error page or a blank Drop page:

Image Image

Even without navigating to the admin library first, some games on the store page also don't load. Log line:

drop  | [21:33:17.447] ERROR (service-nginx/85): 2026/07/15 21:33:17 [error] 104#104: *871 upstream timed out (110: Operation timed out) while reading response header from upstream, client: 172.16.1.7, server: localhost, request: "GET /api/v1/games/b0131da0-8eb2-4ac7-b99e-c64a5534877d HTTP/1.1", upstream: "http://[::1]:4000/api/v1/games/b0131da0-8eb2-4ac7-b99e-c64a5534877d", host: "drop.nilsmoller.lan"

Docker compose:

services:
  postgres:
    image: postgres:14-alpine
    container_name: drop-postgres
    restart: unless-stopped
    stop_grace_period: 1m
    healthcheck:
      test: pg_isready -d drop -U drop
      interval: 30s
      timeout: 60s
      retries: 5
      start_period: 10s
    volumes:
      - /mnt/data/apps/drop/data/postgres:/var/lib/postgresql/data
    environment:
      - POSTGRES_PASSWORD=drop
      - POSTGRES_USER=drop
      - POSTGRES_DB=drop
    networks:
      - drop_network

  drop:
    image: ghcr.io/drop-oss/drop:0.4.0-rc-4
    container_name: drop
    restart: unless-stopped
    stop_grace_period: 1m
    depends_on:
      postgres:
        condition: service_healthy
    ports:
      - 30032:3000
    volumes:
      - /mnt/data/apps/drop/data/library:/library:ro
      - /mnt/data/apps/drop/data/data:/data
    environment:
      - DATABASE_URL=postgres://drop:drop@drop-postgres:5432/drop
      - EXTERNAL_URL=http://drop.nilsmoller.lan
      - IGDB_CLIENT_ID=${IGDB_CLIENT_ID}
      - IGDB_CLIENT_SECRET=${IGDB_CLIENT_SECRET}
    labels:
      - traefik.enable=true
      - traefik.http.routers.drop.entrypoints=web
      - traefik.http.routers.drop.rule=Host(`drop.nilsmoller.lan`)
      - traefik.http.services.drop.loadbalancer.server.port=3000
    # DNS to quad9 directly instead of through adguardhome because adguardhome breaks metadata search
    dns:
      - 9.9.9.10
      - 149.112.112.10
      - 2620:fe::10
      - 2620:fe::fe:10
    networks:
      - drop_network
      - traefik_network

networks:
  drop_network:
  traefik_network:
    external: true

For some housekeeping:

  • Traefik isn't the problem. Going to the IP + port directly shows the same problem.
  • It is running on a TrueNAS scale system in RAIDZ2 with many other Docker containers running similar setups and they work fine.
  • Running version 0.4.0-rc4

If there is anything else I can do, let me know.

Activity

  1. NilsMoller commented on Jul 21, 2026

    @NilsMoller
    Author

    I have found a janky workaround to get to the games. Being logged in on the admin account, go to the store page, go to the game, and use "open in admin dashboard". From there, importing versions works. This doesn't help with new games though.

  2. NilsMoller commented on Jul 22, 2026

    @NilsMoller
    Author

    I had to move a game from one folder to another, meaning I need to remove the old game from Drop. The workaround I mentioned above doesn't allow that (I guess you can only delete games from the admin library?), so I started messing around with the API.

    The API request for the admin library (http://drop.nilsmoller.lan/api/v1//admin/library) also fails. It fails after exactly 2 minutes every time.

    I also see there is no endpoint for deleting a game, so I'm guessing this uses the object deletion stuff which I can't quite understand. Calling DELETE http://drop.nilsmoller.lan/api/v1/object/:id with the ID from the game page doesn't work (so http://drop.nilsmoller.lan/admin/library/b0131da0-8eb2-4ac7-b99e-c64a5534877d loads, I copy the ID from the URL to delete the game using object deletion but it fails).

    There also doesn't seem to be a way to get one game from the admin library, only the whole thing.

    EDIT: Digging into the code, there are route handlers for these things (makes sense). It just isn't in the developer docs. I haven't found something like an OpenAPI spec, but using the API directly does seem to be a valid workaround.

  3. NilsMoller commented on Jul 24, 2026

    @NilsMoller
    Author

    This still happens on rc5, except it doesn't max out the CPU.

  4. DecDuck commented on Jul 24, 2026

    @DecDuck
    Member

    Can you go into the browser's devtools and pull the error from the request, or see if it's just slow?

    I'm guessing the import daemon is hogging all the CPU, so there is a way to tune it.

  5. DecDuck commented on Jul 24, 2026

    @DecDuck
    Member

    You can lower it by setting READER_THREADS

  6. NilsMoller commented on Jul 24, 2026

    @NilsMoller
    Author

    This is the response for url http://drop.nilsmoller.lan/api/v1/admin/library?skip=0&limit=24&sort=default&order=desc&filters=:

    <html>
    <head><title>504 Gateway Time-out</title></head>
    <body>
    <center><h1>504 Gateway Time-out</h1></center>
    <hr><center>nginx</center>
    </body>
    </html>
    
  7. NilsMoller commented on Jul 24, 2026

    @NilsMoller
    Author

    Setting READER_THREADS=1 in the env results in the same thing.

  8. DecDuck commented on Jul 24, 2026

    @DecDuck
    Member

    Accessing the library does quite a bit of disk ops to get update to date information, does this happen over some sort of slow boundary, like a network share or something?

  9. NilsMoller commented on Jul 24, 2026

    @NilsMoller
    Author

    It is local disk access in RAIDZ2 on TrueNAS SCALE. I also run a modded minecraft server, jellyfin, and more which can also do heavy IO but they run fine.

  10. DecDuck commented on Oct 18, 2026

    @DecDuck
    Member

    Looks like there was some weirdness around Prisma, I think I fixed it.

  11. linked a pull request that will close this issueBatch fixes #509on Oct 18, 2026
  12. NilsMoller commented on Oct 19, 2026

    @NilsMoller
    Author

    It's near instant now. This is amazing! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions