Versions Compared

Key

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

Artifact upload Uploading and listing artifact:

In order to create applications with versions, the artifact jars (which contains CDAP application) needs to be uploaded first. Once an artifact is uploaded, an application can be created from it by optionally providing a configuration.

Uploading artifact

Emacs
Code Block
theme
languagebash
POST /v3/namespaces/<namespace-id>/artifacts/<artifact-id> --data-binary @path/to/file-1.1.0.jar

You can view the information about artifacts deployed using the listing endpoint.  

Listing artifacts

Code Block
themeEmacs
languagebash
GET /v3/namespaces/<namespace-id>/artifacts 


Creating applications from artifacts:

REST call to create application from artifact

Code Block
themeEmacs
languagebash
POST /v3/namespaces/<namespace-id>/apps/<app-id>/versions/<version-id>/create -d { "artifact": { "name": "WordCount", "version": "3.5.1", "scope": "user"}, "config": {"stream": "purchaseStream"} }

version-id: Needs to be composed only of alphanumeric, -, _ and . 

...