MySource Matrix Resources

MySource Matrix has been superseded by Squiz Matrix. This site will remain available for archival purposes only; it is not intended as a current source of Matrix information. For all the latest on Matrix, including documentation and release information, visit the Squiz Matrix site.

Main Content

Upgrading MySource Matrix from v3.26 to v3.28

Introduction

This guide will help you upgrade an existing MySource Matrix version 3.26 installation to version 3.28.

This upgrade requires you to have access to:

  • update the MySource Matrix source code
  • run database queries on the MySource Matrix database
  • edit the MySource Matrix configuration files

This guide assumes that your MySource Matrix installation is located at /home/websites/mysource_matrix. Please change any commands to the appropriate location if your installation is located elsewhere.

This upgrade guide is based upon upgrading from the stable version just before the first 3.28 stable release - that is, from version 3.26.4 to 3.28.0. For upgrading earlier versions of Matrix, it is recommended that you upgrade to at least version 3.26.4 before upgrading to 3.28.0.

This upgrade guide assumes that the server requirements will be upgraded in-place, meaning the MySource Matrix system will remain in the same location.

Major version upgrades require you to delete all previous rollback data from your system. Rollback data is incompatible between major versions.

Ensure that you have a current backup of your existing system and rollback data before upgrading.

Stop Editing

No editing should be taking place during a major version upgrade. Before starting the upgrade, first ensure that all editors are logged out of the system.

System administrators can see if there are any active locks on content in the system by clicking on the Automated Patching System icon at the top of the screen, then switching to the Active Locks screen.

Backup

Before starting any upgrade, always backup your MySource Matrix installation. See the MySource Matrix backup management guide for information on how to backup your MySource Matrix system.

Delete Stale HIPO Jobs

During a major version upgrade, stale HIPO jobs should be removed from the system. Log into the MySource Matrix administration interface as root user and go to the HIPO Herder screen. Lock this screen and delete all HIPO jobs that are listed. Note that there may not be any stale HIPO jobs in the system.

Disable Search Indexing

You will need to disable searching from the Search Manager before you undertake this upgrade.

Disable Rollback

At this point, you need to ensure that rollback is disabled before continuing. For help with disabling rollback, see the MySource Matrix rollback management guide.

Disable Cron Run script in Crontab

If you use the Cron system, you will have set up an entry in a Crontab file. It is most likely that it would have been set up for the user Apache runs as, however this depends on your system configuration.

As the user the Crontab entry was installed to, run the following command:

$ crontab -e

Find the entry for Matrix, and add a hash ("#") to the front of the entry to comment it out:

# */15 * * * * php /home/websites/mysource_matrix/core/cron/run.php /home/websites/mysource_matrix

Get the New Source Code

Now, you need to update the MySource Matrix source code. You can find out how to download the latest stable version of MySource Matrix on the installation page.

Once you have downloaded the source code, you need to replace the existing code with the newer version. This will not reset any configuration options or remove any content from your system.

These steps assume MySource Matrix is installed at /home/websites/mysource_matrix and that a tar.gz archive with the new source code exists within /home/websites
$ cd /home/websites
$ mv mysource_matrix mysource_matrix_3-26-x
$ tar -xzvf new_source.tar.gz
$ cd mysource_matrix
$ cp -pr /home/websites/mysource_matrix_3-26-x/data .
$ cp -pr /home/websites/mysource_matrix_3-26-x/core/lib/DAL/Oven core/lib/DAL
$ cp -pr /home/websites/mysource_matrix_3-26-x/core/lib/DAL/QueryStore core/lib/DAL

Differentiate Between Matrix Remaps And Custom Remaps

A new table column must be added to the Matrix database in order to support this new functionality. Queries are PostGres and Oracle-compatible. Please run the following queries and steps on existing systems:

ALTER TABLE sq_ast_lookup_remap ADD auto_remap CHAR(1);
ALTER TABLE sq_rb_ast_lookup_remap ADD auto_remap CHAR(1);
If rollback is disabled, this is the end of the additional steps. If rollback is enabled, the database trigger on the rollback table needs to be re-created due to the new field. Please also execute the following query:
DROP TRIGGER sq_ast_lookup_remap_rb_trg ON sq_ast_lookup_remap;

Trigger Action To Update Twitter Status

The Set Twitter Status Trigger Action which was added to this release requires the I18N_UnicodeNormalizer PEAR package, version 1.0.0 to be installed.

$ pear install I18N_UnicodeNormalizer

Full System Upgrade

Now, the system's installation scripts should be run to ensure the asset types and language translations are up to date.

$ php install/step_02.php /home/websites/mysource_matrix

From Matrix 3.28.x all packages are now under the GPL licence. The licence key structure has been moved from licence.inc to main.inc. Please verify that the licence and warranty keys are safely in main.inc, then the data/private/conf/licence.inc file can be safely deleted.

$ rm data/private/conf/licence.inc
$ php install/compile_locale.php /home/websites/mysource_matrix
$ php install/step_03.php /home/websites/mysource_matrix
$ php install/compile_locale.php /home/websites/mysource_matrix

JS API ENHANCEMENTS: Configurable Number Of Asset Levels In Call To getParents()

Implementations of the JS API which make calls to getParents() may need to be re-assessed, as this function now returns all parent asset levels by default, whereas this previously only returned one level. In order to retain a resultset which includes a single level only, calls to getParents() should be adjusted to pass "1" as the argument for the number of levels. For example:

// [asset_id], [num_levels], [callback_fn]
getParents(123, 1, resultGetParents);

JS API ENHANCEMENTS: Update And Trash Multiple Asset Links, Get Child Count Functionality

As part of this development, the function signature for the updateLink() was modified to take another argument for link locking. Due to this change, implementations using this function may have to be re-assessed. In order to maintain existing functionality without affecting link locks, an empty string should be used for the "locked" value. For example... Old call:

// [parent_id], [child_id], [link_type], [link_value], [sort_order], [callback])
updateLink(123, 124, 1, 'test', 1, linkCallback);
New equivalent call (no manipulation of link locks):

// [parent_id], [child_id], [link_type], [link_value], [sort_order], [locked], [callback])
updateLink(123, 124, 1, 'test', 1,  '', linkCallback);

Additional features for SOAP APIs

A number of SOAP API functions have been added to the web services package. Due to this change, you have to regenerate SOAP WSDL. This can be done in the details screen of SOAP server.

Reset Rollback

Only run this step if your system has rollback enabled. If your system does not use rollback, you can safely skip this step.

Rollback entries should be reset between major versions. For instructions on how to reset rollback, see the MySource Matrix rollback management guide.

Re-enable Cron Run script in Crontab

You can now re-enable your MySource Matrix system's entry in the Crontab in the reverse manner as you did to disable it: by editing the Crontab file and removing the comment (#) from the front of the entry.

Re-enable Rollback

If you needed to disable rollback at the beginning of this upgrade, you may now re-enable it. For help with enabling rollback, see the MySource Matrix rollback management guide.

Re-enable Search Indexing

You can now re-enable indexing of your system. This can be done from the Search Manager.

Upgrade Complete

The upgrade of your MySource Matrix system from version 3.26 to 3.28 is now complete.