Funnelback extensions and plugins

Funnelback extensions provide custom functionality that has been vetted and reviewed to be shared and reused between different search packages, data sources and results pages.

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 search package’s hook scripts

  • filters that can be added to a data sources’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 and a screen to enable or disable plugins on data sources and results pages.

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 the data source or search package.

Plugins can be enabled from the extensions screen by clicking the Apply button or by changing the settings directly in the data source, results page or search package configuration:

Configuration key Value

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:

Configuration key Value

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 of the sample plugin set:

Configuration key Value

plugin.sample.enabled

true

plugin.sample.version

2.0.0

if you enable a plugin on a search package, all child results pages will by default inherit that plugin unless you disable it on a specific child results page.

Custom gather plugins

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

Configuration key Value

plugin.force-gatherer

<plugin name>

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

Configuration key Value

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 the data source, search package or results page configuration. 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 data sources

Push data sources 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 data sources will apply the data from the last successful plugin execution to any new documents committed.

© 2015- Squiz Pty Ltd