IIS 和 FastCGI/指令碼語言/Perl/Catalyst
外觀
這是 Catalyst 和 FastCGI 的快速概述。 假設您已經註冊瞭解釋器。
在 Catalyst 5.7014 和 5.7015 上測試。
確保您擁有以下內容
[Catalyst]
ExePath=C:\strawberry\perl\bin\perl.exe
; The -e is important, this flag tells MyApp_fastcgi.pl to change the way it treats stderr
Arguments="D:\Inetpub\www\DMApp\script\MyApp_fastcgi.pl -e"
; these three lines tell it to always let Cat handle requests.
IgnoreDirectories=1
IgnoreFiles=1
IgnoreExistingFiles=1
; these three lines you can muck with for performance/resource optimizations
QueueLength=999
MaxInstances=20
InstanceMaxRequests=500
由於 MyApp_fastcgi.pl 在上述中接受引數 (-e),因此現在不再需要此步驟
在編寫本文時,某些早期版本(仍然存在錯誤)需要對 stderr 進行修改才能在 Windows 上執行。 您需要對 MyApp_fastcgi.pl 進行更改。
更改顯示 keep_stderr 的行
DMApp->run(
$listen,
{ nproc => $nproc,
pidfile => $pidfile,
manager => $manager,
detach => $detach,
keep_stderr => $keep_stderr,
}
);
更改為1:
DMApp->run(
$listen,
{ nproc => $nproc,
pidfile => $pidfile,
manager => $manager,
detach => $detach,
keep_stderr => 1,
}
);