CGIAlt 0.0.2 is released
I have released CGIAlt 0.0.2.
CGIAlt is an alternative library of standard ‘cgi.rb’. It is faster than and compatible with ‘cgi.rb’ and CGI class.
In this release, CGIAlt supports FastCGI. You should require ‘cgialt/fcgi’ instead of ‘fcgi’ if you want to use CGIAlt with FastCGI.
The following is an example of benchmark.
Table 1. summary of benchmark
cgi.rb CGIAlt CGIAlt+CGIExt
---------------------------------------------------------------------------
require "cgi" (x1000) 13.16 7.89 ( 67%) 9.18 ( 43%)
CGI#new (simple) (x100000) 20.34 14.53 ( 40%) 12.46 ( 63%)
CGI#new (comple) (x100000) 26.62 20.10 ( 32%) 13.19 (102%)
CGI#header (simple) (x1000000) 12.68 6.05 (110%) 6.04 (110%)
CGI#header (complex) (x1000000) 43.52 36.26 ( 20%) 36.62 ( 19%)
Table 2. result of bench.fcgi
Time taken for tests Request per second
--------------------------------------------------------------------------
cgi + fcgi 16.686 [sec] 1198.61 [#/sec]
cgialt + cgialt/fcgi 15.562 [sec] 1285.18 [#/sec]
cgialt + cgialt/fcgi + cgiext 15.310 [sec] 1306.34 [#/sec]