Skip to content

Feature/foreground loop fixing Issue #66 #67

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

pragnesh
Copy link
Contributor

I have added 'loop' command in --daemon option which run daemon in foreground, this simple change enable us to run dynamic-dynamodb with supervisord.

for ex.

dynamic-dynamodb -c example.conf --instance example --daemon loop

sample supervisor conf

[program:example]
command=/usr/local/bin/dynamic-dynamodb -c /path/to/example.conf --instance example --daemon loop
autostart=true
autorestart=true
startsecs=10
redirect_stderr=true

@sebdah
Copy link
Owner

sebdah commented Oct 17, 2013

Thanks for the PR @pragnesh. I will have a closer look at it later today.

Just wonder about 3c78060, have you seen any issues with those imports? They were corrected due to pylint complains.

@pragnesh
Copy link
Contributor Author

sometime dynamic-dynamodb daemon crashed because dynamo table is just deleted which it has read just few second earliier and now it tried to update table throughput.

Also sometime due to some bug dynamic-dynamodb also crashed, i want it to restarted automatically in those case. But the way Deamon written it is not allowing to work with supervisord, so i made this change.

With regard to those imports, it is not working correctly on ubuntu precise 12.04 in original form, i am getting error that config module not found, after 3c78060 change that started working.

@sebdah
Copy link
Owner

sebdah commented Oct 17, 2013

I thought a bit around this and came to the conclusion that loop is part of the definition of the daemon already. So it made more sense to call the option foreground or fg for short. So you will call this mode using --daemon foreground or --daemon fg.

@sebdah sebdah closed this Oct 17, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants