Added config for worker_memory_limit so that the worker process will terminate if the memory limit of the process is exceeded.