geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emerson Cargnin" <echoflor...@bol.com.br>
Subject Cant run/debug geronimo, please help...
Date Tue, 26 Aug 2003 01:48:14 GMT
Sorry for the long post, but i've been through some problems, I'd like to
share with you(and help me to solve it too :).

I'm trying to boot geronimo (windows 2000 , Sun jdk1.4.2), but without
success :

1- going to \target\geronimo-DEV\bin and typing start just opens a new
screen

2 - inside bin, I type twiddle, and I get the following stacktrace :

C:\temp\geronimo\bin>edit twiddle.bat

C:\temp\geronimo\bin>twiddle
21:03:54,859 DEBUG [Main] Home URL: file:/C:/temp/geronimo/
21:03:54,859 DEBUG [Main] Configuration URL:
file:/C:/temp/geronimo/etc/twiddle.conf
21:03:54,953 DEBUG [ConfigurationReader] Reading:
file:/C:/temp/geronimo/etc/twiddle.conf
21:03:55,359 DEBUG [NestedThrowable]
org.apache.geronimo.common.NestedThrowable.parentTraceEnabled=true
21:03:55,359 DEBUG [NestedThrowable]
org.apache.geronimo.common.NestedThrowable.nestedTraceEnabled=false
21:03:55,375 DEBUG [NestedThrowable]
org.apache.geronimo.common.NestedThrowable.detectDuplicateNesting=true
org.apache.geronimo.twiddle.config.ConfigurationException: Failed to process
include: ${twiddle.home}/etc/twiddle/*.conf; - nested throwable:
(java.net.MalformedURLException: Failed to create URL from filespec:
C:\temp\geronimo\bin\../etc/twiddle/*.conf)

I tried to debuig in eclipse :

java.io.FileNotFoundException: C:\eclipse\workspace\etc\twiddle.conf (O
sistema não pode encontrar o caminho especificado)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:106)
at java.io.FileInputStream.<init>(FileInputStream.java:66)
at
sun.net.www.protocol.file.FileURLConnection.connect(FileURLConnection.java:6
9)
at
sun.net.www.protocol.file.FileURLConnection.getInputStream(FileURLConnection
.java:156)
at java.net.URL.openStream(URL.java:913)
at
org.apache.geronimo.twiddle.config.ConfigurationReader.read(ConfigurationRea
der.java:115)
at org.apache.geronimo.twiddle.cli.Main.boot(Main.java:199)
at org.apache.geronimo.twiddle.cli.Main.main(Main.java:223)
at org.apache.geronimo.twiddle.cli.Main.main(Main.java:236)
...

As you can see, it goes a dir up than it should (maybe because i'm running
the code out of the twiddle jar, maybe another approache to discover home
location would be better).

the following code in Twiddle.getHomeDir() :

String path =
Twiddle.class.getProtectionDomain().getCodeSource().getLocation().getFile();
path = URLDecoder.decode(path, "UTF-8");
// home dir is expected to be lib/..
dir = new File(path).getParentFile().getParentFile();

Maybe it's happening becouse i'm debugging the code directly and not using
the twiddle from the jar.

Now I set the TWIDDLE_HOME, but the code :

// Determine what our home directory is
String temp = System.getProperty(TWIDDLE_HOME);

doesn't work.

What should be the solution for this?

I solved it sending a parameter :
-Dtwiddle.home=C:/eclipse/workspace/incubator-geronimo/target/geronimo-DEV
But it should be using the system properties, isn't?

Now : ) I got and error in
_includeList=[${twiddle.home}/etc/twiddle/*.conf]
the value
C:/eclipse/workspace/incubator-geronimo/target/geronimo-DEV/etc/twiddle/*.co
nf
in the  code (commons/Strings.makeURLFromFilespec) :

// make sure it is canonical (no ../ and such)
file = file.getCanonicalFile();

It looks like *.conf from twiddles.conf file is causing the error
<includes>
<include>${twiddle.home}/etc/twiddle/*.conf</include>
</includes>

should I conf  each file? is it just me?
Stack-trace :

org.apache.geronimo.twiddle.config.ConfigurationException: Failed to process
include: ${twiddle.home}/etc/twiddle/*.conf; - nested throwable:
(java.net.MalformedURLException: Failed to create URL from filespec:
C:/eclipse/workspace/incubator-geronimo/target/geronimo-DEV/etc/twiddle/*.co
nf)
at
org.apache.geronimo.twiddle.config.Configurator.configureIncludes(Configurat
or.java:158)
at
org.apache.geronimo.twiddle.config.Configurator.configure(Configurator.java:
115)
at org.apache.geronimo.twiddle.Twiddle.configure(Twiddle.java:203)
at org.apache.geronimo.twiddle.cli.Main.boot(Main.java:202)
at org.apache.geronimo.twiddle.cli.Main.main(Main.java:223)
at org.apache.geronimo.twiddle.cli.Main.main(Main.java:236)
Caused by: java.net.MalformedURLException: Failed to create URL from
filespec:
C:/eclipse/workspace/incubator-geronimo/target/geronimo-DEV/etc/twiddle/*.co
nf
at org.apache.geronimo.common.Strings.toURL(Strings.java:713)
at org.apache.geronimo.common.Strings.toURL(Strings.java:752)
at
org.apache.geronimo.twiddle.config.Configurator.parseGlobURLs(Configurator.j
ava:173)
at
org.apache.geronimo.twiddle.config.Configurator.configureIncludes(Configurat
or.java:151)
... 5 more
Caused by: java.io.IOException: O sistema não pode encontrar o caminho
especificado
at java.io.WinNTFileSystem.canonicalize0(Native Method)
at java.io.Win32FileSystem.canonicalize(Win32FileSystem.java:352)
at java.io.File.getCanonicalPath(File.java:513)
at java.io.File.getCanonicalFile(File.java:534)
at org.apache.geronimo.common.Strings.makeURLFromFilespec(Strings.java:735)
at org.apache.geronimo.common.Strings.toURL(Strings.java:709)
... 8 more


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.512 / Virus Database: 309 - Release Date: 19/8/2003


Mime
View raw message