dev@glassfish.java.net

Re: need to create logging.properties file during upgrade

From: Kedar Mhaswade <Kedar.Mhaswade_at_Sun.COM>
Date: Wed, 29 Jul 2009 12:02:49 -0700

I don't know why you have moved the upgrade code in server-mgmt (which
is supposed to be a client-side code).
Anyway, to make this work, you need to use the RepositoryManager
constructor correctly.

See an example usage in cli-optional/.../ChangeMasterPasswordCommand.java
and its superclass.


Carla Mott wrote:
> I have moved my upgrade logging code to server-mgmt to avoid the
> dependency issues and started using the methods in PEFileLayout to find
> the destination dir (config). However the config dir returned is
> <install_dir>/glassfish/domains/config which is incorrect for what I'm
> doing.
>
> I'm looking for <install_dir>/glassfish/domains/domain1/config. So is
> there a class that returns this information? From RepositoryConfig I
> can get the repositoryRoot, repositoryName name and the instances name.
> So I can build the name if there is not another way to get it.
>
>
> Thanks,
> Carla
>
>
>
> Carla Mott wrote:
>> Hi,
>>
>> I see there is code in admin/server-mgmt that handle the case where
>> domain.xml doesn't exist. I thought I could leverage some of that.
>> In the case of logging things are simpler in that I only need to copy
>> the template file for logging.properties to the config dir of the
>> domain instance. I don't need to create log files etc as that is
>> handled separately. This should only really be needed during upgrade
>> process.
>>
>> I tried updating my code which reads the logging.properties file but
>> that code is in common/common-util and I can not have a dependency on
>> server-mgmt in that module. So I need to know where to put my updates
>> so that very early in the upgrade cycle I can copy over the
>> logging.properties file to the config dir of the domain and how that
>> will get called.
>>
>> Anyone know the appropriate place?
>>
>> Thanks,
>> Carla
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
>> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>