Megatest

Check-in [cb18456dcf]
Login
Overview
Comment:More task:get-db conversion stuff
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | v1.60
Files: files | file ages | folders
SHA1: cb18456dcfa390678b635c8f6809fd2c31d05240
User & Date: matt on 2014-10-07 00:04:28
Other Links: branch diff | manifest | tags
Context
2014-10-07
09:30
Fixed typo check-in: a162c72be6 user: mrwellan tags: v1.60
00:04
More task:get-db conversion stuff check-in: cb18456dcf user: matt tags: v1.60
2014-10-06
23:31
First pass of removing open-run-close for tasks/monitor.db calls check-in: 045b0cea46 user: matt tags: v1.60
Changes

Modified http-transport.scm from [c90a1ae0c7] to [7ee6223861].

490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
	    (begin
	      (thread-sleep! 2)
	      (loop (tasks:server-lock-slot (tasks:get-db) run-id)
		    (- remtries 1)))
	    (begin
	      ;; since we didn't get the server lock we are going to clean up and bail out
	      (debug:print-info 2 "INFO: server pid=" (current-process-id) ", hostname=" (get-host-name) " not starting due to other candidates ahead in start queue")
	      (tasks:server-delete-records-for-this-pid tasks:get-db " http-transport:launch")
	      ))
	(let* ((th2 (make-thread (lambda ()
				   (debug:print-info 0 "Server run thread started")
				   (http-transport:run 
				    (if (args:get-arg "-server")
					(args:get-arg "-server")
					"-")







|







490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
	    (begin
	      (thread-sleep! 2)
	      (loop (tasks:server-lock-slot (tasks:get-db) run-id)
		    (- remtries 1)))
	    (begin
	      ;; since we didn't get the server lock we are going to clean up and bail out
	      (debug:print-info 2 "INFO: server pid=" (current-process-id) ", hostname=" (get-host-name) " not starting due to other candidates ahead in start queue")
	      (tasks:server-delete-records-for-this-pid (tasks:get-db) " http-transport:launch")
	      ))
	(let* ((th2 (make-thread (lambda ()
				   (debug:print-info 0 "Server run thread started")
				   (http-transport:run 
				    (if (args:get-arg "-server")
					(args:get-arg "-server")
					"-")

Modified tasks.scm from [29d82aadd7] to [e478443442].

116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
                                CONSTRAINT clients_constraint UNIQUE (pid,hostname));")
                                  
	  ))
    mdb))

(define (tasks:get-db)
  (if *task-db*
      *task-db*
      (let ((db  (tasks:open-db))
	    (pth (tasks:get-task-db-path)))
	(set! *task-db* (vector db pth))
	db)))
  
;;======================================================================
;; Server and client management







|







116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
                                CONSTRAINT clients_constraint UNIQUE (pid,hostname));")
                                  
	  ))
    mdb))

(define (tasks:get-db)
  (if *task-db*
      (vector-ref *task-db* 0)
      (let ((db  (tasks:open-db))
	    (pth (tasks:get-task-db-path)))
	(set! *task-db* (vector db pth))
	db)))
  
;;======================================================================
;; Server and client management