When will "stat" be implemented? #184

Open
Thomas12 opened this Issue Dec 4, 2012 · 2 comments

3 participants

@Thomas12

Hi,

when will the "stat"-feature be implemented to recompile changed Lua-scripts on the fly?
"stat" would make openresty way more convenient.

As "stat" is said to be "expensive" you could include a timestamp into your luajit-cache to not stat a file more often than e.g. every second.

Kind regards,

Thomas

@chase

@Thomas12, rather than waiting, why don't you just turn off lua_code_cache and use the *_by_lua_file directives to recompile Lua-scripts?
Obviously, you shouldn't keep lua_code_cache off during production.

Another solution would be to make a script that stays running in the background, watches for changes to the configuration file, then sends a HUP signal to the Nginx process whenever a change is detected.

Respectfully,
Chase

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