You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On each creation of new Lua script, a new closure is allocated and the allocated object is linked to the garbage collection.
{code}
Closure *luaF_newLclosure (lua_State *L, int nelems, Table *e) {
Closure *c = cast(Closure *, luaM_malloc(L, sizeLclosure(nelems)));
luaC_link(L, obj2gco(c), LUA_TFUNCTION);
{code}
Creation of many scripts cause inflation of the memory used by the Lua infrastructure of Redis.
From reviewing the code seems like the LUA_TFUNCTION should be freed by the garbage collection, but, for some reason the closures are stored forever.
Is it by design, how can I free the bytecode cache without reset the Lua engine?
The text was updated successfully, but these errors were encountered:
On each creation of new Lua script, a new closure is allocated and the allocated object is linked to the garbage collection.
{code}
Closure *luaF_newLclosure (lua_State *L, int nelems, Table *e) {
Closure *c = cast(Closure *, luaM_malloc(L, sizeLclosure(nelems)));
luaC_link(L, obj2gco(c), LUA_TFUNCTION);
{code}
Creation of many scripts cause inflation of the memory used by the Lua infrastructure of Redis.
From reviewing the code seems like the LUA_TFUNCTION should be freed by the garbage collection, but, for some reason the closures are stored forever.
Is it by design, how can I free the bytecode cache without reset the Lua engine?
The text was updated successfully, but these errors were encountered: