Answer the question
In order to leave comments, you need to log in
Does TERMINABLE MIDDLEWARE make any practical sense?
Is there any benefit from using this feature? As far as I understand, this thing helps speed up page loading, they say the response is displayed in the browser, and the resource-intensive operation is performed after, but in fact I got the following: I return from the 'hello world' route, I add the following to the terminate method of a specially created middlewar:
$m = 9999999;
while($m--){
$arr[] = $m**10;
}
Answer the question
In order to leave comments, you need to log in
It is better to check through sleep. As far as I understand, headers and flash data are sent there, but perhaps your server uses buffering.
The feature is rather dubious, it doesn’t belong in the middleware, it’s better to use the queue.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question