qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "lahiru gunathilake" <glah...@gmail.com>
Subject Debug the Java broker using Idea
Date Tue, 17 Jun 2008 14:03:34 GMT
hi Devs,

I want to debug the broker using Idea and here's what I did,

1. I ran mvn idea:idea to build idea project and open the project in idea
and build it using idea.
2. It builds successfully but there are some Warnings. And now I want to
start the broker and debug  using idea. But I couldn't find what is the main
file to run it.
3. I found there's a main file in this location
luster/src/main/java/org/apache/qpid/server/cluster/Main.java Is that the
main file you are running when we run the script qpid-server script.
4. When I run that file it gives this message
File etc/config.xml could not be found. Check the file exists and is
readable.
Note: QPID_HOME is not set. (But i have already set the QPID_HOME
environment variable. (I'm successfully running the broker in console).So I
change the code and hardcoded the QpidHome variable. And it throws an
Exception like this.
==========================================================================================
log4j:ERROR setFile(null,false) call failed.
java.io.FileNotFoundException: /log/alert.log (No such file or directory)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:102)
    at org.apache.log4j.FileAppender.setFile(FileAppender.java:289)
    at org.apache.log4j.FileAppender.activateOptions(FileAppender.java:163)
    at
org.apache.log4j.config.PropertySetter.activate(PropertySetter.java:256)
    at
org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:220)
    at
org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:150)
    at
org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:163)
    at
org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:425)
    at
org.apache.log4j.xml.DOMConfigurator.parseCategory(DOMConfigurator.java:345)
    at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:827)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:712)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:604)
    at
org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:733)
    at org.apache.qpid.server.Main.configureLogging(Main.java:512)
    at org.apache.qpid.server.Main.startup(Main.java:252)
    at org.apache.qpid.server.Main.execute(Main.java:195)
    at org.apache.qpid.server.Main.<init>(Main.java:95)
    at org.apache.qpid.server.Main.main(Main.java:456)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
log4j:ERROR setFile(null,false) call failed.
java.io.FileNotFoundException: /log/qpid.log (No such file or directory)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:102)
    at org.apache.log4j.FileAppender.setFile(FileAppender.java:289)
    at org.apache.log4j.FileAppender.activateOptions(FileAppender.java:163)
    at
org.apache.log4j.config.PropertySetter.activate(PropertySetter.java:256)
    at
org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:220)
    at
org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:150)
    at
org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:163)
    at
org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:425)
    at
org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:394)
    at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:829)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:712)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:604)
    at
org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:733)
    at org.apache.qpid.server.Main.configureLogging(Main.java:512)
    at org.apache.qpid.server.Main.startup(Main.java:252)
    at org.apache.qpid.server.Main.execute(Main.java:195)
    at org.apache.qpid.server.Main.<init>(Main.java:95)
    at org.apache.qpid.server.Main.main(Main.java:456)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
Error configuring message broker:
org.apache.commons.configuration.ConfigurationException: Property
${QPID_HOME} has not been set
org.apache.commons.configuration.ConfigurationException: Property
${QPID_HOME} has not been set
    at
org.apache.qpid.server.security.auth.database.ConfigurationFilePrincipalDatabaseManager.initialisePrincipalDatabase(ConfigurationFilePrincipalDatabaseManager.java:159)
    at
org.apache.qpid.server.security.auth.database.ConfigurationFilePrincipalDatabaseManager.initialisePrincipalDatabases(ConfigurationFilePrincipalDatabaseManager.java:88)
    at
org.apache.qpid.server.security.auth.database.ConfigurationFilePrincipalDatabaseManager.<init>(ConfigurationFilePrincipalDatabaseManager.java:56)
    at
org.apache.qpid.server.registry.ConfigurationFileApplicationRegistry.initialise(ConfigurationFileApplicationRegistry.java:112)
    at
org.apache.qpid.server.registry.ApplicationRegistry.initialise(ApplicationRegistry.java:97)
    at
org.apache.qpid.server.registry.ApplicationRegistry.initialise(ApplicationRegistry.java:85)
    at org.apache.qpid.server.Main.startup(Main.java:262)
    at org.apache.qpid.server.Main.execute(Main.java:195)
    at org.apache.qpid.server.Main.<init>(Main.java:95)
    at org.apache.qpid.server.Main.main(Main.java:456)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
Caused by: org.apache.qpid.configuration.PropertyException: Property
${QPID_HOME} has not been set
    at
org.apache.qpid.configuration.PropertyUtils.replaceProperties(PropertyUtils.java:83)
    at
org.apache.qpid.server.security.auth.database.ConfigurationFilePrincipalDatabaseManager.initialisePrincipalDatabase(ConfigurationFilePrincipalDatabaseManager.java:149)
    ... 14 more
2008-06-17 19:29:47,612 ERROR [main] server.Main (Main.java:206) - Error
configuring message broker:
org.apache.commons.configuration.ConfigurationException: Property
${QPID_HOME} has not been set
=====================================================================================

Can anybody help me to figure this out..

Regards
Lahiru

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message