ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » WMB v6 / XP / Java - can't find log4j output

Post new topic  Reply to topic
 WMB v6 / XP / Java - can't find log4j output « View previous topic :: View next topic » 
Author Message
hopsala
PostPosted: Mon Dec 10, 2007 12:02 pm    Post subject: WMB v6 / XP / Java - can't find log4j output Reply with quote

Guardian

Joined: 24 Sep 2004
Posts: 960

Hi guys (and gals), long time no see. I trust everyone is doing well.

My problem is simple - I can't find the output file for messages I send into log4j. I've read all the posts I could find here about log4j but couldn't find any reference to a similar problem.

Now, the same code works fine in any other system, and in the properties file I specify an absolute path. I've put the properties file into the jar (the one which goes to the bar file).
What's really strange, is that I don't crash even if I don't provide a properties file - when it isn't in the jar or anywhere else... ??

There are no relevant files in \common and in the EG libraries. I've even tried searching the entire computer for files changed recently (after running the mf), but to no avail. Meaning that for some reason writing is blocked.

Any ideas? Is there anything specific one has to do to make log4j work with WMB? Where should I put the properties file?

Thanks much,
Hop
Back to top
View user's profile Send private message
TonyD
PostPosted: Mon Dec 10, 2007 1:22 pm    Post subject: Reply with quote

Knight

Joined: 15 May 2001
Posts: 540
Location: New Zealand

The name of the directory where the properties file is located should be in the broker's CLASSPATH.
Back to top
View user's profile Send private message Send e-mail
ling_71_99
PostPosted: Tue Dec 11, 2007 8:22 am    Post subject: Should use classpath if you put properties in jar file Reply with quote

Novice

Joined: 19 Nov 2007
Posts: 11
Location: Canada

// Use a PropertyConfigurator to initialize from a property file.
String resource = "/examples/lf5/InitUsingPropertiesFile/example.properties";
URL configFileResource =
<class name here>.class.getResource(resource);
PropertyConfigurator.configure(configFileResource);

Regards,
Michael
_________________
Mike
Back to top
View user's profile Send private message
hopsala
PostPosted: Tue Dec 11, 2007 8:43 am    Post subject: Reply with quote

Guardian

Joined: 24 Sep 2004
Posts: 960

Thanks, the CLASSPATH tip solved it.

took me a while to find where the broker sets its environment; I eventually found it under "C:\Documents and Settings\All Users\Application Data\IBM\MQSI\common\profiles". I set the CLASSPATH and it worked.

Cheers!
Hop
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » WMB v6 / XP / Java - can't find log4j output
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.