Scripting SHUTDOWN NOSAVE not working as expected #466

Closed
sebleier opened this Issue Apr 19, 2012 · 3 comments

Comments

Projects
None yet
2 participants
@sebleier

Testing on sha: d54943b

I was implementing the scripting commands on redis-py and trying to kill long running lua scripts in a half written state using SHUTDOWN NOSAVE

I was using the following lua script:

redis.call('set', 'foo', 'bar')
while true do

end
return

After this script starts running and using redis-cli to send SHUTDOWN NOSAVE, I get the following::

redis 127.0.0.1:6379> SCRIPT KILL
(error) ERR Sorry the script already executed write commands against the dataset. You can either wait the script termination     or kill the server in an hard way using the SHUTDOWN NOSAVE command.
redis 127.0.0.1:6379> SHUTDOWN NOSAVE
(error) BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE.
@antirez

This comment has been minimized.

Show comment Hide comment
@antirez

antirez Apr 19, 2012

Owner

Thanks, fixed, I'm adding tests now.

Owner

antirez commented Apr 19, 2012

Thanks, fixed, I'm adding tests now.

@sebleier

This comment has been minimized.

Show comment Hide comment
@sebleier

sebleier Apr 19, 2012

Great, thanks @antirez!

Great, thanks @antirez!

@sebleier sebleier closed this Apr 19, 2012

@antirez

This comment has been minimized.

Show comment Hide comment
@antirez

antirez Apr 19, 2012

Owner

You are welcome! Regression test added, I also added tests for SCRIPT KILL.

Owner

antirez commented Apr 19, 2012

You are welcome! Regression test added, I also added tests for SCRIPT KILL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment