Ash FrameworkAF
Ash Framework3mo ago
10 replies
pikdum

AshOban scheduled action crashing Oban.Plugins.Cron

We have something like this:

  oban do
    domain Foobar.Translations

    scheduled_actions do
      schedule :create_nightly_global_batch_request, "0 0 * * *" do
        worker_module_name Foobar.Translations.BatchTranslationsRequest.AshOban.ActionWorker.CreateNightlyGlobalBatchRequest
      end
    end

    triggers do
      trigger :create_batch_translations_jobs do
        action :create_batch_translations_jobs
        scheduler_cron "* * * * *"
        where expr(status == :pending)

        worker_module_name Foobar.Translations.BatchTranslationsRequest.AshOban.Worker.CreateBatchTranslationsJobs

        scheduler_module_name Foobar.Translations.BatchTranslationsRequest.AshOban.Scheduler.CreateBatchTranslationsJobs
      end
    end
  end


It looks like that :create_nightly_global_batch_request is crashing Oban.Plugins.Cron at midnight, though. (Log too large, will add as a comment)

It seems to have started after we upgraded from ash_oban 0.4.12 to 0.5.1 and Elixir from 1.18.4 OTP 27 to 1.19.2 OTP 28 (among other things).

Any ideas? Thanks!
Was this page helpful?