On Fri, Jan 30, 2004 at 03:00:37AM -0700, jim cromie wrote:sorry, I could have been clearer. esp exersizing new vocabulary.
This sounds like it could plug into the trace mechanism, either increasing its
leverage, simplifying its implementation, or both.
I've long wanted the DBI to have code hooks for method call entry & exit that could be used for building all sorts of funky tools.
And having just crept up to a line, let me cross it. Can new DBI2 have
2 logging levels under transactions ? Anything that commits (success)
logs at 1 or 2, things that rollback are logged at 5 or 6. This should
help unravel anomalous behavior by automatically putting your fovea
on it.
I'm not quite sure what you're asking for there.
Tim.
speculative logging: The basic idea is to buffer up a log as a transaction proceeds,
and decide afterwards what details of the log you want to keep - ie emit to the
logging device.
Commit/rollback is the most obvious decision point, if youve got a
rollback, or an error, dump the log-trace since the start-transaction at a high
level of detail, if all went smoothly, log only at a low trace-level.
Another way of looking at this is helping trace() to work in a scoped manner,
perhaps even as attributes to handles, etc.
trace"
DBI->trace($trace_level)
DBI->trace($trace_level, $trace_filename) $dbh->trace({on_success => 1, on_err => 6 });
$sth->trace('+1')
$sth->trace({filter => sub {...})Id hope that scoped detail-control might help find the origin of an error caught at $sth->execute(),
causing a detailed dump from beginning of the scope, whether its a transaction, perl-method, handle, etc.
wrt vocabulary, webmd.com showed me this:
*The *macula*.* This is the bull's-eye at the center of the retina. The dead center of this bull's eye is called the *fovea*. Because it's at the focal point of the eye, it has more specialized, light sensitive nerve endings, called photoreceptors, than any other part of the retina.
The fovea is where the eye is most capable of 'grokking' the scene. A large
part of the visual cortex is dedicated to processing the image collected by the
fovea.
With this, the log contained that detail where it counted, with the surrouinding
log entries providing context at a summary level.
