Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] The launcher JAR's class path

You have to put it on the classpath, so in a bundle is the only real answer.

However, you can attach it as a standalone fragment to a bundle, which
means that you've only got one thing to change when you want to apply
different properties. That fragment can even attach directly to the
log4j bundle. You may find that you need to have "Export-Package:
log4j.properties" if you have it in-bundle in order for log4j to find
it, but you shouldn't need to do that if attaching to the log4j bundle
as a fragment.

Alex.

On 10/05/07, Steven E. Harris <seh@xxxxxxxxx> wrote:
My application uses several bundles that in turn use log4j wrapped up
as a bundle (namely, Spring-OSGi). As is often the case, when log4j
starts up, it tries and fails to find a log4j.properties file on the
class path. The next step is to put a log4j.properties file somewhere
on the class path.

Say that I'm trying to launch my application like so:

  java -jar org.eclipse.equinox.launcher_[...].jar

What directories would then be visible to the log4j bundle on the
class path? Of course, some bundle content is also on the class path
as seen by a particular bundle, but putting a log4j.properties file
into one of /my/ bundles doesn't necessarily make it visible to the
log4j bundle.

Given this situation sketched here, where would be a sane place to put
a log4j.properties file?

--
Steven E. Harris

_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev



Back to the top