Bug 1072845 - [QE] (6.2.x) Domain mode service script uses wrong string to verify if JBoss started
Summary: [QE] (6.2.x) Domain mode service script uses wrong string to verify if JBoss ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Scripts and Commands
Version: 6.2.0
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: CR2
: EAP 6.2.3
Assignee: Ivo Studensky
QA Contact: Petr Kremensky
Russell Dickenson
URL:
Whiteboard:
Depends On: 1020677
Blocks: eap62-cp03-blockers
TreeView+ depends on / blocked
 
Reported: 2014-03-05 09:43 UTC by Petr Kremensky
Modified: 2014-06-09 12:48 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 1020677
Environment:
Last Closed: 2014-06-09 12:48:03 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Petr Kremensky 2014-03-05 09:43:00 UTC
+++ This bug was initially created as a clone of Bug #1020677 +++

Description of problem:
JBoss EAP 6.2.0 script uses "JBoss AS.*started in" string to verify if the JBoss started. It should be JBAS015874. Thus, it will work for different languages (and with EAP). 
Currently the service start() will success even if no "started in" message is found.
from JBoss EAP 6.2.0 jboss-as-domain.sh script:
start() {
...
  count=0
  launched=false

  until [ $count -gt $STARTUP_WAIT ]
  do
    grep 'JBoss AS.*started in' $JBOSS_CONSOLE_LOG > /dev/null
    if [ $? -eq 0 ] ; then
      launched=true
      break
    fi
    sleep 1
    let count=$count+1;
  done

  success
  echo
  return 0
}

Version-Release number of selected component (if applicable):
EAP 6.2.0.ER6

started log:
[Host Controller] 08:13:44,258 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015874: JBoss EAP 6.2.0.GA (AS 7.3.0.Final-redhat-9) (Host Controller) started in 8766ms - Started 12 of 12 services (0 services are passive or on-demand)

Additional info:
Keep in mind that greping just JBAS015874 will return success once domain-controller is up, this doesn't mean that whole domain is up.
Original issue BZ1015237

--- Additional comment from Permaine Cheung on 2013-10-18 08:48:32 EDT ---

Jason, please reassign accordingly.

When this is fixed in Wildfly, we'll need to merge the fix into the EAP branch.

--- Additional comment from Petr Kremensky on 2014-02-17 08:11:25 EST ---

This is same with jboss-as-standalone.sh script. Launched variable is ignored and script return success even if server failed to start once the timeout expires.

{ ...
  count=0
  launched=false

  until [ $count -gt $STARTUP_WAIT ]
  do
    grep 'JBAS015874:' $JBOSS_CONSOLE_LOG > /dev/null
    if [ $? -eq 0 ] ; then
      launched=true
      break
    fi
    sleep 1
    let count=$count+1;
  done

  success
  echo
  return 0
}

Comment 1 Scott Mumford 2014-03-10 01:46:20 UTC
Does this ticket require an entry in the 6.2.2 Release Notes?

I don't see a 'bug' here, per se, this seems more like an enhancement than a bug fix.

Comment 2 Permaine Cheung 2014-03-17 16:19:29 UTC
This needs to be fixed upstream then merged back into EAP, however, it hasn't been fixed for 6.2.2.
I agree that this is an enhancement.

Comment 3 Permaine Cheung 2014-03-17 16:46:58 UTC
Jason, can you please reassign? I'm not sure who works on the script upstream. Thanks!

Comment 4 Scott Mumford 2014-03-17 21:14:59 UTC
Thanks Permaine

Comment 5 Ivo Studensky 2014-04-08 08:49:42 UTC
PR sent:
https://github.com/jbossas/jboss-eap/pull/1200

Comment 6 Petr Kremensky 2014-05-09 06:39:44 UTC
Verified on EAP 6.2.3.CR2.


Note You need to log in before you can comment on or make changes to this bug.