views:

52

answers:

1

I'm using pylons, and using this command to start the server:

paster serve --reload development.ini

I found when I modify something, the paster will reload the application. In the console, it shows:

-------------------- Restarting --------------------
Starting server in PID 7476.
serving on http://127.0.0.1:5000

This is convenient but not enough, because it will cost 5 seconds more or less each time. If I refresh that page and the server is not reloaded completely yet, the page will display the old content, and I don't know if it is the lastest content, so I had to refresh the page several times to make sure.

I wonder if there is a better way to read the modified content without reloading, or find a quicker reloading?

+1  A: 

To controllers, you can configure Routes to rescan the directory controllers without restart application:

http://pylonshq.com/docs/en/1.0/controllers/#adding-controllers-dynamically

renatopp
It seems only support **adding new controllers**, but not **modifing**. I tried and start `paster` without `--reload` option, but modified controller can't be reload. Do you successfully reload the modified controller without restarting?
Freewind