Skip to content

Stalling in non-blocking mode? #30

@milgner

Description

@milgner

I'm currently investigating a problem where two concurrent jobs are stalling even though I specified block: 0. The basic logic is

begin
  RedisMutex.with_lock(self.class.to_s, block: 0) do
    # do work
  end
rescue RedisMutex::LockError
  # someone else is already working on it - going home now.
end

So far I have been unable to force a reproduction on my local machine. Do you have an idea what might be the cause? One difference that comes to mind is that the real machine uses a hosted Redis (cluster mode, 1 shard, 2 nodes) versus the local Redis on my dev machine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions