Avoiding Duplicate URIs
The Content Engine's default method for generating content
item/article URIs is to append the content item's database ID to a
prefix (article
by default). This mechanism has not
changed between version 4.x and version 5.2.7.2. When content items
are migrated from version 4.x to version 5.2.7.2, they are assigned
new database IDs. If no special action was taken, this would mean that
all your publications' URIs would change as a result of the the
migration. In order to prevent this happening, the Migrator tool
includes the old URI with every exported content item. This URI
(article123.ece
, for example) is imported into the
system and stored with the content item as its URI. The new system will
then always publish the content item as
article123.ece
, even though its database ID is (for
example) 456
.
This mechanism ensures that all migrated content retains its original URI. However, the problem is not completely solved unless we also ensure that no newly-created content item in the new system ends up with the same URI. There are three possible ways you can avoid this problem:
-
Set the starting ID number in your new database to a much higher number than the current ID number in your old system. If you are going to run the systems in parallel for any length of time, then you need to make sure that there is a large enough gap to allow for plenty of new content items being created on the old system.
-
Change the prefix/suffix used for generating URIs to something different on the new system. You can do so by setting one or both of the following properties in your common configuration layer:
articlePagePrefix
(article
by default)articlePageSuffix
(.ece
by default)You must set the properties in configuration-layer-root
/ServerConfig.properties
. For general information on version 5 configuration layers, see Configuring The Content Engine. -
Make a transaction filter that generates URIs for all your content. Making a transaction filter requires Java programming skills. For further information about making and using transaction filters, see Transaction Filters.