[core] write all cq MEM_CHUNK if spill to tempfile
If chunkqueue size grows large enough in memory to use tempfiles, write all MEM_CHUNK in chunkqueue to tempfiles to free up memory. If earlier chunks in chunkqueue are MEM_CHUNK, then a prior attempt to write was not able to proceed, or items are being added to chunkqueue as they are decoded from TLS. In either case, choose to free up memory sooner. This may result in some cases where lighttpd soon reads data back from disk to send to the backend, but since some (now all) of the data is in tempfiles, sendfile() will avoid reading back into userspace, though sendfile() will not be used if lighttpd needs to read data back into memory to encrypt data using TLS.master
parent
6800b0821c
commit
715699ba50
Loading…
Reference in New Issue