JBoss Enterprise Portal Platform provides an integrated open source platform for hosting and serving a portal's web interface, aggregating, publishing, and managing its content, and personalizing its experience.
Product Component | OS Type | Versioning | Pattern Depth |
---|---|---|---|
JBossPortal | Windows, UNIX | File, Path | Instance-based |
The pattern supports both the Windows and UNIX platforms.
Pattern | Trigger Node | Attribute | Condition | Argument |
---|---|---|---|---|
JBossPortal | DiscoveredProcess | cmd | matches | regex '\bjava(?:\.exe)?$' |
args | matches | regex 'org\.jboss\.Main' |
The trigger is the same trigger as Red Hat JBoss Application Server. To ensure the pattern only generated on a JBoss Portal instance the following additional checking as carried out before an SI is created.
The pattern first parses the trigger process arguments to pull out the classpath using the following regular expressions:
If the classpath is within quotes (contains spaces in the paths): (?i)-(?:cp|classpath)\s+"(.+?)"
If the classpath is not within quotes: (?i)-(?:cp|classpath)\s+(\S+)\s
If the classpath is within quotes (contains spaces in the paths): -(?:cp|classpath)\s+"(.+?)"
If the classpath is not within quotes: -(?:cp|classpath)\s+(\S+)\s
The classpath has also the path separator characters normalized for the platform type
The pattern then parses the classpath section by section (sections are separated by ':' on UNIX platforms and ';' on the Windows platform) to obtain the installation path using the following regular expressions:
Windows: (?i)^(\w:\\.+?)\\bin\\run\.jar
UNIX: ^(/\S+?)/bin/run\.jar
If the installation path is not obtained the pattern will stop.
If the installation path is found the pattern continues onto the second test to verify the presence of JBoss Portal.
The pattern checks for the existence of a file <installation_path>/server/default/deploy/jboss-portal.sar/portal-aop.xml. If it cannot find this file it assumes it is not looking at a JBoss Portal instance so exits without creating an SI
The pattern in this module will set the following attribute:
Pattern Name | SI Type |
---|---|
JBossPortal | Red Hat JBoss Portal |
Versioning is attempted using file and path versioning.
The pattern has already obtained details of the base directory when checking for false positives
For file versioning, the pattern looks at the following file
The pattern then extracts the version information from the file using the following regular expression
The pattern has already obtained details of the base directory when checking for false positives
If file versioning is unsuccessful the pattern attempts path versioning. It does this by parsing the base directory using the following regular expression:
The JBossPortal pattern triggers on the JBoss Application Server (java or java.exe with 'org.jboss.Main' in its arguments) process.
If a server is identified, the JBossPortal pattern creates an instance-based Software Instance, its key being based on server name, installation_path, type (i.e. Red Hat JBoss Portal) and host key.
If no server is identified, the JBossPortal pattern creates a grouped instance-based Software Instance, its key being based on the installation path
If a server name has been identified, a dependency relationship is created between the Portal SI and the Application Server SI that share this server name.
The Application Server SI is identified by using the following query:
Subject Matter Expert input will be welcome on any other potential approaches not discussed to improving product versioning coverage and depth of Red Hat JBoss Portal.
Testing was performed against a live installation of JBoss Portal on both Windows and Linux
There are no known open issues with this pattern.
Created by: Chris Blake 25 Sep 2008
Updated by: Nikola Vukovljak 22 Jan 2013