Megatest

Check-in [f22ffbf700]
Login
Overview
Comment:wip
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | v1.80-servload
Files: files | file ages | folders
SHA1: f22ffbf700a5263dfe5cbd6d9dacf174e7d1c663
User & Date: matt on 2023-04-30 10:57:34
Other Links: branch diff | manifest | tags
Context
2023-04-30
20:59
db2db sync almost working check-in: 2a182fc8db user: matt tags: v1.80-servload
10:57
wip check-in: f22ffbf700 user: matt tags: v1.80-servload
2023-04-27
21:53
Attempt to use threads to reduce updater impact on dashboard gui redraw check-in: e4fc754440 user: matt tags: v1.80-servload
Changes

Modified dashboard.scm from [4eb224d52b] to [3d1081a532].

261
262
263
264
265
266
267

268
269
270
271

272
273
274


275


276

277
278
279
280

281
282
283
284
285
286
287
				     "updaters thread"))
		   (th2 (make-thread (lambda ()
				       (let loop ()
					   (case (thread-state th1)
					     ((terminated)
					      (debug:print 0 *default-log-port* "th1 terminated, all done for now."))
					     ((running)

					      (thread-suspend! th1)
					      (thread-sleep! 0.1)
					      (loop))
					     ((sleeping)

					      (thread-resume! th1)
					      (thread-sleep! 0.9)
					      (loop))


					     (else


					      (loop))))))))

	      (thread-start! th1)
	      (thread-sleep! 0.1)
	      (thread-start! th2)
	      (thread-join! th1))))))


;; if tab-num passed in then use it, otherwise look in commondat at curr-tab-num
;; adds the updater passed in the updaters list at that hashkey
;;
(define (dboard:commondat-add-updater commondat updater #!key (tab-num #f))
  (let* ((tnum          (or tab-num
			     (dboard:commondat-curr-tab-num commondat)))







>




>



>
>

>
>

>



|
>







261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
				     "updaters thread"))
		   (th2 (make-thread (lambda ()
				       (let loop ()
					   (case (thread-state th1)
					     ((terminated)
					      (debug:print 0 *default-log-port* "th1 terminated, all done for now."))
					     ((running)
					      (debug:print 0 *default-log-port* "th1 running, suspending now.")
					      (thread-suspend! th1)
					      (thread-sleep! 0.1)
					      (loop))
					     ((sleeping)
					      (debug:print 0 *default-log-port* "th1 sleeping, resuming now.")
					      (thread-resume! th1)
					      (thread-sleep! 0.9)
					      (loop))
					     ((dead)
					      (debug:print 0 *default-log-port* "th1 "(thread-state th1)", what's next?"))
					     (else
					      (debug:print 0 *default-log-port* "th1 "(thread-state th1)", what's next?")
					      (thread-sleep! 0.5)
					      (loop))))))))
	      (set! *updaters-running* #t)
	      (thread-start! th1)
	      (thread-sleep! 0.1)
	      (thread-start! th2)
	      (thread-join! th1)
	      (set! *updaters-running* #f))))))

;; if tab-num passed in then use it, otherwise look in commondat at curr-tab-num
;; adds the updater passed in the updaters list at that hashkey
;;
(define (dboard:commondat-add-updater commondat updater #!key (tab-num #f))
  (let* ((tnum          (or tab-num
			     (dboard:commondat-curr-tab-num commondat)))

Modified dbmod.scm from [e4788821d9] to [89117c0f03].

783
784
785
786
787
788
789










790
791
792
     run-id
     #t
     (lambda (dbdat db)
       (sqlite3:execute db qry
			(or newstate  currstate "NOT_STARTED")
			(or newstatus currstate "UNKNOWN")
			run-id testname)))))












)







>
>
>
>
>
>
>
>
>
>



783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
     run-id
     #t
     (lambda (dbdat db)
       (sqlite3:execute db qry
			(or newstate  currstate "NOT_STARTED")
			(or newstatus currstate "UNKNOWN")
			run-id testname)))))
;;======================================================================
;; db to db sync
;;======================================================================

(define (dbmod:db-to-db-sync src-db dest-db last-update)
  (let ((sdb #f) ;;
	(ddb #f))
    (dbmod:sync-gasket tables last-update inmem db
		       dbfullname syncdir)
    ))


)