comment out line #38 (loader => 'Delayed') in thrall.bat
You hit the nail on the head, bravo! So to make this crystal clear, the loader type is responsible for the difference in initialisation, not the server type itself, and with thrall, the delayed loading is on purpose.
Will this change to .bat break anything?
Yes, very much. It appears there is a lot of thread-unsafe code in my application. Let me show y'all a bizarre example:
use JSON qw(encode_json);
my $app = sub { return [200, [], [encode_json [] ]] };
With plackup, the response is
[]. With thrall but no Delayed loader, the response is
Internal Server Error, the exception
hash- or arrayref expected (not a simple scalar, use allow_nonref to allow this) at ….