Fossil

Check-in [2630e506]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Tweaked the log output for the statistics a bit.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:2630e50610bdd0ed0370b3958a4a41c6dc962483
User & Date: aku 2007-11-22 07:21:12
Context
2007-11-22
07:22
Reworked the dot export internals a bit to be more general regarding labeling and attribute writing. Updated the cycle breaker to define proper labels. check-in: f2848471 user: aku tags: trunk
07:21
Tweaked the log output for the statistics a bit. check-in: 2630e506 user: aku tags: trunk
06:03
Fixed the calculation of possible parents for a detached NTDB. Has to be trunk. The symbols were skipped before, causing them to have no parents at all later on, forcing an abort after CollateSymbols. Added some high verbosity log commands for debugging of this area. check-in: 930ec162 user: aku tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tools/cvs2fossil/lib/c2f_repository.tcl.

193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
...
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
	    set  bfmt %-${bmax}s
	} else {
	    set bfmt %s
	}

	foreach p $prlist {
	    set pid [$p id]
	    set prefix "Statistics: Project [format $bfmt \"[$p printbase]\"]"
	    regsub -all {[^	]} $prefix { } blanks
	    set sep " : "

	    set rcount [state one { SELECT COUNT (*) FROM revision R, file F WHERE R.fid = F.fid AND F.pid = $pid }]
	    set tcount [state one { SELECT COUNT (*) FROM tag T,      file F WHERE T.fid = F.fid AND F.pid = $pid }]
	    set bcount [state one { SELECT COUNT (*) FROM branch B,   file F WHERE B.fid = F.fid AND F.pid = $pid }]
	    set scount [state one { SELECT COUNT (*) FROM symbol             WHERE pid = $pid                     }]
	    set acount [state one { SELECT COUNT (*) FROM author   WHERE aid IN (SELECT DISTINCT aid FROM meta WHERE pid = $pid) }]
	    set ccount [state one { SELECT COUNT (*) FROM cmessage WHERE cid IN (SELECT DISTINCT cid FROM meta WHERE pid = $pid) }]

	    log write 2 repository "$prefix$sep[format $fmt $rcount] [sp $rcount revision]"
	    log write 2 repository "$blanks$sep[format $fmt $tcount] [sp $tcount tag]"
	    log write 2 repository "$blanks$sep[format $fmt $bcount] [sp $bcount branch branches]"
	    log write 2 repository "$blanks$sep[format $fmt $scount] [sp $scount symbol]"
	    log write 2 repository "$blanks$sep[format $fmt $acount] [sp $acount author]"
	    log write 2 repository "$blanks$sep[format $fmt $ccount] [sp $ccount {log message}]"
	}
	return
    }

    # pass II persistence
    typemethod persistrev {} {
	state transaction {
................................................................................
	    set  bfmt %-${bmax}s
	} else {
	    set bfmt %s
	}

	foreach p $prlist {
	    set pid [$p id]
	    set prefix "Statistics: Project [format $bfmt \"[$p printbase]\"]"
	    regsub -all {[^	]} $prefix { } blanks
	    set sep " : "

	    set ccount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid              }]
	    set rcount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid AND type = 0 }]
	    set scount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid AND type = 1 }]

	    log write 2 repository "$prefix$sep[format $fmt $ccount] [sp $ccount changeset]"
	    log write 2 repository "$blanks$sep[format $fmt $rcount] [sp $rcount {revision changeset}]"
	    log write 2 repository "$blanks$sep[format $fmt $scount] [sp $scount {symbol changeset}]"
	}
	return
    }

    # # ## ### ##### ######## #############
    ## State








|










|
|
|
|
|
|







 







|







|
|
|







193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
...
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
	    set  bfmt %-${bmax}s
	} else {
	    set bfmt %s
	}

	foreach p $prlist {
	    set pid [$p id]
	    set prefix "Project [format $bfmt \"[$p printbase]\"]"
	    regsub -all {[^	]} $prefix { } blanks
	    set sep " : "

	    set rcount [state one { SELECT COUNT (*) FROM revision R, file F WHERE R.fid = F.fid AND F.pid = $pid }]
	    set tcount [state one { SELECT COUNT (*) FROM tag T,      file F WHERE T.fid = F.fid AND F.pid = $pid }]
	    set bcount [state one { SELECT COUNT (*) FROM branch B,   file F WHERE B.fid = F.fid AND F.pid = $pid }]
	    set scount [state one { SELECT COUNT (*) FROM symbol             WHERE pid = $pid                     }]
	    set acount [state one { SELECT COUNT (*) FROM author   WHERE aid IN (SELECT DISTINCT aid FROM meta WHERE pid = $pid) }]
	    set ccount [state one { SELECT COUNT (*) FROM cmessage WHERE cid IN (SELECT DISTINCT cid FROM meta WHERE pid = $pid) }]

	    log write 2 repository "Statistics: $prefix$sep[format $fmt $rcount] [sp $rcount revision]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $tcount] [sp $tcount tag]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $bcount] [sp $bcount branch branches]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $scount] [sp $scount symbol]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $acount] [sp $acount author]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $ccount] [sp $ccount {log message}]"
	}
	return
    }

    # pass II persistence
    typemethod persistrev {} {
	state transaction {
................................................................................
	    set  bfmt %-${bmax}s
	} else {
	    set bfmt %s
	}

	foreach p $prlist {
	    set pid [$p id]
	    set prefix "Project [format $bfmt \"[$p printbase]\"]"
	    regsub -all {[^	]} $prefix { } blanks
	    set sep " : "

	    set ccount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid              }]
	    set rcount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid AND type = 0 }]
	    set scount [state one { SELECT COUNT (*) FROM changeset WHERE pid = $pid AND type = 1 }]

	    log write 2 repository "Statistics: $prefix$sep[format $fmt $ccount] [sp $ccount changeset]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $rcount] [sp $rcount {revision changeset}]"
	    log write 2 repository "Statistics: $blanks$sep[format $fmt $scount] [sp $scount {symbol changeset}]"
	}
	return
    }

    # # ## ### ##### ######## #############
    ## State