Megatest

Check-in [2efebe79cc]
Login
Overview
Comment:Added a little code to move server logs aside in the case where the server decided to not start
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | v1.64
Files: files | file ages | folders
SHA1: 2efebe79cceb686f8d68c8435a804b37a26c09ae
User & Date: mrwellan on 2017-07-21 11:11:36
Other Links: branch diff | manifest | tags
Context
2017-07-21
16:25
Fixed missing condition where exit on no start needed for server was happening. check-in: 18835703e2 user: mrwellan tags: v1.64
11:11
Added a little code to move server logs aside in the case where the server decided to not start check-in: 2efebe79cc user: mrwellan tags: v1.64
2017-07-20
10:02
Added bash script to make simple report from megatest call gathering. This is handy if you are trying to find what is loading down a server for example. check-in: 69e4b88930 user: mrwellan tags: v1.64
Changes

Modified http-transport.scm from [eebbc561d6] to [7c24faae09].

511
512
513
514
515
516
517
518


519


520
521
522
523
524
525
526
	     (not server-starting))
	(begin
	  (debug:print-info 0 *default-log-port* "NOT starting server, there is either a recently started server or a server in process of starting")
	  (exit))))
  ;; lets not even bother to start if there are already three or more server files ready to go
  (let* ((num-alive   (server:get-num-alive (server:get-list *toppath*))))
    (if (> num-alive 3)
	(begin


	  (debug:print 0 *default-log-port* "ERROR: Aborting server start because there are already " num-alive " possible servers either running or starting up")


	  (exit))))
  (let* ((th2 (make-thread (lambda ()
			     (debug:print-info 0 *default-log-port* "Server run thread started")
			     (http-transport:run 
			      (if (args:get-arg "-server")
				  (args:get-arg "-server")
				  "-")







|
>
>

>
>







511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
	     (not server-starting))
	(begin
	  (debug:print-info 0 *default-log-port* "NOT starting server, there is either a recently started server or a server in process of starting")
	  (exit))))
  ;; lets not even bother to start if there are already three or more server files ready to go
  (let* ((num-alive   (server:get-num-alive (server:get-list *toppath*))))
    (if (> num-alive 3)
	(let* ((serv-fname      (conc "server-" (current-process-id) "-" (get-host-name) ".log"))
               (full-serv-fname (conc *toppath* "/logs/" serv-fname))
               (new-serv-fname  (conc *toppath* "/logs/" "defunct-" serv-fname)))
	  (debug:print 0 *default-log-port* "ERROR: Aborting server start because there are already " num-alive " possible servers either running or starting up")
          (if (common:file-exists? serv-fname)
              (system (conc "sleep 1;mv -f " full-serv-fname " " new-serv-fname)))
	  (exit))))
  (let* ((th2 (make-thread (lambda ()
			     (debug:print-info 0 *default-log-port* "Server run thread started")
			     (http-transport:run 
			      (if (args:get-arg "-server")
				  (args:get-arg "-server")
				  "-")