mjc 96/03/29 00:56:49 Modified: src mod_status.c Log: Improved generated HTML and added scoreboard explanations Revision Changes Path 1.5 +13 -4 apache/src/mod_status.c Index: mod_status.c =================================================================== RCS file: /export/home/cvs/apache/src/mod_status.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C3 -r1.4 -r1.5 *** mod_status.c 1996/03/28 15:29:45 1.4 --- mod_status.c 1996/03/29 08:56:49 1.5 *************** *** 70,75 **** --- 70,76 ---- * 18.3.96 Make extra Scoreboard variables #definable * 25.3.96 Make short report have full precision [Ben Laurie suggested] * 25.3.96 Show uptime better [Mark/Ben Laurie] + * 29.3.96 Better HTML and explanation [Mark/Rob Hartill suggested] */ #include "httpd.h" *************** *** 177,183 **** up_time=nowtime-restart_time; if (!short_report) { ! rputs("

Server Status Page

\n\n",r); rvputs(r,"Hostname: ",server->server_hostname,"
",NULL); rvputs(r,"Current Time: ",asctime(localtime(&nowtime)),"
",NULL); rvputs(r,"Restart Time: ",asctime(localtime(&restart_time)),"
", --- 178,185 ---- up_time=nowtime-restart_time; if (!short_report) { ! rputs("Apache Status",r); ! rputs("

Apache Server Status

\n\n",r); rvputs(r,"Hostname: ",server->server_hostname,"
",NULL); rvputs(r,"Current Time: ",asctime(localtime(&nowtime)),"
",NULL); rvputs(r,"Restart Time: ",asctime(localtime(&restart_time)),"
", *************** *** 203,215 **** if(!short_report && i%25 == 24) rputs("\r\n",r); } ! if(!short_report) rputs("",r); ! if (short_report) sprintf(buffer,"\nBusyServers: %d\nIdleServers: %d\n",busy,ready); else ! sprintf(buffer,"\n
%d requests currently being processed,\n %d idle servers\n\n",busy,ready); rputs(buffer,r); #ifdef STATUS_INSTRUMENTATION --- 205,222 ---- if(!short_report && i%25 == 24) rputs("\r\n",r); } ! if(!short_report) { rputs("",r); ! rputs("Server States:",r); ! } if (short_report) sprintf(buffer,"\nBusyServers: %d\nIdleServers: %d\n",busy,ready); else ! sprintf(buffer,"\n%d requests currently being processed,\n %d idle servers\n\n",busy,ready); rputs(buffer,r); #ifdef STATUS_INSTRUMENTATION *************** *** 309,314 **** --- 316,323 ---- } } #endif + if (!short_report) + rputs("",r); return 0; }