Mail Archive Home | jotm List | Febuary 2003 Index
| <-- Date Index --> | <-- Thread Index --> |
Jeff Mesnil <Jean-Frederic.Mesnil@xxxxxxxxxxxx> wote :
> Hi,
>
>> The problems I am encountering is that Carol cannot find carol.properties
>> and jndi.properties. The strange thing is that all the files are on
>> classpath and I can verify that, because trace.properties are being foung.
>> I am getting following exception
>
> I had the same problem (and the same exception) with JOTM in Tomcat.
>
>> I think the problem is in CommunicationConfiguration.java in the following
>> code
>> public static void loadCarolConfiguration() throws
>> RMIConfigurationException {
>> Properties rmiProps = new Properties();
>> Properties jndiProps = new Properties();
>> // load the configuration files
>> try {
>> // load the rmi configuration file
>> InputStream rmiFileInputStream =
>> ClassLoader.getSystemResourceAsStream(CAROL_FILE_NAME);
>
> Miro is right: I've checked out CAROL and replace
>
> InputStream rmiFileInputStream =
> ClassLoader.getSystemResourceAsStream(CAROL_FILE_NAME);
>
> by
>
> InputStream rmiFileInputStream =
> Thread.currentThread().getContextClassLoader().getResourceAsStream(CAROL_FILE_NAME);
>
> and the exception is no more thrown (see diff at the end of my mail).
>
> cheers,
> jeff
Thank you Jeff,
For this modification (bug correction), I'm going to integrate this
inside Carol (for 1.3 release)
Your are now writer inside the Carol CVS repository for future
modifications, bug correction of this type.
Guillaume
>
> RCS file:
> /cvsroot/carol/carol/src/org/objectweb/carol/util/configuration/CommunicationConfiguration.java,v
> retrieving revision 1.8
> diff -r1.8 CommunicationConfiguration.java
> 147c147
> < InputStream rmiFileInputStream =
> ClassLoader.getSystemResourceAsStream(CAROL_FILE_NAME);
> ---
> > InputStream rmiFileInputStream =
> Thread.currentThread().getContextClassLoader().getResourceAsStream(CAROL_FILE_NAME);
> 155c155
> < InputStream jndiFileInputStream =
> ClassLoader.getSystemResourceAsStream(JNDI_FILE_NAME);
> ---
> > InputStream jndiFileInputStream =
> Thread.currentThread().getContextClassLoader().getResourceAsStream(JNDI_FILE_NAME);
--
Guillaume Riviere
INRIA -- SARDES/IMPACT
ObjectWeb Consortium
+(33)476615525
| <-- Date Index --> | <-- Thread Index --> |
Powered by MHonArc.
Copyright © 2006-2007, OW2 Consortium | contact | webmaster.