Index: common.scm ================================================================== --- common.scm +++ common.scm @@ -2142,11 +2142,11 @@ (effective-host (or remote-host "localhost")) (normalized-effective-load (/ effective-load numcpus)) (will-wait (> normalized-effective-load maxnormload))) (if (> recommended-delay 0) (let* ((actual-delay (min recommended-delay 30))) - (debug:print-info 0 *default-log-port* "Load is high, delaying " actual-delay " seconds.") + (debug:print-info 0 *default-log-port* "Load control, delaying " actual-delay " seconds to maintain safe load.") (thread-sleep! actual-delay))) (cond ;; bad data, try again to get the data ((not will-wait) Index: megatest-version.scm ================================================================== --- megatest-version.scm +++ megatest-version.scm @@ -18,6 +18,6 @@ ;; Always use two or four digit decimal ;; 1.01, 1.02...1.10,1.11,1.1101 ... 1.99,2.00.. ;; (declare (unit megatest-version)) -(define megatest-version 1.6564) +(define megatest-version 1.6565) Index: server.scm ================================================================== --- server.scm +++ server.scm @@ -323,13 +323,17 @@ ;; wait for server=start-last to be three seconds old ;; (define (server:wait-for-server-start-last-flag areapath) (let* ((start-flag (conc areapath "/logs/server-start-last"))) (if (file-exists? start-flag) - (let* ((fmodtime (file-modification-time start-flag))) - (if (> (- (current-seconds) fmodtime) 3) ;; good enough - (system (conc "touch " start-flag)) ;; lazy but safe + (let* ((fmodtime (file-modification-time start-flag)) + (reftime (+ 3 (random 5))) + (delta (- (current-seconds) fmodtime))) + (if (> delta reftime) ;; good enough + (begin + (debug:print-info 0 *default-log-port* "Ready to start server, last start: " fmodtime ", delta: " delta) + (system (conc "touch " start-flag))) ;; lazy but safe (begin (thread-sleep! 5) (server:wait-for-server-start-last-flag areapath)))) (system (conc "touch " start-flag)))))