Installing the Extension - fredhopper/hybris-connector GitHub Wiki

IMPORTANT: This page is now archived. To learn how to install and configure the extension, see README.md.

Basic overview

The hybris Commerce Suite is based on a modular concept that allows new logic to be located in separate, function-specific extensions.

The Fredhopper plug-in comes in the form of a hybris extensions called 'fredhoppersearch'.

The 'fredhoppersearch' extension itself depends on a prepackaged jar, 'fredhoppercore', which contains core classes and beans required both to generate input data and query the index.

The 'fredhoppercore' .jar is designed to contain no references to or dependencies on any hybris code and as such can be made to work with other solutions.

The 'fredhoppersearch' extension contains all logic interacting with the hybris code base.

The default implementation found here can be adapted and overridden in a generated extension of your own to suit project specifics as you see fit.

To this end, we have added a Fredhopper template ('fredhoppertemplate') for generating a new extension via 'ant extgen' as per hybris recommended practice.

Add the Fredhopper extensions

Please make sure to append the new extensions to your config/localextensions.xml:

<extensions>  
  ...  
  <extension name="fredhoppersearch" />  
  <extension name="<generated>" />  
</extensions>  

Add and configure related properties

There are a number of property values which need to be set before the plug-in can successfully operate.

These property values will direct the plug-in's logic to the correct Fredhopper instance url, provide the required credentials, specify the location where index files should be generated locally etc.

Please add your values for these to your config/local.properties:

Property Meaning
fh.product.catalog.name The name of the hybris catalog to use as the source of your data
fh.product.catalog.version The version of the hybris catalog to use
fh.data.directory The file path where index files should be generated before upload
fh.instance.host The fully qualified domain name of the Fredhopper host instance
fh.instance.port The port number to connect to
fh.instance.servername The specific server name of your instance, as used in the path when publishing data
fh.instance.username The username to authenticate with
fh.instance.password The password to authenticate with
fh.instance.query.url The Fredhopper url to query against
fh.instance.universe The Fredhopper universe to use
fh.query.maxretries Number of retries time for a request before giving an error

For example:

fh.product.catalog.name= apparelProductCatalog
fh.product.catalog.version= online
fh.data.directory= file:/Projects/Fredhopper/hybris/temp
fh.instance.host= my.eu1.fredhopperservices.com
fh.instance.port= 443
fh.instance.servername= fas:live1
fh.instance.username= example7
fh.instance.password= ...
fh.instance.query.url= http://query.prepublished.live1.fas.eu1.fredhopperservices.com/fredhopper-ws/services/FASWebService
fh.instance.universe = catalog01
fh.query.maxretries = 3

Rebuild the hybris Commerce Suite

Finally, as with any new hybris extension, rebuild the hybris Commerce Suite for these changes to take affect.

Make sure you update your system afterwards to import essential data for the Fredhopper Connector.

⚠️ **GitHub.com Fallback** ⚠️