Commit Graph

9 Commits

Author SHA1 Message Date
Matthew Flatt
6eef00a312 raco setup: fix problem with doc index database
When a tag is serializable but not `write'--`read' invariant,
then it needs to be serialized and deserialized.

Also, clarify and check in `tag?' that a tag should be
serializable.
2012-12-13 15:45:48 -07:00
Matthew Flatt
cd257fe65b setup/xref: simplify db interaction
Relies on improvements to SQLite retry support.
2012-12-03 18:57:53 -07:00
Matthew Flatt
569af52ffc raco setup: turn off synchronous mode for doc database
Synchronous mode implies fsync(), which makes updates *much*
slower on some machines, such as the DrDr machine. The doc
database doesn't need to survive a catastrophic failue
(such as a power failure or OS crash), so turn synchronous
mode off.
2012-11-26 06:24:29 -07:00
Matthew Flatt
31e644e5e1 raco setup: add a layer of db write locking, db read fallback
Change `raco setup' to guard database writes in different places
by an explicit lock that is implemented by place channels. Change
corss-reference reading to fall back to just loading ".sxref"
files if the database seems to be too contended at that point.

These changes are aimed at avoiding distaerous performance when
SQLite seems not to behave well.

Also, fix break and other exception handling near the "fast abort"
path for both reads and writes.
2012-11-25 17:55:23 -07:00
Matthew Flatt
d47bfc287d raco setup: more consistent logging and pausing on db locks 2012-11-25 07:23:59 -07:00
Matthew Flatt
c12a129b09 remove unused locking layer in the doc database manager 2012-11-24 08:13:51 -07:00
Matthew Flatt
9888fac99e raco setup: move doc dependency and duplicate checking to database
This change makes document building --- and specially incremental
document building --- more scalable. The global duplicate-definition
check is handled by a database query, for example.
2012-11-23 20:07:49 -07:00
Matthew Flatt
41e9e3e5ff db: add `sqlite3-available?'
Loading `db/sqlite3' no longer raises an exception if
the SQLite library isn't found. Instead, `sqlite3-connect'
raises an exception, while `sqlite3-available?' reports
whether it will work.

The dynamic test allows the documentation-help system
to continue to work if SQLite3 is not available. Currently,
though, `raco setup' still insists on using SQLite3 to
build the database of documented tags.
2012-11-23 18:44:51 -07:00
Matthew Flatt
8c1b5db815 raco setup: build database mapping doc tags to "out.sxref"s
The `xref' produced by `setup/xref' uses the database to delay
loading "out.sxref"s, which cuts 64-bit DrRacket's initial
footprint by around 50MB (i.e., about 20%).
2012-11-23 18:44:50 -07:00