Skip to main content
Version: Deploy 23.1

Plugin synchronization

This topic covers plugin synchronization, which involves aligning the filesystem and database during system startup to streamline the plugin management process.

Once you upgrade your Digital.ai Deploy to 10.2.0 or higher version there is no more manually copying of plugin files. Everything is handled by Digital.ai Deploy GUI and internal API. Plugins are now being stored in the database as a central location to remove manual manipulation of files across the cluster.

How synchronization works

From Deploy 22.0 and later versions, you can add a new option -plugin-source when starting the distribution. You can configure value of the option as database or filesystem. If you do not configure the option, database is set as the default value.

The -plugin-source startup parameter defines the source location for the plugins. It helps in synchronizing the contents of the database and filesystem.

If the plugin source is defined as database or -plugin-source option is not defined:

  • All plugins on the filesystem that are not in the database will be deleted
  • All plugins from the database that do not exist on the filesystem will be written on the filesystem

If the plugin source is filesystem:

  • All plugins from the database that do not exist on the filesystem will be deleted
  • All plugins on the filesystem that are not inserted into the database will be inserted into the database

Plugin synchronization is skipped in certain cases (even if the -plugin-source option is defined) in the following scenarios:

  • When you start a fresh installation for the first time
  • When you start the system the first time after upgrading to a new version

If there are different versions of a plugin in the database and filesystem the one from -plugin-source will override the one on the other location. This will happen irrespective of the version and source, thereby allowing version upgrades and downgrades.

NOTE The default value of the -plugin-source is database when Digital.ai Deploy is run as a service. To modify the -plugin-source value, configure the value of:

  • wrapper.app.parameter.1 from -plugin-source=database to -plugin-source=filesystem in conf/xld-wrapper-server.conf
  • wrapper.app.parameter.5 from -plugin-source=database to -plugin-source=filesystem in conf/xld-wrapper-worker.conf

Examples

  • If plugin source is filesystem and a plugin that is inserted into the database does not exist on the filesystem, the plugin will be deleted from the database.

    Log output:

    Plugins Manager version

  • If plugin source is database and a plugin that is inserted into the database does not exist on the filesystem, the plugin will be written to the filesystem.

    Log output:

    Plugins Manager version

  • If plugin source is database and a plugin that is inserted into the database exist on the filesystem, but a different version, the plugin on the filesystem will be removed and the plugin from the database will be written to the filesystem.

    Log output:

    Plugins Manager version

Plugins

Bundled plugins

Plugins that come with the distribution are called bundled plugins. They are automatically placed on your filesystem.

When you start your distribution of Digital.ai Deploy 10.2 and later versions for the first time, you will see a message that these plugins are being inserted into the database and synchronized with the message below:

Plugin synchronization bundled

Official plugins

Official plugins are plugins that you can find under the Browse tab in the Plugins menu. If you install a new official plugin it means it is being added into the database. You will get a message that the plugin is ready for installation. After you restart the system, the synchronization begins and the new plugin is written to the filesystem and the new plugin is ready for use.

Log output:

Plugin synchronization official

Local plugins

  • Local plugins are plugins that you can manually upload by clicking the Installed tab under the Plugins menu. Once you upload a new local plugin it means it is being inserted to the database. You will get a message that the plugin is ready for installation. Once you restart the system, synchronization will happen and the new plugin gets written to the filesystem after which it is ready for usage.
  • If plugin exists both on filesystem and database (which means plugin with the same name was already uploaded before), only plugins from plugin source will get materialized
  • Type validation is introduced as of Digital.ai Deploy 22.0.0, so there cannot be duplicated types.