[sip-comm-dev] Questions about Felix and Logger


#1

Hi,

I have two questions.

The first one is about Felix : to add something into SC, we need to
add a line in the file : "lib/felix.client.run.properties". The
question is : is the jars loaded in the same order as the lines ?

The second question is about the Logger, I think it's more convenient
to have a log file by profile. I've read the class implementation and
the javadoc of the java.util.logging.Logger class but I haven't found
something to set the location where the logs are saved. Do you know
where we can set this location ?

Cheers

Damien

···

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net


#2

Damien Roth wrote:

The first one is about Felix : to add something into SC, we need to
add a line in the file : "lib/felix.client.run.properties". The
question is : is the jars loaded in the same order as the lines ?
  
I believe yes, but there is no guarantee. You should not try to depend on ordering in OSGi.

-> richard

···

The second question is about the Logger, I think it's more convenient
to have a log file by profile. I've read the class implementation and
the javadoc of the java.util.logging.Logger class but I haven't found
something to set the location where the logs are saved. Do you know
where we can set this location ?

Cheers

Damien

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net


#3

Hey there Damien,

Damien Roth написа:

Hi,

I have two questions.

The first one is about Felix : to add something into SC, we need to
add a line in the file : "lib/felix.client.run.properties". The
question is : is the jars loaded in the same order as the lines ?

Having read your personal mail I imagine you are asking this in relation
to the implementation of the profile manager. The thing is that in order
to successfully set a profile for SIP Communicator you need to plug your
code in a place where it would run before Felix, so that Felix would
take into account the properties that you've set. The best way to do
this would be to modify the SIP Communicator launcher. I know that this
would make it difficult to have your code work as a plugin but I don't
think this is a problem: we'd simply integrate it in the trunk.

Note however, that you would still need to plug the configuration part
as a plugin. That is, the part where you'd be able to create, delete and
edit profiles, as well as select the default profile to load.

Give me a phone call in case you'd like to discuss this in more detail.

The second question is about the Logger, I think it's more convenient
to have a log file by profile. I've read the class implementation and
the javadoc of the java.util.logging.Logger class but I haven't found
something to set the location where the logs are saved. Do you know
where we can set this location ?

Good thinking! This is currently being set through the
logging.properties file. I don't see a way how we could easily bind it
to the profiles though, so this might be tricky, especially given that
once you start the profile manager it would already be too late to
change anything through the system properties.

We are using the java.util.logging utilities so you'd have to look in
there for a way to globally change all FileHandlers after an application
has been started and potentially even after having already instantiated
some of the loggers.

Anyways, even though this is important, if I were you I'd only were
about it after the rest of the profile manager is working.

Cheers
Emil

···

Cheers

Damien

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net