|
View:
New views
4 Messages
—
Rating Filter:
Alert me
|
|
|
tomcat6 with netbeans6 will not workHello,
I found numerous posts about this problem, but none of the replies offered a real solution. I run NB 6.0.1 and a standalone tomcat6. It was easy to integrate tomcat into netbeans and start it from netbeans, but for some reason netbeans does not recognize that tomcat is running although tomcat is started which is clearly visibile from netbeans console: Apr 17, 2008 11:39:27 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 1041 ms Progress bar goes left and right and after a while message is displayed that tomcat failed to start. I use java 6 on winXP, firewall is turned off and I have no idea what else to try. There is no messages in the IDE log, only INFO [org.netbeans.modules.j2ee.deployment.impl.ServerInstance]: DebuggerInfo cannot be found for: Tomcat 6.0 The same problem occurs with NB6.1. I checked forums and issue tracker and this problem is known to be related with BFE service in Vista, but I run XP and haven't got BFE service at all. This is really annoying and I have a feeling that this problem is not taken seriously, so I wanted to debug myself (this must be something stupid) but got confused with the new mercurial repository. Has anybody got any idea? Please don't suggest to delete userdir, turn off this or install that. Tomcat integration worked for me before so IT HAS TO WORK now. I am sure that some message should be written to the log file but I don't know how to make NB log FINE messages. Anybody knows how to increase debug level for NB? If anybody from NB team reads this, please take this seriously or at least give me some hints how to debug this. Thank you! Dario |
|
|
Re: tomcat6 with netbeans6 will not workHi,
ndario wrote: > Hello, > > I found numerous posts about this problem, but none of the replies offered a > real solution. > > I run NB 6.0.1 and a standalone tomcat6. It was easy to integrate tomcat > into netbeans and start it from netbeans, but for some reason netbeans does > not recognize that tomcat is running although tomcat is started which is > clearly visibile from netbeans console: > > Apr 17, 2008 11:39:27 AM org.apache.catalina.startup.Catalina start > INFO: Server startup in 1041 ms > > Progress bar goes left and right and after a while message is displayed that > tomcat failed to start. I use java 6 on winXP, firewall is turned off and I > have no idea what else to try. There is no messages in the IDE log, only > > INFO [org.netbeans.modules.j2ee.deployment.impl.ServerInstance]: > DebuggerInfo cannot be found for: Tomcat 6.0 > > > The same problem occurs with NB6.1. > > I checked forums and issue tracker and this problem is known to be related > with BFE service in Vista, but I run XP and haven't got BFE service at all. > > This is really annoying and I have a feeling that this problem is not taken > seriously, so I wanted to debug myself (this must be something stupid) but > got confused with the new mercurial repository. > 1) install mercurial and ant (http://wiki.netbeans.org/HgHowTos#section-HgHowTos-InstallingMercurial) 2) invoke hg clone http://hg.netbeans.org/main 3) cd main 4) ant build-nozip 5) cd nbbuild/netbeans/bin 6) ./netbeans -J-Xdebug -J-Xrunjdwp:server=y,transport=dt_socket,address=7777,suspend=n 7) attach the debugger from your ide to port 7777 > Has anybody got any idea? Please don't suggest to delete userdir, turn off > this or install that. Tomcat integration worked for me before so IT HAS TO > WORK now. > Are you sure there no security software that could cause this? Can you connect to the tomcat with telnet? Did you install security updates? > I am sure that some message should be written to the log file but I don't > know how to make NB log FINE messages. Anybody kons how to increase debug > level for NB? > Use parameter -J-Dorg.netbeans.modules.tomcat5.level=0 > > If anybody from NB team reads this, please take this seriously or at least > give me some hints how to debug this. > This is taken seriously, OTOH tomcat detection works pretty well on any other platform as well on most windows instances. This issue very hard to reproduce. Because the code is the same for any OS there is real possibility that it is caused by some change in the system. You can also file an issue and we can share logs and other info there. > Thank you! > > Dario > > Thanks, P. > > > > > > |
|
|
Re: tomcat6 with netbeans6 will not workHi,
Petr, thanks for your suggestions, I debugged netbeans and found the problematic spot. It is in org.netbeans.modules.tomcat5.util.Utils.pingTomcat(...) method but it turned out that problem is not related to netbeans at all. In fact, it is reproducible from java program i created myself for testing. This method sends a request to tomcat and connection times out while waiting for response. It looks like this: String text = in.readLine(); it blocks then times out because response never comes in. That is why NB thinks tomcat is not working. I tried to telnet to tomcat and send the same request and got the response immediately, but using java sockets and streams just doesn't work. To make things even stranger, using URL class instead of Sockets, also works. I have no idea what may be wrong and will keep working on this. I hope I will have more information next week. |
|
|
Re: tomcat6 with netbeans6 will not workI am giving up, this is madness! It may be windows or java networking implementation but it just won't work. In fact I can't make simplest examples to work. I noticed that PrintStream works but PrintWriter doesn't (that is why URL class works) and I used that to "fix" tomcat plugin by replacing PrintWriter out = new PrintWriter(socket.getOutputStream(), true); with PrintStream out = new PrintStream(socket.getOutputStream(), true); in org/netbeans/modules/tomcat5/utis/Utils.java It works now, Tomcat start is detected but don't ask me why and how. I also don't know if there are other problems with this plugin when it tries to speak to tomcat. There is obviously different behavior from my computer at work (with latest win patches) and my comp at home (hasn't been updated quite a while). Simple networking examples run at home but not at work. I just guess that it may be related to windows patches. |
| Free Forum Powered by Nabble | Forum Help |