Introduction

Originally created in version 2.0, the Kettle plugin system was designed with the KISS principle in mind.  At the core of it, it's a simple Java URL class loader appropriately named "KettleURLClassLoader".  It was used to load Step and Job entry plug-ins. 

In version 3.0, support for Java annotations were added as well as support for partition plugins.

In version 4 of Kettle we wanted to add Repository and Database plugins as well as plan for Transformation and job plugins. We also want to add support for loading annotation plug-ins from single independend jar files stored anywhere we like.  That would make configuration of plugins a lot easier.  You write a set of plugins of various types, put those in a jar file and you put the jar file in the "plugins" folder.  End of story.  Obviously, having 7 different class loaders around that all do almost the same thing was not an option so we decided to rewrite the plug-in system a bit.

This resulted in the creation of the Kettle 4 Plugin Registry.

PluginRegistry

 The plugin registry is the new one-stop-shop you can use to deal with all the aspects of handling any type of plugin.  For this, a number of new interfaces and classes were created:

Migration of code from 3.x

StepLoader

The step loader singleton was used everywhere we needed to load a StepInterface or if we wanted to learn more about a certain step.

As such, this class was used mostly in Spoon, in StepMeta and in the Repository plugins.   Here are the main changes to make:

The StepPlugin class and the PluginInterface are quite similar, you'll find your way around.  We took the opportunity to correct a few mistakes from in that class though: