Megatest

Check-in [5209afd099]
Login
Overview
Comment:wip
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | v1.7001-multi-db-rb01
Files: files | file ages | folders
SHA1: 5209afd099a8d442ce341e5d7b26d201803ae649
User & Date: matt on 2022-04-07 07:04:24
Other Links: branch diff | manifest | tags
Context
2022-04-21
19:10
implemented db:get-db with extra runid arg check-in: c201b33851 user: matt tags: v1.7001-rebase-wip, v1.7001-multi-db-rb01
2022-04-12
07:15
Merged back to v1.7001-multi-db check-in: 689ac0bf5f user: matt tags: v1.7001-multi-db-rb01
2022-04-11
21:43
wip check-in: bd65c1e661 user: matt tags: v1.7001-multi-db-wip2, v1.7001-multi-db-rb01
2022-04-10
20:05
Merged Martin's fix. Got commonmod, debugprint and mtargs modules working check-in: 911725fc69 user: matt tags: v1.7001-multi-db-wip, v1.7001-multi-db-rb01
2022-04-07
07:04
wip check-in: 5209afd099 user: matt tags: v1.7001-multi-db-rb01
06:38
sync working? check-in: f2cf1492f8 user: matt tags: v1.7001-multi-db-rb01
Changes

Modified dbfile.scm from [9671b9ee01] to [c5ec4d8a51].

443
444
445
446
447
448
449
450
451
452
453
454








455
456
457


458
459
460
461
462
463
464
443
444
445
446
447
448
449





450
451
452
453
454
455
456
457



458
459
460
461
462
463
464
465
466







-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
+
+







;;======================================================================

;; if we are not a server create a db handle. this is not finalized
;; so watch for problems. I'm still not clear if it is needed to manually
;; finalize sqlite3 dbs with the sqlite3 egg.
;;
(define (db:no-sync-db db-in)
  (mutex-lock! *db-access-mutex*)
  (let ((res (if db-in
                 db-in
                 (let ((db (dbfile:open-no-sync-db)))
                   (set! *no-sync-db* db)
  (if db-in
      db-in
      (if *no-sync-db*
	  *no-sync-db*
	  (begin
	    (mutex-lock! *db-access-mutex*)
	    (let ((db (dbfile:open-no-sync-db)))
	      (set! *no-sync-db* db)
                   db))))
    (mutex-unlock! *db-access-mutex*)
    res))
	      (mutex-unlock! *db-access-mutex*)
	      db)))))

(define (dbfile:open-no-sync-db dbpath)
  (let* (;; (dbpath (db:dbfile-path))
	 (dbname (conc dbpath "/no-sync.db"))
	 (db-exists (file-exists? dbname))
	 (db     (sqlite3:open-database dbname)))
    (sqlite3:set-busy-handler! db (sqlite3:make-busy-timeout 136000))