Bug 780737 (SOA-3190)

Summary: Quickstarts fail to compile or deploy depending on existence of /server/default directory
Product: [JBoss] JBoss Enterprise SOA Platform 5 Reporter: Pavel Macik <pmacik>
Component: Tooling, ExamplesAssignee: tcunning
Status: CLOSED NEXTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 5.2.0 ER1CC: kevin.conner, pmacik, tcunning
Target Milestone: ---   
Target Release: 5.2.0 GA, 5.2.0.ER2   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/SOA-3190
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-10-07 08:32:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
SOA-3190.patch
none
base-build.xml.diff none

Description Pavel Macik 2011-07-20 12:04:53 UTC
Workaround: Workaround Exists
Workaround Description: Create ${SOA-P}/jboss-as/server/default directory if doesn't exist.
project_key: SOA

When one tries to deploy (ant deploy) any quickstart the QS/conf/base-build.xml among other thins checks for existence of /server/default directory... if the directory doesn't exist, the ant execution fails.

If anyone removes or renames (that is presumable) the default profile he would not be able to run the quickstarts ant at all...

To reproduce:
1) unzip SOA-P 
2) move/rename ${SOA-P}/jboss-as/server/default to ${SOA-P}/jboss-as/server/<anything-else>
3) from ${SOA-P}/jboss-as/samles/quickstarts/helloworld run 'ant deploy':

$ ant deploy
Buildfile: build.xml

BUILD FAILED
/SOA-P/jboss-as/samples/quickstarts/helloworld/build.xml:9: The following error occurred while executing this line:
/SOA-P/jboss-as/samples/quickstarts/conf/base-build.xml:57: Cannot determine build hierarchy

Total time: 0 seconds

Comment 1 Pavel Macik 2011-07-20 12:10:26 UTC
Workaround Description: Added: Create ${SOA-P}/jboss-as/server/default directory if doesn't exist.
Workaround: Added: [Workaround Exists]


Comment 2 tcunning 2011-07-20 12:31:27 UTC
You should be able to delete the default directory and successfully deploy/run if you create a conf/quickstarts.properties and configure the org.jboss.esb.server.home org.jboss.esb.server.config properties.      I just tried it successfully on 5.1.0.GA.

I believe this is documented, but if it is not, it should be.

Comment 3 Pavel Macik 2011-07-20 14:00:37 UTC
Right...
But with SOA-P 5.2.0.ER1 it doesn't work...
I have those 2 properties set in the /quickstarts/conf/quickstarts.properties file

org.jboss.esb.server.home=${SOA-P}/jboss-as
org.jboss.esb.server.config=production

and it behave as described.

Comment 4 tcunning 2011-07-20 14:13:20 UTC
Taking a look at this now.

Comment 5 tcunning 2011-07-20 15:54:35 UTC
Link: Added: This issue relates to JBESB-3639


Comment 6 tcunning 2011-07-20 20:09:17 UTC
Fixed here :

------------------------------------------------------------------------
r37277 | tcunning | 2011-07-20 15:53:00 -0400 (Wed, 20 Jul 2011) | 4 lines

JBESB-3639
Search for copyright.txt which exists within SOA-P, rather than
Contributors.txt.


Comment 7 Julian Coleman 2011-08-05 10:27:08 UTC
Trying to deploy a quickstart now results in:

  /tmp/SOA/jboss-soa-p-standalone-5/jboss-esb/samples/quickstarts/conf/base-build.xml:361: Cannot determine target deployment, please check quickstarts.properties or deployment.properties

This is because the tests for hierarchy.jbossesb* are now:

  <available file="${product.dir}/server/${org.jboss.esb.server.config}"/>

but ${org.jboss.esb.server.config} has not been set at this
point.

Comment 8 Julian Coleman 2011-08-05 10:30:42 UTC
Attached patch (SOA-3190.patch) contains proposed fix:

  move processing of the home and config properties (from the quickstarts properties file) to earlier
  uncomment configuration from example properties file
  remove test mentioning that "default" is the default

Comment 9 Julian Coleman 2011-08-05 10:30:43 UTC
Attachment: Added: SOA-3190.patch


Comment 10 Kevin Conner 2011-08-05 18:27:36 UTC
The previous patch won't work in all circumstances so shouldn't be applied.  I'll take a quick look and suggest an alternative.

Comment 11 Kevin Conner 2011-08-05 19:17:16 UTC
This patch should allow the hierarchy tests to take note of the quickstart config, while still allowing the installation override and a default of "default"

Comment 12 Kevin Conner 2011-08-05 19:17:16 UTC
Attachment: Added: base-build.xml.diff


Comment 13 Kevin Conner 2011-08-05 19:19:12 UTC
I should add that there is no need to update the quickstart.properties-example

Comment 14 Anne-Louise Tangring 2011-08-08 15:50:02 UTC
Coordinate with Julian.

Comment 15 tcunning 2011-08-09 17:10:22 UTC
Committed Kevin's fixed (attached, base-build.xml diff).

Comment 16 David Le Sage 2011-08-26 05:23:22 UTC
Release Notes Docs Status: Added: Not Required
Writer: Added: dlesage


Comment 17 Pavel Macik 2011-10-07 08:32:22 UTC
Verified in 520ER4