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 226630

Summary: Server startup not detected if non English language setting
Product: serverplugins Reporter: TFruehbeck <tfruehbeck>
Component: JBossAssignee: Petr Hejl <phejl>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P3    
Version: 7.1   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:
Attachments: proposed patch for pattern detection of startup message

Description TFruehbeck 2013-02-25 09:08:51 UTC
Created attachment 131817 [details]
proposed patch for pattern detection of startup message

Server startup message is nationalized. For German it reads differently, message will not be recognized:

in German it reads:
JBoss AS 7.1.3.Final "Arges" wurde gestartet in 4212ms - 136 von 217 Diensten gestartet 

A pattern is better suited for the task:

 Pattern jboss7Started = Pattern.compile("JBoss AS 7\\..*? \"[^\"]*\"");
 ...
 jboss7Started.matcher(line).find()

proposed Patch attached.

Reference:
http://netbeans.org/bugzilla/show_bug.cgi?id=200132
Comment 1 Petr Hejl 2013-06-19 12:46:04 UTC
Fixed in web-main c6d89869d799. Please verify.
Comment 2 Quality Engineering 2013-06-21 02:30:07 UTC
Integrated into 'main-golden', will be available in build *201306202301* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/c6d89869d799
User: Petr Hejl <phejl@netbeans.org>
Log: #226630 - Server startup not detected if non English language setting
Comment 3 TFruehbeck 2013-06-22 14:00:48 UTC
sorry to say, no.

instead of using my proposed Matcher.find() you used Matcher.matches() - a big difference in this case. 

The whole line would be: 
15:44:37,254 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015874: JBoss AS 7.1.3.Final "Arges" wurde gestartet in 3241ms - 139 von 221 Diensten gestartet (80 Services sind Passiv oder werden bei Bedarf geladen)

which means: 
 - either use Pattern.compile(".*JBoss AS 7(\\..*)* \\d+ms .*")
 - or Matcher.find()

"JBOSS_7_STARTED_ML.matcher(line).matches()" is confirmed to work.

Thomas
Comment 4 Petr Hejl 2013-07-18 10:18:14 UTC
Should be fixed now - web-main f246ab282d58.
Comment 5 Quality Engineering 2013-07-19 02:31:41 UTC
Integrated into 'main-silver', will be available in build *201307182300* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/f246ab282d58
User: Petr Hejl <phejl@netbeans.org>
Log: #226630 - Server startup not detected if non English language setting