The Media editor allows the content administrator to select and link to media assets stored in a content repository.

The media editor consists of an Experience Manager editor and a lightweight Web application that enables the content administrator to browse and navigate across a set of media assets in order to more easily find specific files.

The default Discover Electronics reference application stores media directly in the Endeca Configuration Repository and uses a built-in asset browser to present these assets to the content administrator. You may also initialize an MDEX Engine to index media asset metadata and URIs as records, making them available for Guided Navigation in an enhanced Media Browser.

A Media editor allows a content administrator to link media into a cartridge. It can be combined with the Link Builder in order to create images that link to destinations in your application, such as those used in site banners.

To add a Media editor to a template:

In order to use the Media editor, if you are using the Endeca Configuration Repository as your media store, you must upload any media files to the repository. If you are using an external digital asset management system with a corresponding MDEX Engine, the matching application must be configured and running and the Media Browser must be enabled.

You can specify allowable media formats in the editor JSON file. You can also enable or disable the Media Browser, and specify the MDEX Engine that it should query for media records.

The Discover Electronics reference application uses the Endeca Configuration Repository to store media and accesses these resources through a default asset browser, rather than relying on the Media Browser and an accompanying media MDEX Engine.

Below is the configuration for the Media editor in the editor JSON file, located at <app dir>\config\import\editors\MediaEditor\_.json:

{
   "ecr:type":"editor",
   "config":{
      "useMediaBrowser":"false",
      "mediaRoots":{
         "default":"http://EXAMPLE:8006/ifcr/sites/Discover/media/",
         "MediaSource":"http://EXAMPLE:8006/discover-authoring/images/"
      },
      "mdexPort":"17000",
      "mdexHost":"EXAMPLE",
      "videoFormats":"mp4|ogg|ogv|webm",
      "imageFormats":"jpg|png|gif",
      "mediaURI":"/ifcr/sites/Discover/media/"
   }
}

This sets the following properties across all instances of the media editor in the application:

Property

Description

useMediaBrowser

This property enables or disables the media browser. By default, it is set to false.

mediaRoots

This property specifies the absolute URLs to available media repositories. It includes a nested default property that points to the Endeca Configuration Repository, and an additional property for each repository indexed by the media MDEX Engine. For more information, see "About resolving media paths in content items."

default

The absolute URL to the Endeca Configuration Repository, used by the default asset browser. The specified host and port should match those used by Workbench.

content source (mediaSource)

An absolute URL to a media content source. In the reference data application, records are assigned a media.repository_id property with a value of mediaSource.

Your own data ingest process may assign different values for media served from varying locations. In this case, each media.repository_id value should have a corresponding element in the editor JSON file that identifies the URL for that content source.

mdexPort

For applications using the Media Browser, this is the hostname or IP address of the media MDEX Engine server.

mdexHost

For applications using the Media Browser, this is the port on which the specified media MDEX Engine server listens.

videoFormats

A pipe-delineated list of valid video formats. Videos do not display in either the default asset browser or Media Browser. The Discover Electronics reference application is configured to use mp4, ogg, ogv, and webm, formats.

Note that Internet Explorer only supports the mp4 format. If you attempt to view an ogg, ogv, or webm format video in the Media Editor using Internet Explorer, an invalid source error message appears.

imageFormats

A pipe-delineated list of valid image formats. Any images not matching a listed format do not display in either the default asset browser or Media Browser. The Discover Electronics reference application is configured to use jpg, png, and gif formats.

mediaURI

The location of the media node within the Endeca Configuration Repository. This is only used by the default asset browser.

Note the following:

The ability to store media in the Endeca Configuration Repository has been deprecated in Oracle Commerce 11.3. Oracle Commerce Strongly recommends against storing any media in the Endeca Configuration Repository.

If you wish to use the Endeca Configuration Repository as your media content source, you can upload assets directly to Experience Manager. It might be useful in a development environment, where a separate media server may not be worth the effort of maintaining.

All applications created using the Deployment Template include a set_media script in the <app dir>\control directory. This script uploads media content from the <app dir>\config\media directory to the Endeca Configuration Repository. After uploading content, it becomes available for use in Experience Manager.

In general, you can store moderate amounts of media content in the Endeca Configuration Repository. Very roughly speaking, a moderate amount of media content is approximately thousands of media files but not tens of thousands of media files. This storage mechanism is intended as a convenience when you build an application in a development environment.

If you have larger amounts of media content, Oracle recommends employing a digital asset management system rather than uploading the media content into the Endeca Configuration Repository.

Here are a few specific guidelines to keep in mind before you upload media content to the Endeca Configuration Repository:

To upload media content for use in Experience Manager:

Links to media assets are resolved in the Media editor by combining configuration in the editor configuration file with the media.path property on the selected record. At runtime, these links are resolved against the media sources specified in the Assembler context file.

For example, assume the following element within <mediaRoots> in the editor configuration file:

<myMediaSource>http://myhost.mydomain.com:8006/myCMS/Discover/media/</myMediaSource>

A media record with a media.repository_id value of "myMediaSource" and a media.path value of "images/foo.jpg" would resolve to:

http://myhost.mydomain.com:8006/myCMS/Discover/media/images/foo.jpg

At runtime, the value of the media.path property is instead appended to the appropriate media source configured in assembler-context.xml:

<!--
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ~ Media Sources
-->

<bean id="authoringMediaSources" class="java.util.ArrayList" lazy-init="true">
    <constructor-arg>
        <list>
            <bean class="com.endeca.infront.cartridge.model.MediaSourceConfig">
                <property name="sourceName" value="MyMediaSource" />
                <property name="sourceValue" value="http://${workbench.host}:${workbench.port}/ifcr/sites/
${workbench.app.name}/media/" />
            </bean>
            <bean class="com.endeca.infront.cartridge.model.MediaSourceConfig">
                <property name="sourceName" value="default" />
                <property name="sourceValue" value="http://${workbench.host}:${workbench.port}/ifcr/sites/
${workbench.app.name}/media/" />
            </bean>
        </list>
    </constructor-arg>
</bean>

<bean id="liveMediaSources" class="java.util.ArrayList" lazy-init="true">
    <constructor-arg>
        <list>
            <bean class="com.endeca.infront.cartridge.model.MediaSourceConfig">
                <property name="sourceName" value="MyMediaSource" />
                <property name="sourceValue" value="/images/" />
            </bean>
            <bean class="com.endeca.infront.cartridge.model.MediaSourceConfig">
                <property name="sourceName" value="default" />
                <property name="sourceValue" value="/images/" />
            </bean>
        </list>
    </constructor-arg>
</bean>

In a live environment, the aforementioned media record would resolve to:

http://myhost.mydomain.com:8006/myBiggerFasterCMS/Discover/media/assets/images/foo.jpg

Note

While the tooling, authoring, and live content sources can all differ, Oracle recommends configuring the Media Browser to use the authoring content source.

The default browser for the Media editor can only be configured to browse media assets in the Endeca Configuration Repository. If you are serving media assets from an external content source, you must enable the Media Browser and configure it to use your media MDEX Engine.

Follow these steps to configure the Media Browser in the MediaEditor JSON file for the Discover Electronics reference application, located at <app dir>\config\import\editors\MediaEditor\_.json:

  1. Change the value of the useMediaBrowser to true.

     "useMediaBrowser": "true",
  2. Include a content source element under mediaRootsthat points to your media host.

    The element name is a unique key that identifies a media host. Each record has a corresponding media.repository_id property that identifies its content source. The relevant content source property maps that source to a URL.

    For example, in the CAS crawl configuration for the reference data application, each record is assigned a media.repository_id property with a value of mediaSource. The mediaSource property in the editor configuration file specifies the URL:

    "mediaRoots": {
            "default": "http://Example-LAP:8006/ifcr/sites/Discover/media/",
            "mediaSource": "http://Example-LAP:8006/ifcr/sites/Discover/media/"
          },

  3. Modify the mdexPort and mdexHost elements to point to the host and port of the MDEX Engine backing your media host.

    "mdexPort": "17000",
          "mdexHost": "Example-LAP",
  4. Save and close the file.

    {
        "ecr:type":"editor",
        "config": {
          "useMediaBrowser": "true",
          "mediaRoots": {
            "default": "http://Example-LAP:8006/ifcr/sites/Discover/media/",
            "mediaSource": "http://Example-LAP:8006/ifcr/sites/Discover/media/"
          },
          "mdexPort": "17000",
          "mdexHost": "Example-LAP",
          "videoFormats":"mp4|ogg|ogv|webm",
          "imageFormats": "jpg|png|gif",
          "mediaURI": "/ifcr/sites/Discover/media/"
         }  
    }
  5. Navigate to the <app dir>\control directory.

  6. Run the set_editors_config script to publish your changes to the Endeca Configuration Repository.

If you are storing media resources in an independent content store, you can set up an MDEX Engine where records represent media assets and include asset metadata and URIs. Storing this information as records allows content administrators to navigate assets based on image size, modification date, or other attributes when selecting media assets for a content item.

Tools and Frameworks includes a reference media MDEX application, including a CAS pipeline and Deployment Template configuration.

The Tools and Frameworks package includes a reference implementation of a media MDEX Engine that includes a CAS crawl and Forge pipeline for crawling resources on the file system and indexing the corresponding metadata and URIs. The Experience Manager can then query the MDEX Engine for record information.

The reference media application illustrates the schema requirements and configuration that you should use when building your own media pipeline.

The reference media MDEX Engine data application assumes an environment where all required Oracle components are running on the same machine.

You must have the Oracle Content Acquisition System and Oracle Tools and Frameworks installed on the machine onto which you wish to deploy the media MDEX Engine.

The reference data application runs an MDEX Engine with indexed media resources, and integrates with the Discover Electronics reference application to expose the media records to a business user in the Media editor in Experience Manager. The records include properties for metadata, such as image dimensions, making it easier to narrow down a large quantity of media assets to those that fit the requirements for a cartridge in the front-end application.

To deploy the reference data application:

  1. Include the CAS manipulators for the reference data application as server plugins:

  2. Restart the CAS Service.

  3. Deploy the reference data application:

    1. Open a command prompt or command shell.

    2. Navigate to the ToolsAndFrameworks\<version>\deployment_template\bin directory.

    3. Run deploy.bat or deploy.sh with the following options:

      deploy --app <Endeca Directory>/ToolsAndFrameworks/<version>/reference/media-mdex-cas/deploy.xml
    4. Confirm the Platform Services installation directory.

    5. Enter n to skip installation of a base application.

    6. Specify media as the application name.

    7. Specify the application directory.

      Typically, this is C:\Endeca\apps on Windows, or /usr/local/endeca/apps on UNIX.

    8. Specify the EAC port previously used for the Discover Electronics reference application.

      By default, this is port 8888.

    9. Specify the port that Workbench runs on.

      By default, this is port 8006.

    10. Specify a Dgraph port.

      By default, this is port 17000. If you change this value, you must also update the configuration for the MediaEditor in the \config\import\editors\MediaEditor\_.json file after deploying the application.

    11. Specify the CAS installation directory.

    12. Specify the CAS version.

    13. Enter the port that CAS runs on.

      By default, this is port 8500.

    14. Enter the name of the application in which you wish to enable media browsing.

      For the Discover Electronics reference application this should be Discover.

    15. Enter the absolute path to the location on disk where media assets are stored.

      This is the file path that the Content Acquisition System crawls to index the files. In a default Discover Electronics deployment it is C:\Endeca\apps\Discover\config\media on Windows, or usr/local/endeca/apps/Discover/config/media on Unix.

  4. Provision the application with the EAC and run a baseline update:

In order for the Media Browser in Experience Manager to have sufficient information for forming content XML, any pipeline that you configure for a media MDEX Engine must define specific properties and dimensions.


Copyright © Legal Notices