You can use a Git repository to import a SQL Stream Builder project that was
previously created and exported using source control.
-
Navigate to the Streaming SQL Console.
-
Go to your cluster in Cloudera Manager.
-
Select SQL Stream Builder from the list of services.
-
Click .
The Streaming SQL Console opens in a new window.
-
Click Import Project on the
Projects page of Streaming SQL Console.
The Import Project window appears.
-
Optional: Provide a prefix that overrides the Materialized View table
names.
Providing a prefix to the Materialized View tables names that overrides the
default one is an advanced option. The tables are prefix by default with the ID
of the projects to avoid collision between projects. This configuration allows
setting a custom prefix to the Materialized View tables created in the
project.
-
Provide the Source Settings of the project.
-
Add a remote Github repository URL to the Clone
URL field.
You can use the following example URLs with or without
authentication:
- To clone without authentication:
https://github.com/cloudera/ssb-examples.git
- To clone and push with HTTP basic authentication
(username/password):
https://github.com/cloudera/ssb-examples.git
- To clone and push with SSH authentication (SSH private key):
git@github.com:cloudera/ssb-examples.git
- To clone and push a local git repository on the filesystem of
SSB host:
file:///usr/src/ssb-examples/
-
Provide the branch name or tag of the Github repository to the
Branch field. This branch is checked out when
pulling or pushing to the Github repository.
-
Provide the name of the project to the Project
field.
-
Enable or disable Allow deletions on import.
Enabling the allow deletion upon import allows you to hard-reset your project
to its versioned state when there are untracked resources in it. For example,
the job is deleted from the project when importing the project from Github if
the job does not exist in the repository. In other words, the upstream version
overrides the version you have in Streaming SQL Console. If disabled, the
project keeps the resources that were not pushed to the Github repository.
The
deletion affects the jobs, data sources, functions, Materialized Views and
their API keys.
-
Enable or disable Authentication for the project.
After you have created the project, you have the following options to manage the
project on the Projects page:
- Click Open to use the created project and start creating
SQL jobs.
- Click Switch to open another project than the active
one.
- Click Delete to remove the project from SSB.