Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Hydrator Plugin Experience

Installing custom plugins

In CDAP 3.2, installing Hydrator plugins requires uploading the artifact containing the plugins, placing a .json the UI uses to configure widgets into a special folder on the UI machine, and adding docs to cdap's website.

...

Code Block
GET /namespaces/{namespace-id}/artifacts/{artifact-name}/{versions}/{artifact-version}/properties
GET /namespaces/{namespace-id}/artifacts/{artifact-name}/{versions}/{artifact-version}/properties/{property}?keys=key1,key2
PUT /namespaces/{namespace-id}/artifacts/{artifact-name}/{versions}/{artifact-version}/properties/{property}
POSTPUT /namespaces/{namespace-id}/artifacts/{artifact-name}/{versions}/{artifact-version}/properties
DELETE /namespaces/{namespace-id}/artifacts/{artifact-name}/{versions}/{artifact-version}/properties/{property}

...

Code Block
{
  "properties": {
    "widgets.batchsource.database": "{
      \"doc\": \" <markdown content> \",
 <widgets json>",
    \"widgetsdoc.batchsource.database": \" <widgets json> \"
    }"<doc>",
    ...
  }
}

 

Jira Legacy
serverCask Community Issue Tracker
serverId45b48dee-c8d6-34f0-9990-e6367dc2fe4b
keyCDAP-4280

 

...

Installing plugins from hydrator-plugins repository

To install the plugins from hydrator-plugins, a user simply installs the hydrator-plugins rpm or deb.  In addition, cdap-site.xml will have to set the app.artifact.dir setting to include the directory for those plugins (/opt/hydrator-plugins/artifacts).

 

The work for this will include setting up the hydrator-plugins build to create the rpms and debs.  The pom will be changed so that in addition to the jars, the config json will be created.  The json files will be created using an antrun script target that writes out the parents for the artifact, as well as properties for widget and doc information.  Prepare phases can then copy jars and jsons to the right place for packaging to be done.

 

The CDAP build will still need to bundle the results of the hydrator-plugins build in order to build a standalone zip that contains hydrator plugins. To accomplish this, we will add a property ('-Dadditional.artifacts.dir=</path/to/additional/artifacts>') that can be used to copy any additional jars and jsons from some external directory. This property can then be used in standalone builds to pull in the hydrator-plugins artifacts and configs.

Plugin Selection

User installs CDAP 3.3.0 by downloading the sdk or installing via packages.  Included in CDAP is the Hydrator webapp, cdap-etl-batch-3.3.0, and cdap-etl-realtime-3.3.0 artifacts.  Also included are all the v1.0.0 plugins in the hydrator-plugins repo, like cassandra-1.0.0.  The user creates a pipeline that reads from cassandra and writes to a Table.

...