Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • pleroma pleroma
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 647
    • Issues 647
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 88
    • Merge requests 88
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • PleromaPleroma
  • pleromapleroma
  • Issues
  • #1790
Closed
Open
Issue created May 19, 2020 by rinpatch@rinpatchContributor0 of 2 checklist items completed0/2 checklist items

Oban overuse

It is my opinion that right now Oban is overused in Pleroma. Oban is not an in-memory queue, every job creation is a query to the database, therefore it should be used only when it's actually needed.

Things that do not need Oban but use it:

  • Prefetching preview cards, media proxy prefetch and preload. These tasks just warm the cache, we don't care if they fail or of they get preserved when the node goes down
  • Pleroma.Workers.Cron.ClearOauthTokenWorker, Pleroma.Workers.Cron.StatsWorker, Pleroma.Workers.Cron.PurgeExpiredActivitiesWorker (a.k.a everything that uses Oban cron except digest emails). Same argument as the last one. Do we care if StatsWorker runs exactly at the start of each hour and that it's scheduled jobs get preserved between restarts? No, it regenerates stats on reboot anyway, send_after(self(), :refresh, 3600000) will do
Assignee
Assign to
Time tracking