This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 255709 - Deploying to Tomcat sometimes fails with "No context exists" due to not giving enough time for startup
Summary: Deploying to Tomcat sometimes fails with "No context exists" due to not givin...
Status: NEW
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Tomcat (show other bugs)
Version: 8.2
Hardware: PC Mac OS X
: P3 normal (vote)
Assignee: Petr Hejl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-06 04:06 UTC by brettryan
Modified: 2019-07-10 16:31 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description brettryan 2015-10-06 04:06:44 UTC
In some cases deploying to the built in tomcat server (Apache Tomcat 8.0.26.0) results in an incorrectly detected FAIL.

Note that in the cases this has occurred that the Tomcat server is already running and I have performed a clean, then a run.

From the run log the following is produced:

    ------------------------------------------------------------------------
    BUILD SUCCESS
    ------------------------------------------------------------------------
    Total time: 11.442s
    Finished at: Tue Oct 06 12:51:06 AEDT 2015
    Final Memory: 57M/498M
    ------------------------------------------------------------------------
    NetBeans: Deploying on Apache Tomcat 8.0.26.0
        profile mode: false
        debug mode: false
        force redeploy: true
    In-place deployment at /Users/bryan/Development/unite/target/unite-2.4.0-SNAPSHOT
    Deployment is in progress...
    deploy?config=file%3A%2Fvar%2Ffolders%2Fgq%2Fq59yl8zj7h331__rv71l8jlc0000gn%2FT%2Fcontext8010628486644957462.xml&path=/unite
    OK - Deployed application at context path /unite
    Start is in progress...
    start?path=/unite
    FAIL - No context exists for path /unite

Note that the browser does appear with the "unknown context path" error from Tomcat, but this is prematurely appearing as in the past the browser would not appear when a failure was detected.

It seems that the context path check is too premature as checking the server log and waiting for the application to startup properly results in the app being available.



Steps to reproduce
------------------
* Note: This is intermittent and not always reproducible, in fact, I can only reproduce this using an existing project that is significantly large enough with a startup time of around 10 seconds. 

1. Open a sufficiently large enough web based maven project using a J2EE6 spec.
2. Run the project
3. Clean the project
4. Run the project


Expected outcome
----------------
IDE waits for deployment to succeed then opens browser.


Actual outcome
--------------
IDE will behave normally, but 3/10 tried from my attempts would try opening the browser too early and produce a fail in the deployment.

If you inspect the server output and then open the browser after deployment all would have deployed fine.
Comment 1 brettryan 2015-10-06 04:09:39 UTC
Product Version: NetBeans IDE Dev (Build 201509280002)
Java: 1.8.0_60; Java HotSpot(TM) 64-Bit Server VM 25.60-b23
Runtime: Java(TM) SE Runtime Environment 1.8.0_60-b27
System: Mac OS X version 10.11 running on x86_64; UTF-8; en_AU (nb)
User directory: /Users/bryan/Library/Application Support/NetBeans/dev
Cache directory: /Users/bryan/Library/Caches/NetBeans/dev


Further note. Am also getting lots of "Slowness detected" warnings of "non responsive 25 seconds" or so, sometimes minutes, usually when background scanning is running.
Comment 2 Petr Hejl 2015-10-06 14:39:25 UTC
It's a bit problem to reproduce this one. Can you share the project for testing? BTW I guess it is actually the start command which fails so there is either problem in NB or Tomcat reporting app has been deployed too early and the start command fails consequently.
Comment 3 sunnyydv12 2019-07-10 16:31:55 UTC
I am also play this game https://getrobloxfreerobux.com i really like this new version mini puzzle game.