Upgrading your installation

After you install IBM TRIRIGA Application Suite, you can upgrade your installation to the latest version by planning your upgrade according to the checklist and then performing the installation.

Important: Prior to upgrading IBM TRIRIGA Application Suite Operator, it is recommended that you switch the subscription update approval strategy to Manual. Doing so enables you to take necessary steps to backup the database and any configuration files, and schedule necessary downtime for the upgrade.

For more information and steps to compete this task, see Changing the TRIRIGA Application Suite update approval strategy.

Data recovery and backups

Before starting the upgrade process, create a data recovery plan to be used in the event of an IBM TRIRIGA Application Suite system failure. IBM TRIRIGA is a Java enterprise application that runs on a variety of database platforms. Each database platform provides different methods and recommendations for backups and recovery. Consult the product information provided with the database platform you are using with IBM TRIRIGA Application Suite for backup and recovery operation standards and best practices.

The IBM TRIRIGA database must be backed up before you begin any upgrade. Stage all upgrades in a test environment and complete thorough reviews before you upgrade any production environment.

Operator upgrade

Important: Prior to upgrading IBM TRIRIGA Application Suite Operator, ensure that you schedule the necessary downtime, lock the system, and make backups of your database.

Catalog Source image change

Changing the CatalogSource is required only if you are installing from a dedicated TAS CatalogSource for testing purposes. If you are installing the TAS operator from the IBM operator catalog, the catalog image will automatically be refreshed once it is available and the subscription will be marked as updatable.

To do so from the OpenShift Container Platform web console:
  1. Log in to the OpenShift Container Platform web console.
  2. Go to Operators > Installed Operators.
  3. Click the IBM TRIRIGA Application Suite installed operator.
  4. Click the Subscription tab. Then, under Catalog Source, click tas-catalogsource.
  5. Go to the YAML tab and update the spec.image value to icr.io/cpopen/ibm-tas-catalog:1.0.1.
Or, to do so from the OpenShift CLI:

```bash
cat <<EOF | oc apply -f -
apiVersion: operators.coreos.com/v1alpha1
kind: CatalogSource
metadata:
  name: tas-catalogsource
  namespace: openshift-marketplace
spec:
  displayName: TAS Operators
  image: 'icr.io/cpopen/ibm-tas-catalog:1.0.1'
  publisher: IBM
  sourceType: grpc
  updateStrategy:
    registryPoll:
      interval: 5m
EOF
```

After you make this change, during the next registry poll, a new version of IBM TRIRIGA Application Suite Operator will be pulled and you will see an option to upgrade on the Operator Details Subscription tab.

To apply the available updates:
  1. Go to Operators > Installed Operators.
  2. Click the IBM TRIRIGA Application Suite installed operator.
  3. Click the Subscription tab. Then, under Upgrade Status, click Upgrade available.
  4. Click Preview Install Plan. Then, click Approve.
  5. Click the channel version and select the higher version of the channel to receive updates.
  6. Click Preview Install Plan. Then, click Approve.

At this point, the IBM TRIRIGA Application Suite Operator will upgrade itself and proceed to upgrade and restart all TRIRIGA instances. To monitor the progress, view the logs of the tririga-controller-manager pod.

Operator rollback

In the event that you require rollback, complete these steps to roll back to a previous version of IBM TRIRIGA Application Suite:
  1. Log in to the OpenShift Container Platform web console.
  2. Go to Operators > Installed Operators.
  3. Uninstall the IBM TRIRIGA Application Suite installed operator.
  4. Go to Workloads > Deployments.
  5. Delete the TRIRIGA instance Kubernetes deployment objects. By deleting deployments, you delete TRIRIGA pods and all connections to the database, making it possible to restore the database. Note that deleting the tririga-contoller-manager or ibm-truststore-mgr-controller-manager objects is not required.
    Important: Do not delete TRIRIGA CRs. Only delete TRIRIGA K8S deployment objects. If you delete TRIRIGA CRs, all configurations will be lost.
  6. Update the catalog source to point to the previous image. If you are using IBM operator catalog, you must create a dedicated TAS Operator catalog source pointing to the icr.io/cpopen/ibm-tas-catalog:1.0.0 image.
    
    ```bash
    cat <<EOF | oc create -f -
    apiVersion: operators.coreos.com/v1alpha1
    kind: CatalogSource
    metadata:
      name: tas-catalogsource
      namespace: openshift-marketplace
    spec:
      displayName: TAS Operators
      image: 'icr.io/cpopen/ibm-tas-catalog:1.0.0'
      publisher: IBM
      sourceType: grpc
      updateStrategy:
        registryPoll:
          interval: 5m
    EOF
    ```
    
  7. Restore the backup of the TRIRIGA database.
  8. Reinstall the previous version of the IBM TRIRIGA Application Suite Operator into the same namespace using a dedicated CatalogSource pointing to the icr.io/cpopen/ibm-tas-catalog:1.0.0 catalog image.

After you reinstall a previous operator, new Kubernetes deployment objects are created and TRIRIGA pods startup.