tcl-rivet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dav...@dedasys.com (David N. Welton)
Subject Re: Error logging
Date Mon, 20 Jan 2003 05:48:09 GMT
Damon Courtney <damon@your.unreality.com> writes:

> > Hrm... I'm undecided.  It wouldn't be much larger, but maybe
> > adding a timestamp in Tcl itself would be more Tcl'ish?

>     Hrmm... We could just add a command to do error logging.  All it
> would do is 'puts stderr' with an Apache timestamp on the front.

Sure, if we made it a Tcl optional, then people could use it if they
want the timestamp.  I guess adding a stderr channel would be a pretty
minor thing to do too.  Maybe the best thing for now is to put it in
the 'TODO' list with a note saying that we'll do it if enough people
feel that it would help them.

> > 	if (toplevel && rsc->rivet_after_script) {
> > 	    Tcl_AppendObjToObj(outbuf, Tcl_NewStringObj(rsc->rivet_after_script, -1));
> > 	}

> > We could do something like:

> > if (toplevel) {
> > #ifdef DEFAULT_AFTER_SCRIPT
> >     rsc->after_script = DEFAULT_AFTER_SCRIPT;
> > #endif
> >     if(rsc->after_script) {
> >          Tcl_AppendObjToObj(outbuf, Tcl_NewStringObj(rsc->rivet_after_script,
-1));
> >     }
> > }

> > Something like that...

> > Let's see what you've got though, so I can see exactly how you've
> > done it:-) I definitely think the file/socket cleanup stuff could
> > be useful.

>     Nah.  Screw all that. 0-] I made it into it's own procedure
> called cleanup_open_channels, and they can run it as an
> "AfterScript" if they want to.  I, originally, put it in the
> cleanup_request proc since it's there but not really doing anything.
> What do you think about that?

That sounds like the right way to handle things.  How does it work?

-- 
David N. Welton
   Consulting: http://www.dedasys.com/
     Personal: http://www.dedasys.com/davidw/
Free Software: http://www.dedasys.com/freesoftware/
   Apache Tcl: http://tcl.apache.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: rivet-dev-unsubscribe@tcl.apache.org
For additional commands, e-mail: rivet-dev-help@tcl.apache.org


Mime
View raw message