Appdev component fails to start while upgrading TIBCO ActiveMatrix BPM 4.x.x to 4.3.0

Appdev component fails to start while upgrading TIBCO ActiveMatrix BPM 4.x.x to 4.3.0

book

Article ID: KB0074718

calendar_today

Updated On:

Products Versions
TIBCO BPM Enterprise (formerly TIBCO ActiveMatrix BPM) 4.0.0, 4.1.0, 4.2.0, 4.3.0

Description

TIBCO ActiveMatrix BPM 4.x.x to 4.3.0 upgrade fails as appdev component fails to start. This failure occurs after the system AMX BPM application, commonly known as amx.bpm.app, has been upgraded. 

Symptoms: 

All of the below symptoms will occur - 

1. TIBCO Configuration Tool (TCT) gets the following error while upgrading BPM - 

  [echo] ================================================================= [echo] Task: Starting AMX BPM Application on BPM Node [echo] ================================================================= [echo] 28 Aug 2019 07:51:54 INFO - Executing action 'start' for 1 objects from data file '/opt/tibco/bpm_config_home/tibco/data/bpm/amx.bpm.app/deployment/integration_upgrade.xml' 28 Aug 2019 07:51:54 INFO - Starting Applications... . . 28 Aug 2019 08:08:52 ERROR - Application Start failed 28 Aug 2019 08:08:52 ERROR - TIBCO-AMX-CLI-000343: Start component 'apps' on node 'BPMNode' failed : java.lang.IllegalArgumentException: Exception during web application initialization. Deployment of web application failed 28 Aug 2019 08:08:52 ERROR - java.lang.IllegalArgumentException: Exception during web application initialization. Deployment of web application failed com.tibco.amf.runtime.implementationtype.webapp.WebAppImplementationAdapter.initImplementation(WebAppImplementationAdapter.java:242) . . caused by: javax.resource.ResourceException: TIBCO-AMX-HPA-014303: Failed to add context . . caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'roleRestService': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.tibco.cap.roles.services.impl.RoleServiceImpl com.tibco.cap.roles.rest.RoleRestService.roleService; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'repositoryComponent' defined in class path resource [app-repo-beans.xml]: Invocation of init method failed; nested exception is javax.jcr.RepositoryException: Cannot connect to the jcr/db..
2. BPM Node logs will have the following exception - 

28 Aug 2019 07:59:50,905 [ComponentFrameworkDelegate] [ERROR] com.tibco.repo.api.util.RepoContext - getCurrentSession() RepositoryException
javax.jcr.RepositoryException: Invalid repository configuration: {}
at org.apache.jackrabbit.core.TransientRepository$3.getRepository(TransientRepository.java:257)
at org.apache.jackrabbit.core.TransientRepository.startRepository(TransientRepository.java:280)
.
.
Caused by: org.apache.jackrabbit.core.config.ConfigurationException: Could not load JDBC driver class oracle.jdbc.driver.OracleDriver
at org.apache.jackrabbit.core.config.DataSourceConfig$DataSourceDefinition.isJndiConfig(DataSourceConfig.java:164)
at org.apache.jackrabbit.core.config.DataSourceConfig$DataSourceDefinition.verify(DataSourceConfig.java:146)
.
.
Caused by: java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)


3. TCT logs also indicate the newer version of repository.xml couldn't be extracted - 

 
-ext-oracle-repo-xml:
   [rename] DEPRECATED - The rename task is deprecated.  Use move instead.
Cannot rename nonexistent file /opt/tibco/bpm_config_home/tibco/data/bpm/amx.bpm.app/appdev/repository.xml_ORA

4. The newly introduced appdev.properties is not copied into the BPM configuration folder (n2.config.location). 

Cause: 

Upgrade scripts are not able to extract the new appdev configuration files

 

Issue/Introduction

TIBCO ActiveMatrix BPM 4.x.x to 4.3.0 upgrade fails as appdev component fails to start

Environment

ALL

Resolution

This issue has been fixed in 4.3.0 HF 1. When upgrading to 4.3.0 HF 1 or higher from a pre-4.3.0 version, below workaround is not required. 

Workaround: 

Note: If the issue has already occurred, please revert back to a pre-upgrade restore point. 

The following steps, when performed prior to the upgrade, will help avoid this issue. Please note each step contains an example, which may not exactly match with your environment.  

1. Copy the latest appdev war (appdev-war-1.3.0-SNAPSHOT.war) into each of the appdev directories - 

$ cd $TIBCO_HOME/components/shared/1.0.0/plugins  
$ for d in com.tibco.amxbpm.fullnode* ; do cp "./com.tibco.amxbpm.fullnode_1.12.1.026/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war" "$d/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/"
> done

cp: ‘./com.tibco.amxbpm.fullnode_1.12.1.026/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war’ and ‘com.tibco.amxbpm.fullnode_1.12.1.026/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war’ are the same file

2. Verify the new war file now exists under each of the com.tibco.amxbpm.fullnode_* directory - 

$ cd $TIBCO_HOME/components/shared/1.0.0/plugins    
$ find ./ -name appdev-war-*-SNAPSHOT.war  
./com.tibco.amxbpm.fullnode_1.9.0.048/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war
./com.tibco.amxbpm.fullnode_1.9.1.010/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.0.1-SNAPSHOT.war
./com.tibco.amxbpm.fullnode_1.9.1.010/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war
./com.tibco.amxbpm.fullnode_1.9.2.003/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.0.2-SNAPSHOT.war
./com.tibco.amxbpm.fullnode_1.9.2.003/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war
./com.tibco.amxbpm.fullnode_1.12.1.026/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war


3. Execute the upgrade

4. After the upgrade, delete the latest appdev war except under the latest amx.bpm.app template directory - com.tibco.amxbpm.fullnode_1.12.1.026 (refer output from step #2)

$ cd $TIBCO_HOME/components/shared/1.0.0/plugins    
$ rm ./com.tibco.amxbpm.fullnode_1.9.0.048/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war
$ rm ./com.tibco.amxbpm.fullnode_1.9.1.010/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war
$ rm ./com.tibco.amxbpm.fullnode_1.9.2.003/com.tibco.daa/com.tibco.appdev.studio/Deployment Artifacts/appdev-war-1.3.0-SNAPSHOT.war

Additional Information

Internal defect id - WRM-11653