Getting Started with Streaming Analytics
Also available as:
loading table of contents...

Setting up the Stream Analytics App using the TruckingRefAppEnvEnviornmentBuilder

About This Task

Follow the below instructions if you want to set up the reference application using an utility. If not, skip this section and go through the next set of sections. Perform the below steps on the host where SAM is running.


  1. Download the SAM_EXTENSIONS zip file. Unzip the contents. Call the unzipped folder $SAM_EXTENSION

  2. Navigate to the unzip location:

    cd $SAM_EXTENSION/ref-app
  3. Modify the file based on your environment:

    • = the REST url of the SAM instance in your env (e.g.: http://<SAM_HOST>:<SAM_PORT>/api/v1)

    • sam.service.pool.hdf.ambari.url = The rest endpoint for the HDF cluster you installed (e.g.: http:/<HDF_AMBARI_HOST>:<PORT>/api/v1/clusters/<cluster_name>)

    • sam.service.pool.hdp.ambari.url = The rest endpoint for the HDP cluster you installed. (e.g.: http:/<HDP_AMBARI_HOST>:<PORT>/api/v1/clusters/<cluster_name>)

    • sam.schema.registry.url = The url of the Schema Registry service in SAM you installed as part of the HDF cluster (e.g.: http://SR_HOST:SR_PORT/api/v1)

  4. Run the following command

    • java -cp sam-trucking-ref-app-shaded.jar hortonworks.hdf.sam.refapp.trucking.env.TruckingRefAppEnviornmentBuilderImpl

If script ran successfully, you should see output like the following (it will take about 3-5 minutes to finish):

Trucking Ref App environment creation time[367 seconds] Trucking Ref App SAM URL: http://SAM_HOST:SAM_PORT/#/applications/78/view