Versions Compared

Key

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

...

  1. Clone The Hub Github Repo locally.

  2. Create a new branch for your changes.

  3. If you are deploying a new version of an existing artifact proceed to step 3. If you are deploying a new artifact that does not currently exist in the Hub then create a directory under packages/ with the name of the artifact. The naming convention is “<artifact-type>- <artifact-name>“.

  4. Create a new directory under the packages/<artifact>/ directory, name this new directory with the version number. Ex. to deploy version 1.0.0 the path would be packages/<artifact>/1.0.0/

  5. If you are updating an existing artifact, it is recommended that you delete the old version if they target the same version of CDAP. For example, if you’re adding version 1.1.0 and the existing version is 1.0.0 and they both target CDAP 6.1.1, then we recommend that you delete 1.0.0 since there is no reason anyone should deploy the older version.

  6. Place the appropriate files in the directory you just created, following the info presented in the Background Info section.

  7. Create a Pull Request with your changes and send the link to someone from the Cloud Data Fusion team for approval.

  8. Once the PR is approved, merge it into the master branch.

  9. From the hub/ directory run the following commands:

    Code Block
    git checkout master
    git pull
    cd packager
    mvn clean package
    cd ..
    java -cp packager/target/*:packager/target/lib/* io.cdap.hub.Tool build
  10. Open the packages.json file and ensure your new artifact appears in the json with the correct version.

  11. When you are ready to deploy run the following commands:

Note

Warning: This will push your changes to prod instantly, there is no staging environment or rollout. As soon as the upload is done the changes are live. Please double check that all the required artifact files are present and that packages.json contains the correct versions.

Code Block
gsutil -m cp -r -n packages/ gs://hub-cdap-io/v2/
gsutil cp categories.json gs://hub-cdap-io/v2/categories.json
gsutil cp packages.json gs://hub-cdap-io/v2/packages.json

1112. Wait a couple minutes for the changes to propagate and try to deploy your new artifact from The Hub in a CDF instance.

...