Funnelback extensions and plugins

Funnelback extensions provide custom functionality that has been vetted and reviewed to be shared and reused between different collections.

Custom functionality is implemented as one or more plugins which a Funnelback administrator can install onto Funnelback. Plugins are a way for the community to contribute common solutions to re-occurring problems, or for highly unique solutions to be implemented for a particular problem.

Types of plugins

Plugins allow you to package up functionality that includes:

  • logic that will run at the same time as executing a collection’s hook scripts

  • filters that can be added to a collection’s filter chain

  • custom gatherers

Some plugins will combine a few of these together.

Available plugins

Before a plugin can be used it must be added to the available plugins on the Funnelback server by a Funnelback administrator.

Available plugins are listed on the extensions screen, available from the navigation panel within the administration interface.

extensions.png

The extensions screen lists the available plugins and also provides access to documentation for the plugin.

Using plugins

Once a plugin has been installed on a server, the next step to using the plugin is to pick a version and enable it on a collection.

Plugins can be enabled from the extensions screen or by changing the settings directly in collection.cfg or profile.cfg:

plugin.<name of plugin>.enabled=true
plugin.<name of plugin>.version=<version to enable>

For example, to enable version 1.0.0 of the sample plugin set:

plugin.sample.enabled=true
plugin.sample.version=1.0.0

Multiple versions of the same plugin can be made available on the same server. To use 2.0.0-RELEASE of the sample plugin set:

plugin.sample.enabled=true
plugin.sample.version=2.0.0-RELEASE
if you enable a plugin on a collection.cfg, all profiles will by default inherit that plugin.

Custom gather plugins

Some plugins can define a custom gatherer, but these will only run if the collection type is set to custom. To use a custom gathering plugin, create a custom collection, then enable the plugin on that collection. If your custom collection uses multiple plugins which define custom gatherers, the following setting in collection.cfg can be used to specify which one to use:

plugin.force-gatherer=<plugin name>

For example, to use the gatherer that comes from the sample plugin:

plugin.force-gatherer=sample

Configuring a plugin

While the bare minimum is to enable a plugin with a version, most plugins will be configured by setting keys in collection.cfg or profile.cfg. Each plugin will be different, so you will need to read the documentation to know which settings are expected. Additionally, some plugins can supply filters which need to be added to the filter chain.

When do plugins run?

A plugin will run at different times depending on the type of plugin. These can include:

  • At the start of a custom gather, to provide documents to be indexed

  • During indexing, to provide metadata or do other processing.

  • When a query is executed by a user.

Push collections

Push collections will run all plugins at a regular interval that is determined by the time it takes to run them all. They will also all be re-run when executing a vacuum with re-index. Push collections will apply the data from the last successful plugin execution to any new documents committed.

© 2015- Squiz Pty Ltd