Since the interpreter continues after a request, you need to free the documents. The thread cleanup does not take care of them.