Using a AWS CloudFormation template to update the engine version of your Neptune DB Cluster - Amazon Neptune

Using a AWS CloudFormation template to update the engine version of your Neptune DB Cluster

You can re-use the Neptune AWS CloudFormation template that you used to create your Neptune DB Cluster to update its engine version.

Neptune engine version upgrades can be minor or major. Using an AWS CloudFormation template can help with major version upgrades, which often contain significant changes. Since major version upgrades can contain database changes that are not backward-compatible with existing applications, you may also need to make changes to your applications when upgrading. Always test before upgrading, and we strongly recommend that you always create a manual snapshot of your DB cluster before upgrading.

Note that you have to do a separate engine upgrade for each major version. You can't skip a major version and upgrade directly to the major version following.

Prior to May 17, 2023, if you used the Neptune AWS CloudFormation stack to upgrade your engine version, it simply created a new, empty DB cluster in place your current one. As of May 17, 2023, however, the Neptune AWS CloudFormation stack now supports in-place engine upgrades that preserve your existing data.

For a major version upgrade, your template should set the following properties in DBCluster:

  • DBClusterParameterGroup (Custom or Default)

  • DBInstanceParameterGroupName

  • EngineVersion

Similarly, for DBInstances attached to DBCluster you should set:

  • DBParameterGroup (Custom/Default)

Make sure that all your parameter groups are defined in the template, whether they are default or custom.

In the case of a custom parameter group, make sure that the family of your existing custom parameter group is compatible with the new engine version. Engine versions earlier than used parameter group family neptune1, whereas engine releases from forward require parameter group family neptune1.2. See Amazon Neptune parameter groups for more information.

For major engine version upgrades, specify a parameter group with the appropriate family in the DBCluster DBInstanceParameterGroupName field.

A default parameter group should be upgraded to one that is compatible with the new engine version.

Note that Neptune automatically reboots DB instances after an engine upgrade.