This article covers a Bloomreach Experience Manager version 11. There's an updated version available that covers our most recent release.

View a document in a channel

The document editor contains a 'View' menu that lists the names of all channels that document can be viewed in. Clicking on a channel name shows the document in that channel in the Channels Perspective.

CMS configuration

The list of channels for the document is fetched from HST through a REST call. The CMS contains a 'REST proxy' service that uses a CXF JAX-RS client to create a proxy from classes that represent a REST service. These classes are provided by the HST in the ' hst-rest-api' module.

REST proxy service

The REST proxy service to use for the HST can be configured at:

/hippo:configuration/hippo:frontend/cms/cms-services/hstRestProxyService

Configuration parameters:

  • rest.uri the URI at which the CMS can access the 'CMS REST service' run by the site. Default value: ' http://127.0.0.1/site/_cmsrest'
    The default host name (' 127.0.0.1') and mount (' _cmsrest') are set via Spring configuration in HST, and can be overridden if needed.
    By default (if not explicitly specified) the port of the rest.uri is automatically derived to use the current request (local) port serving the CMS.
    This allows running multiple CMS cluster instances on the same host, using different ports.  

  • plugin.class
    Should be ' org.hippoecm.frontend.service.restproxy.RestProxyServicePlugin'

  • service.id
    CMS service ID to use in the plugin framework.
    Default value: ' hst.rest.proxy.service'

Some Spring configuration has to be present in the site module of your project to inject the CMS REST pipeline into HST. This consists of the file

site/src/main/resources/META-INF/hst-assembly/overrides/hst-cms-rest.xml

with the following contents:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:lang="http://www.springframework.org/schema/lang"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:util="http://www.springframework.org/schema/util"
       xmlns:aop="http://www.springframework.org/schema/aop"
       xsi:schemaLocation="
            http://www.springframework.org/schema/beans
            http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
            http://www.springframework.org/schema/lang
            http://www.springframework.org/schema/beans/spring-lang-3.0.xsd
            http://www.springframework.org/schema/util
            http://www.springframework.org/schema/util/spring-util-3.0.xsd
            http://www.springframework.org/schema/aop
            http://www.springframework.org/schema/aop/spring-aop-3.0.xsd">

  <import resource="classpath:/org/hippoecm/hst/site/optional/jaxrs
                                  /SpringComponentManager-rest-jackson.xml" />
  <import resource="classpath:/org/hippoecm/hst/cmsrest
                                  /SpringComponentManager-cmsrest.xml" />

</beans>

HST will automatically add a mount for the CMS REST service to the HST hosts configuration at runtime.

If everything is configured correctly, the following URL (using example port 8080 configured for the Tomcat container) should return all channels for the UUID of a hippo:handle of a document:

http://127.0.0.1:8080/site/_cmsrest/documents/<uuid>/channels

View menu

The 'View' menu itself is rendered by the 'channel actions' plugin. Its configuration is located at:

/hippo:configuration/hippo:workflows/default/handle/frontend:renderer/channelactions

The channel actions plugin recognizes the following properties:

  • rest.proxy.service.id
    Service ID of the CMS REST proxy service to use.
    Default: hst.rest.proxy.service

  • plugin.class
    CMS plugin class that renders the menu.
    Default: org.onehippo.cms7.channelmanager.plugins.channelactions.ChannelActionsPlugin

Removing the 'View' menu for channels

The view menu for channels can be removed by removing the plugin configuration at  /hippo:configuration/hippo:workflows/default/handle/frontend:renderer/channelactions.

Did you find this page helpful?
How could this documentation serve you better?
On this page
    Did you find this page helpful?
    How could this documentation serve you better?