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 191810 - Logging hangs when using Logback
Summary: Logging hangs when using Logback
Status: RESOLVED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: WebLogic (show other bugs)
Version: 8.0.2
Hardware: PC Windows 7 x64
: P3 normal with 3 votes (vote)
Assignee: Petr Hejl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-10 16:37 UTC by ron.koerner
Modified: 2015-03-03 15:41 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 ron.koerner 2010-11-10 16:37:39 UTC
There seems to be a problem when using Netbeans, Tomcat and logback in conjunction.

As soon as an exception is thrown in a webapp running in Tomcat under Netbeans, the logging hangs before printing the stacktrace.

For me the webapp still works, but does no more logging until Tomcat is restarted. Other people reported Tomcat hanging as well.

See http://jira.qos.ch/browse/LBCLASSIC-212 for a related logback issue.

My tests have shown, that using
- logback with Netbeans without Tomcat
- logback with Tomcat without Netbeans
- Netbeans with Tomcat without logback
- Netbeans with Tomcat with logback without logback enhanced stacktraces
all work fine.

Therefore I assume the problem lies with Netbeans' logging parser and I also assume that there are different parsers for Tomcat and standalone applications since standalone applications can handle the enhanced stacktraces.

The difference between a normal and enhanced stacktrace is:

(normal)
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
        at java.lang.String.substring(String.java:1949)

(enhanced)
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
        at java.lang.String.substring(String.java:1949) ~[na:1.6.0_18]
Comment 1 Petr Hejl 2011-10-14 08:37:40 UTC
Could you please also provide thread dump of NetBeans in situation when the log is not printed anymore?
Comment 2 Petr Hejl 2011-10-14 09:15:25 UTC
Should be fixed in web-main ab06eadf62b8. Please verify in dev build once integration message appears in the issue.
Comment 3 Quality Engineering 2011-10-15 14:44:00 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/ab06eadf62b8
User: Petr Hejl <phejl@netbeans.org>
Log: #191810 Logging hangs when using Logback with Tomcat
Comment 4 patrick2 2013-08-29 14:30:43 UTC
I have the exact same issue with the Oracle Weblogic Server Output.
Comment 5 sjonsson 2014-06-05 14:46:25 UTC
I have the same issue happening in Weblogic Server (11g and 12c).  Logback stops logging to the Server Output window upon the first error.  Any known workarounds?
Comment 6 Petr Hejl 2014-09-26 08:45:51 UTC
Fixed in in jet-main branch server_split 74697e976778.
Comment 7 Quality Engineering 2014-10-18 05:10:44 UTC
Integrated into 'main-silver', will be available in build *201410180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/74697e976778
User: Petr Hejl <phejl@netbeans.org>
Log: #191810 - Logging hangs when using Logback
Comment 8 sjonsson 2015-03-03 15:37:40 UTC
Has this fix made its way into Netbeans 8.0.2?  If so, then it does not fix the issue.  Logback logging to the Netbeans output console (WebLogic 12c) stops as soon as the first exception gets logged.

This is very frustrating.  Any known workarounds?

Product Version: NetBeans IDE 8.0.2 (Build 201411181905)
Java: 1.7.0_60; Java HotSpot(TM) 64-Bit Server VM 24.60-b09
Runtime: Java(TM) SE Runtime Environment 1.7.0_60-b19
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
App Server: WebLogic 12c
Comment 9 Petr Hejl 2015-03-03 15:41:50 UTC
As the target milestone suggest it will be part of the next release not 8.0.2. Until than you may try the daily build.