Closed crawford closed 10 months ago
Your theory sounds correct. You can see here that it spawns a next task but doesn't store the handle and therefore doesn't join on exit. And I suppose the tokio runtime does not wait for the tasks to complete on exit.
When the process within an enclave sends a large amount of data over an open socket and then exits, not all of the data will be sent before the enclave exits. From the client's point of view, the response to their request is prematurely terminated. I'm guessing this is because odyn isn't flushing its buffers before exiting, but I haven't had a chance to investigate.