On Wed, 12 Dec 2001, Bill Barker wrote:

> I'm probably just misunderstanding what situations you are trying to handle
> here, so if you can be a little bit more verbose, I'll probably change my
> vote.

More details:

jk_env will replace all jk_logger_t parameters. All methods will follow
the  pattern:

  method( jk_env *env, jk_foo *_this, ... other params ... );

The env will be guaranteed to be used single-threaded ( i.e. either each
thread has a per/thread env, or we use the objCache, or any other
mechanism ). mod_jk will get an instance and release it after it's done.

The env will be have few uses:

- save the error message and details. When an error is detected, besides
returning the right status ( or NULL for methods returning a real object
and not using ** ), we'll call env->throw() method. This will replace the
current jkLog( JK_ERROR, ... ) ( which will be implemented in throw() )
from each method. Caller could either check the rc, or env->error ( I
prefer the second because it's more consistent )

- logger. In addition, because env is per/thread we could do some tricks
here too ( right now it works because printf is synchronized - or I think
so ).

- temp pool/storage. Things like map, logger, etc need some temp storage.
Right now they either malloc/free or use some other ugly tricks ( per
stack, etc ).


Costin


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to