Hey there, So what I want is that a function/line of code should execute AFTER a controller function has thrown out all the output.
What I have is a download function; I'm trying to keep track of open/ closed connections. Users would be downloading big files; like 200-400MB. So, I want to know how many connections have been opened by the user and how many of them have been closed. What the script does is, it fetches a file from the remote server; and streams it back to the client. I'm using a custom streaming function which calls the response.stream function in the end after sending out the necessary headers/fetching the file from the remote server. Possible or do I need to implement the response.stream function on my own?

