Giter Club home page Giter Club logo

Comments (3)

snmgian avatar snmgian commented on May 25, 2024

Hello,

Which versions of sidekiq and sidekiq-scheduler are you using?

I just setup a sample project and couldn't see the problem you are facing in.

In the UI's navigation bar there are two entries: Scheduled and Recurring Jobs. The code you are referring to affects the information displayed at Recurring Jobs.

As far as I can tell from skimming through the code base, the removed schedules are the ones who are not present in schedule_hash, so if a schedule is added, it will not be removed in the next step.

from sidekiq-scheduler.

vikram-chaitanya avatar vikram-chaitanya commented on May 25, 2024

Hi,

I looked through the code and my configuration and found the issue. The issue was in schedule config in sidekiq.yml. When there was an extra colon before the first entry schedule key(maintenance) it was coming in as symbol from prepare_schedule method and get_all_schedules method was giving keys with string so the array subtraction failed and the key was removed immediately after it was added.

sidekiq.yml (before fix)

:schedule:
:maintenance:
cron: '0 */1 * * *'
class: InactiveScheduler
queue: inactive_queue
description: "Queues job to handle inactive objects"

sidekiq.yml (after fix) ->
:schedule:
maintenance:
cron: '0 */1 * * *'
class: InactiveScheduler
queue: inactive_queue
description: "Queues job to handle inactive objects"

After removing the extra colon before the "maintenance" key it worked fine.

from sidekiq-scheduler.

snmgian avatar snmgian commented on May 25, 2024

Good to hear that you solve it by changing your configuration, but definitively it's a misbehaviuor.

I just found the reason of the failure and opened issue #102 to handle this case, thanks!

from sidekiq-scheduler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.