JBoss and IDEA not playing nice together

Hello, folks. I've been experiencing quite a weird situation. It seems that JBoss doesn't like IDEA or vice-versa.

For the past year or so I've been developing applications on IDEA targeted for JBoss, and never really had any problems with that. I developed the applications on my machine and deployed on a remote server. I also used to debug my application by starting the server in debug mode and attaching IDEA to it. Everything was, and for this scenario, still is fine.

However, lots of people got involved in the project and now the remote server is reserved for "test" builds -- not for everyday development cycle. Each developer should now run the app server on his own machine. Now here comes my problem: IDEA (#957) simply dies whenever JBoss (3.2.2_jetty-4.2.11) starts to deploy an application. Simple like this. No exceptions, no stack traces, no VM errors. IDEA simply vanishes without any traces left. I'm running Windows 2000 SP4.

Maybe IDEA listens on some local port that for some unknown reason JBoss broadcasts to during an application deployment? Maybe it's something related to license checker?

Is anyone else experiencing something like this? Could someone else reproduce this? Please, help me track down what could be possibly causing this. Both Jetbrainers and EAP'ers comments are welcome. Now follows lots of info that could or could not be related to this problem. Hope this helps >.<

Output of netstat -n -a -p tcp with IDEA running, before starting JBoss:

Output of the same command after starting JBoss. IDEA is dead by now:

My jboss-service.xml:
resource:log4j.xml true 127.0.0.1 -1 300 jboss:service=XidFactory jboss:service=TransactionManager jboss:service=TransactionManager true false false true true jboss:service=TransactionManager jboss.system:service=MainDeployer org.jboss.deployment.DeploymentSorter org.jboss.deployment.scanner.DeploymentFilter 5000 deploy/ True ]]>

11 comments

Crossposted to JBoss forums here[/url]

0

What way do you start JBoss? Is it a run configuration in IDEA, or do you
start from command line and attach the debugger in IDEA? If it is a
configuration does the deployment fail only
when running or also when starting under debugger?

"Marcus Brito" <pazu@animegaiden.com.br> wrote in message
news:22467196.1067451868532.JavaMail.javamailuser@localhost...

Hello, folks. I've been experiencing quite a weird situation. It seems

that JBoss doesn't like IDEA or vice-versa.
>

For the past year or so I've been developing applications on IDEA targeted

for JBoss, and never really had any problems with that. I developed the
applications on my machine and deployed on a remote server. I also used to
debug my application by starting the server in debug mode and attaching IDEA
to it. Everything was, and for this scenario, still is fine.
>

However, lots of people got involved in the project and now the remote

server is reserved for "test" builds -- not for everyday development cycle.
Each developer should now run the app server on his own machine. Now here
comes my problem: IDEA (#957) simply dies whenever JBoss
(3.2.2_jetty-4.2.11) starts to deploy an application. Simple like this. No
exceptions, no stack traces, no VM errors. IDEA simply vanishes without any
traces left. I'm running Windows 2000 SP4.
>

Maybe IDEA listens on some local port that for some unknown reason JBoss

broadcasts to during an application deployment? Maybe it's something related
to license checker?
>

Is anyone else experiencing something like this? Could someone else

reproduce this? Please, help me track down what could be possibly causing
this. Both Jetbrainers and EAP'ers comments are welcome. Now follows lots of
info that could or could not be related to this problem. Hope this helps >.<
>

Output of netstat -n -a -p tcp with IDEA running, before starting JBoss:
TCP 0.0.0.0:135 0.0.0.0:0 LISTENING > TCP 0.0.0.0:445 0.0.0.0:0 LISTENING > TCP 0.0.0.0:1029 0.0.0.0:0 LISTENING > TCP 0.0.0.0:1053 0.0.0.0:0 LISTENING > TCP 0.0.0.0:3612 0.0.0.0:0 LISTENING > TCP 0.0.0.0:4403 0.0.0.0:0 LISTENING > TCP 0.0.0.0:6942 0.0.0.0:0 LISTENING > TCP 0.0.0.0:8123 0.0.0.0:0 LISTENING > TCP 0.0.0.0:9874 0.0.0.0:0 LISTENING > TCP 10.71.2.224:139 0.0.0.0:0 LISTENING > TCP 10.71.2.224:139 10.71.2.178:3834 ESTABLISHED > TCP 10.71.2.224:2764 0.0.0.0:0 LISTENING > TCP 10.71.2.224:4529 10.42.2.17:1352 TIME_WAIT > TCP 127.0.0.1:3611 0.0.0.0:0 LISTENING > TCP 127.0.0.1:3611 127.0.0.1:3612 ESTABLISHED > TCP 127.0.0.1:3612 127.0.0.1:3611 ESTABLISHED > TCP 127.0.0.1:4403 127.0.0.1:8123 ESTABLISHED > TCP 127.0.0.1:8123 127.0.0.1:4403 ESTABLISHED]]>
Output of the same command after starting JBoss. IDEA is dead by now:
TCP 0.0.0.0:135 0.0.0.0:0 LISTENING > TCP 0.0.0.0:445 0.0.0.0:0 LISTENING > TCP 0.0.0.0:1029 0.0.0.0:0 LISTENING > TCP 0.0.0.0:1053 0.0.0.0:0 LISTENING > TCP 0.0.0.0:3612 0.0.0.0:0 LISTENING > TCP 0.0.0.0:4403 0.0.0.0:0 LISTENING > TCP 0.0.0.0:4530 0.0.0.0:0 LISTENING > TCP 0.0.0.0:4534 0.0.0.0:0 LISTENING > TCP 0.0.0.0:4536 0.0.0.0:0 LISTENING > TCP 0.0.0.0:8009 0.0.0.0:0 LISTENING > TCP 0.0.0.0:8080 0.0.0.0:0 LISTENING > TCP 0.0.0.0:8123 0.0.0.0:0 LISTENING > TCP 0.0.0.0:8787 0.0.0.0:0 LISTENING > TCP 10.71.2.224:139 0.0.0.0:0 LISTENING > TCP 10.71.2.224:139 10.71.2.178:3834 ESTABLISHED > TCP 10.71.2.224:2764 0.0.0.0:0 LISTENING > TCP 10.71.2.224:4531 10.42.2.17:1352 TIME_WAIT > TCP 10.71.2.224:4534 10.72.17.31:3418 ESTABLISHED > TCP 10.71.2.224:4536 10.72.17.31:3419 ESTABLISHED > TCP 127.0.0.1:3611 0.0.0.0:0 LISTENING > TCP 127.0.0.1:3611 127.0.0.1:3612 ESTABLISHED > TCP 127.0.0.1:3612 127.0.0.1:3611 ESTABLISHED > TCP 127.0.0.1:4403 127.0.0.1:8123 ESTABLISHED > TCP 127.0.0.1:8123 127.0.0.1:4403 ESTABLISHED]]>
My jboss-service.xml:
> > > > > resource:log4j.xml > true > > > > 127.0.0.1 > -1 > > > > > > > > > > 300 > jboss:service=XidFactory > > > > jboss:service=TransactionManager > > > > jboss:service=TransactionManager > > > > true > false > false > true > true > jboss:service=Transa ctionManager > > > > > > > jboss.system:service=MainDeployer > org.jboss.deployment.DeploymentSorter > org.jboss.deployment.scanner.DeploymentFilter > 5000 > > deploy/ > > True > > ]]>



0

I'm a bit curious as to how you actually do that... that is, how do you start JBoss in such a way that you can attach IDEA to it remotely?

If you could point me to any HOWTO on that I'd be happy to try it out and see if I have the same problem as you do.

0

Eugene, I'm starting JBoss standalone and later attaching IDEA via remote debugging. However, to do that I should start JBoss first, then start IDEA, otherwise IDEA will die when JBoss starts to deploy an application.

Stefan, to attach to JBoss remotely you just need to edit the JBoss startup scripts to include the remote debugging parameters. When creating a remote application configuration in IDEA, it will show you what parameters you need to add.

0

Thanks, I had already figured it out.

Everything works fine for me although I don't have all the options that IDEA specifies. Here's the thing that I use to start JBoss:

java -Djboss.home=/usr/local/java/jboss/current -classpath /usr/local/java/jboss/current/bin/run.jar -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=10250 org.jboss.Main

Here's what IDEA suggests:
-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=10250

So I'm not using the -Xnoagent and -Djava.compiler=NONE options. It's probably not that but still maybe worth a shot... anybody know what these options actually do?

Other things that might be of interest regarding why this works for me and not for you:

I'm using JBoss 3.2.1 w/Tomcat.
I'm running Linux.
I use JRE 1.4.1_05 to run IDEA (don't ask why...)
I use JRE 1.4.2_02 to run JBoss

0

I'm using IDEA's default JRE to run it (1.4.2) and 1.4.2_02 to run JBoss. I've tried all combinations of these two JRE (ie, run IDEA with 1.4.2_02, JBoss with 1.4.2, both with 1.4.2_02, both with 1.4.2) and the same thing keeps happening: IDEA dies when JBoss is starting.

And no, IDEA is not attached to JBoss when that happens. I just happen to have IDEA open when JBoss is starting. So sad >.<

0

And oh yes, I've also tried to start JBoss with no debug options at all. Same thing.

0

I'm still to find the real cause of this bug, but thankfully reverting to JBoss 3.2.0 makes me happy and dandy again.

0

And just for completeness, here's the hotspot error that's dumped when IDEA crashes:



I think that now I have enough information to open a SRC, and will be doing so.

0


I have the same problem with IDEA build 706 (on
1.4.1_02) and Windows 2000 SP4. When IDEA is
started and so is JBoss (running on 1.4.2_02), IDEA
crashes suddenly...

0

I used to have a similar problem running against JBoss. It seems to be related to the FileWatcher2K.DLL. Try removing/renaming the FileWatcher2K.DLL in the <IDEA-installation-directory>/bin directory and restarting IDEA. File synchronization will take longer, but the silent crashes should stop.

0

Please sign in to leave a comment.