{"action":"opened","issue":{"url":"https://api.github.com/repos/hjr265/redsync.go/issues/8","labels_url":"https://api.github.com/repos/hjr265/redsync.go/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/hjr265/redsync.go/issues/8/comments","events_url":"https://api.github.com/repos/hjr265/redsync.go/issues/8/events","html_url":"https://github.com/hjr265/redsync.go/issues/8","id":113744366,"number":8,"title":"Redsync for a shared resource across a distributed system","user":{"login":"csesmita","id":10883344,"avatar_url":"https://avatars.githubusercontent.com/u/10883344?v=3","gravatar_id":"","url":"https://api.github.com/users/csesmita","html_url":"https://github.com/csesmita","followers_url":"https://api.github.com/users/csesmita/followers","following_url":"https://api.github.com/users/csesmita/following{/other_user}","gists_url":"https://api.github.com/users/csesmita/gists{/gist_id}","starred_url":"https://api.github.com/users/csesmita/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/csesmita/subscriptions","organizations_url":"https://api.github.com/users/csesmita/orgs","repos_url":"https://api.github.com/users/csesmita/repos","events_url":"https://api.github.com/users/csesmita/events{/privacy}","received_events_url":"https://api.github.com/users/csesmita/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-28T04:57:20Z","updated_at":"2015-10-28T04:57:20Z","closed_at":null,"body":"Dear Authors,\r\n\r\nThanks for your effort in implementing the redsync algorithm in go. I am trying to use your implementation in a distributed system where multiple nodes might request for the same named resource. In that case, though the mutexes created for the same named resource are different, the lock should still succeed for one and only one node. \r\n\r\nThe delScript inside Lock() prevents this from happening. I am trying to understand why you would need that in the first place?\r\n\r\n(\r\nI'd like to simulate the following behaviour at the redis-server:\r\n\r\n127.0.0.1:6379> get uuid1\r\n(nil)\r\n127.0.0.1:6379> set uuid1 2345 NX PX 200000\r\nOK\r\n127.0.0.1:6379> get uuid1\r\n\"2345\"\r\n127.0.0.1:6379> set uuid1 1234 NX PX 200000\r\n(nil)\r\n127.0.0.1:6379> get uuid1\r\n\"2345\"\r\n\r\nA get fetching a non-nil value should suffice, the value needn't be equal\r\n)\r\n\r\nThanks,\r\nSmita"}}