Hi Ginnie,

I am concern about your comments on logger.py, lines 394-403.

On there, you said that to use this new interface, one needs to
first call logging.setLoggerClass(InstallLogger), then, call
getLogger() with the "default logger file" value that they want,
then, instantiate the engine.

That's not how things work in the CUD, from my understanding.

In CUD, the install engine should be the one, and the only one,
that sets up all the logging stuff to be used by all
the applications.  Engine is the one
that calls the logging.setLoggerClass(), then, call the
getLogger(INSTALL_LOGGER_NAME...).
That's what the engine's _init_logging() function
does today.  In that function, we even explicitly
check to make sure nobody else has called getLogger()
before the engine is instantiated.  See the code here:
http://src.opensolaris.org/source/xref/caiman/slim_source/usr/src/lib/install_engine/__init__.py#215

If we want to allow the user to pass in a default log file name
to use, we can modify the __init__() function of the install
engine to accept an additional argument for default log file name,
and the engine can call getLogger() with this default log file name.

Thanks,

--Karen

On 08/09/11 12:43, Virginia Wray wrote:
Hi --

Could I get a code review for the following bug:
http://monaco.us.oracle.com/detail.jsf?cr=7033339
Be able to specify logfile name when instantiate InstallLogger

https://cr.opensolaris.org/action/browse/caiman/ginnie/7033339/webrev/


I've tested the changes with the distro constructor. I ran it in its original
form and it completed successfully. I also modified it to set it's own
default log using my code changes and ran it. I checked to make sure
the engine interface worked correctly with these changes as well.
In both instances, it logged to the location that I expected.

I've included instructions on how to invoke this in the logger.py file.

I've asked Karen and Drew to review. Others are welcome as well.
I'm leaving on vacation, so if you could respond today, I would
appreciate it.

thanks,
ginnie


_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

Reply via email to