rstudio/redx — pull request #11 by CBarraford (2014-11-18 19:27:00+00:00)
Title: Use content_by_lua and access_by_lua instead of by_file

Noticed a bug where if you use `content_by_lua_file` instead of `content_by_lua`, the lua vm leaks memory until it crashes.

In dev, i could run a bash for loop hitting `/batch` api endpoint and see memory utilization would go up until the VM crashes (about 1GB). Even if i ran garbage collection manually, it would help but never get back to less than hundreds of MBs.

Using the new way, i was unable to get memory utilization of the VM to go above 1 or 2 MBs.