Upgrade from v4 to v5

The Coveo for Salesforce v5 release introduces changes in the Coveo for Salesforce AppExchange package.

This article provides answers to the most frequently asked questions and concerns about upgrading from Coveo for Salesforce v4 to v5.

What are the breaking changes associated with the Coveo for Salesforce v5 package?

The Coveo for Salesforce components included in the package are built using the Salesforce Aura Components Framework and the Coveo JavaScript Search Framework. In the Coveo for Salesforce v4 packages, these components stored the HTML of your pages inside Visualforce components within Salesforce.

As of the Coveo for Salesforce v5 release, the HTML content of your pages is now being stored inside a new custom object called Page Content.

Additionally, the Coveo Visualforce (Classic) components included in the package have been deprecated.

Warning
Warning

If you’re using Coveo Classic components, we don’t recommend upgrading to v5. Consider upgrading to the latest Coveo for Salesforce v4 release instead. Otherwise, consider migrating to Lightning components and upgrading to v5 to continue taking advantage of the new features and updates offered by Coveo.

Lastly, the Coveo VisitorIdAccessor Lightning component has been replaced by the new ClientIdAccessor Lightning component.

Why is Coveo changing where the HTML of the pages is stored?

Salesforce no longer allows managed packages such as Coveo for Salesforce to create, write, or delete Visualforce components programmatically using Apex code. Although a managed package can still read from a Visualforce component, Salesforce now recommends this content be stored within a custom object instead.

Which Coveo Lightning components are affected by this change?

This change also affects the following Lightning Web component:

What can I expect as an impact to my implementation of Coveo for Salesforce if I’m using the affected Coveo Lightning components?

Other than how the HTML content of a page is stored under the hood, there should be no visible impact to the user experience.

Specifically, to limit any visible impact on existing implementations, Coveo components will continue to read the HTML from existing Visualforce components, just like before. However, when a page containing a Coveo component is opened for the first time, the package will try to copy the HTML from the existing Visualforce component to the new Page Content custom object. Provided the current user has the appropriate permissions on the new object, the page will now be stored and read from the Page Content custom object.

All newly created pages will use the Page Content custom object from now on to store HTML content.

As an administrator, you may need to give users new access to existing pages or newly created ones.

For example, in order to create or edit an existing page using the Coveo Interface Editor, you’ll need to set object permissions for the new Page Content custom object.

Note

The required permissions to create and edit pages have been added to the Coveo Authorized Administrator permission set that’s packaged with Coveo for Salesforce.

You will also need to provide field-level security access on the fields of that object.

Why am I unable to delete a page?

If you’re unable to delete a page, for example, you try to delete a page but nothing happens after the confirmation message, that means the page still exists as a Visualforce component.

An error message indicating the name of the Visualforce component should appear in your browser console.

Due to the copy mechanism that was put in place to ensure backward compatibility, in order to delete a page that still exists as a Visualforce component, you must manually delete the Visualforce component first. This operation can no longer be handled by the managed package.

Once the Visualforce component has been deleted, you will be able to delete your page.

To manually delete a Visualforce component

  1. (Recommended) Make sure that your page exists as a Page Content record before deleting the Visualforce component. To do so, enter the following SOQL query:

    SELECT Name FROM CoveoV2__PageContent__c Where Name = '<ComponentName>'

    Where you replace <ComponentName> with the name of the Visualforce component.

    Note

    The HTML of the page will be stored in the CoveoV2__PageContent1__c field.

  2. From the Setup menu in Salesforce, enter Visualforce in the Quick Find box, and then select Visualforce components.

  3. Search for the name of the Visualforce component that’s displayed in the error message of your browser console, and then delete it.

    Tip
    Tip

    This component should contain the HTML of the page you want to delete.

Which Coveo Visualforce (Classic) components are no longer supported in Coveo for Salesforce v5?

Note

Each component can be replaced by a corresponding Lightning component.

What can I expect as an impact to my implementation of Coveo for Salesforce if I’m using the affected Coveo Classic components?

Warning
Warning

If you’re using Coveo Classic components, we don’t recommend upgrading to v5. Consider upgrading to the latest Coveo for Salesforce v4 release instead. Otherwise, consider migrating to Lightning components and upgrading to v5 to continue taking advantage of the new features and updates offered by Coveo.

Your Coveo Classic components will continue to load and work like before.

However, since our managed package can no longer be used to create or edit Visualforce components, that means you can no longer use the Interface Editor to create or modify your Classic search pages. The Interface Editor for the Coveo Insight Panel Classic Component, Coveo Search (that is, Full Search page), and Coveo Case Creation components has been disabled.

Tip
Tip

If you didn’t create a Visualforce search page prior to v5, and you try to load one for the first time in v5, then a blank page will be displayed. This behavior is expected.

As of the Coveo for Salesforce v5 release, Coveo Classic components must now be updated manually.

Why has the VisitorIdAccessor Lightning component been replaced by the ClientIdAccessor component?

Since the visitorId query parameter is deprecated and has been replaced by the clientId in newer versions of the Coveo UI libraries, the component was replaced to reflect this change. For more information, see What’s the client ID?.

How does the replacement of the VisitorIdAccessor component affect my implementation?

If you’re currently using the Coveo VisitorIdAccessor Lightning component, we recommend replacing it with the new ClientIdAccessor component at your earliest convenience to maintain up-to-date analytics and to improve visit tracking capabilities.

What will happen if I keep using Coveo for Salesforce v4?

In short, you will be missing out on the latest updates, features, and potential bug fixes. However, there’s no pressure to upgrade to v5 right away. Coveo will continue to support v4 until February 2026.

Can I roll back to v4 once I upgrade to v5?

It’s very difficult to roll back a Coveo for Salesforce package after it has been upgraded. We strongly recommend that you read the documentation, verify if the changes will affect your implementation, for example, by testing it in a sandbox first, and plan accordingly before upgrading your package.

What if I don’t want to upgrade to v5?

You may continue to use v4. Coveo will continue to support v4 until February 2026. Depending on the situation, we may decide that the best course of action to continue support is to upgrade to v5.

For more information, see Product lifecycle.