Joule
  • Welcome to Joule's Docs
  • Why Joule?
    • Joule capabilities
  • What is Joule?
    • Key features
    • The tech stack
  • Use case enablement
    • Use case building framework
  • Concepts
    • Core concepts
    • Low code development
    • Unified execution engine
    • Batch and stream processing
    • Continuous metrics
    • Key Joule data types
      • StreamEvent object
      • Contextual data
      • GeoNode
  • Tutorials
    • Getting started
    • Build your first use case
    • Stream sliding window quote analytics
    • Advanced tutorials
      • Custom missing value processor
      • Stateless Bollinger band analytics
      • IoT device control
  • FAQ
  • Glossary
  • Components
    • Pipelines
      • Use case anatomy
      • Data priming
        • Types of import
      • Processing unit
      • Group by
      • Emit computed events
      • Telemetry auditing
    • Processors
      • Common attributes
      • Filters
        • By type
        • By expression
        • Send on delta
        • Remove attributes
        • Drop all events
      • Enrichment
        • Key concepts
          • Anatomy of enrichment DSL
          • Banking example
        • Metrics
        • Dynamic contextual data
          • Caching architecture
        • Static contextual data
      • Transformation
        • Field Tokeniser
        • Obfuscation
          • Encryption
          • Masking
          • Bucketing
          • Redaction
      • Triggers
        • Change Data Capture
        • Business rules
      • Stream join
        • Inner stream joins
        • Outer stream joins
        • Join attributes & policy
      • Event tap
        • Anatomy of a Tap
        • SQL Queries
    • Analytics
      • Analytic tools
        • User defined analytics
          • Streaming analytics example
          • User defined analytics
          • User defined scripts
          • User defined functions
            • Average function library
        • Window analytics
          • Tumbling window
          • Sliding window
          • Aggregate functions
        • Analytic functions
          • Stateful
            • Exponential moving average
            • Rolling Sum
          • Stateless
            • Normalisation
              • Absolute max
              • Min max
              • Standardisation
              • Mean
              • Log
              • Z-Score
            • Scaling
              • Unit scale
              • Robust Scale
            • Statistics
              • Statistic summaries
              • Weighted moving average
              • Simple moving average
              • Count
            • General
              • Euclidean
        • Advanced analytics
          • Geospatial
            • Entity geo tracker
            • Geofence occupancy trigger
            • Geo search
            • IP address resolver
            • Reverse geocoding
            • Spatial Index
          • HyperLogLog
          • Distinct counter
      • ML inferencing
        • Feature engineering
          • Scripting
          • Scaling
          • Transform
        • Online predictive analytics
        • Model audit
        • Model management
      • Metrics engine
        • Create metrics
        • Apply metrics
        • Manage metrics
        • Priming metrics
    • Contextual data
      • Architecture
      • Configuration
      • MinIO S3
      • Apache Geode
    • Connectors
      • Sources
        • Kafka
          • Ingestion
        • RabbitMQ
          • Further RabbitMQ configurations
        • MQTT
          • Topic wildcards
          • Session management
          • Last Will and Testament
        • Rest endpoints
        • MinIO S3
        • File watcher
      • Sinks
        • Kafka
        • RabbitMQ
          • Further configurations
        • MQTT
          • Persistent messaging
          • Last Will and Testament
        • SQL databases
        • InfluxDB
        • MongoDB
        • Geode
        • WebSocket endpoint
        • MinIO S3
        • File transport
        • Slack
        • Email
      • Serialisers
        • Serialisation
          • Custom transform example
          • Formatters
        • Deserialisers
          • Custom parsing example
    • Observability
      • Enabling JMX for Joule
      • Meters
      • Metrics API
  • DEVELOPER GUIDES
    • Setting up developer environment
      • Environment setup
      • Build and deploy
      • Install Joule
        • Install Docker demo environment
        • Install with Docker
        • Install from source
        • Install Joule examples
    • Joulectl CLI
    • API Endpoints
      • Mangement API
        • Use case
        • Pipelines
        • Data connectors
        • Contextual data
      • Data access API
        • Query
        • Upload
        • WebSocket
      • SQL support
    • Builder SDK
      • Connector API
        • Sources
          • StreamEventParser API
        • Sinks
          • CustomTransformer API
      • Processor API
      • Analytics API
        • Create custom metrics
        • Define analytics
        • Windows API
        • SQL queries
      • Transformation API
        • Obfuscation API
        • FieldTokenizer API
      • File processing
      • Data types
        • StreamEvent
        • ReferenceDataObject
        • GeoNode
    • System configuration
      • System properties
  • Deployment strategies
    • Deployment Overview
    • Single Node
    • Cluster
    • GuardianDB
    • Packaging
      • Containers
      • Bare metal
  • Product updates
    • Public Roadmap
    • Release Notes
      • v1.2.0 Join Streams with stateful analytics
      • v1.1.0 Streaming analytics enhancements
      • v1.0.4 Predictive stream processing
      • v1.0.3 Contextual SQL based metrics
    • Change history
Powered by GitBook
On this page
  • Overview
  • What this tutorial is about
  • Who this tutorial is intended for
  • What we will learn
  • Prerequisites
  • Implementation
  • Step 1 - Start up our environment
  • Step 2 - Run the Getting Started example
  • Step 3 - Will start the quote publisher
  • Step 4 - Now review our use case outputs
  • Step 5 - Stop the quotes simulator
  • Step 6 - Shut the environment down
  • What did we learn?
  • What’s next?

Was this helpful?

  1. Tutorials

Getting started

All you need to get started with Joule.

PreviousTutorialsNextBuild your first use case

Last updated 4 months ago

Was this helpful?

The tutorial is built against Version 1.2.1-SNAPSHOT of the platform.

Overview

What this tutorial is about

This tutorial aims to teach how to run a real-time banking example with your first Joule.

Who this tutorial is intended for

We have tailored this tutorial for anyone who wants to learn how to use Joule for the first time and who wishes to learn how to deploy a first use case given that your environment is setup already.

Build your environment with .

What we will learn

By the end of this tutorial, we will have learned:

  1. How to start and stop Joule.

  2. Deploy a first real-time use case.

  3. Access the Redpanda interface to see the deployed use case in action.

Prerequisites

  1. Docker or any other alternative to run containers.

Optional

Only install the below if you do not want to run Docker images of vendor software:

Implementation

Step 1 - Start up our environment

The following steps will guide us on setting up our environment to deploy our images and containers with Joule.

  1. We will clone the repository with this command.

git clone 
https://gitlab.com/joule-platform/fractalworks-stream-gettingstarted/
  1. Once cloned, we will checkout to dev.

git checkout dev
  1. We will navigate to the quickstart directory.

  2. We will make sure that Docker or our alternative is running.

We are now ready to start building Joule. To start Joule, we need to run the following command which will start building our images and containers.

Joule needs to run from the root directory as an example:

pi@raspberrypi:~/projects/fractalworks-joule-platform $ ./bin/startJoule.sh

In the case of this use case, we will run the following command from the ~/quickstart location:

./startupJoule.sh

The command will start up the following containers ready for use case deployment:

  • Joule Daemon

  • Joule Database

  • Redpanda

We should expect this output

Step 2 - Run the Getting Started example

The banking demo directories provides a set of examples in the form of a postman collection and environment. These can be found under the examples directory.

We will now get started running the banking Getting Started demo example using Postman.

  1. First we will import the use case demos and environment files from the banking-demo examples directory.

  1. We will set the Postman environment to Joule.

  1. From the Getting started \ Deploy folder click Run folder from the menu.

  1. Finally execute the run order by clicking the Run Joule - Banking demo button.

This will deploy the source, stream, sink and the use case binding definition to the platform.

Note on a restart these setting will be rehydrated and will automatically start.

We should expect this output

Step 3 - Will start the quote publisher

The banking demo is provided with a quote simulator which is seeded using

./bin/startQuotePublisher.sh

This command will generate a continuous set of quote and publish them to the quotes topic. We will see how to access the topic on the next step.

We should expect this output

Press return to continue.

Step 4 - Now review our use case outputs

Once the processing pipeline completes its tasks, the resulting events are published on to the analytics_view topic ready for further consumption (i.e. distribution, dashboard, dynamic portfolio risk measures etc).

We should expect this output

Step 5 - Stop the quotes simulator

Once we are ready to shut down Joule, we will first stop the quotes publisher by executing the command below.

./bin/stopQuotePublisher.sh

We can now undeploy the use case and its linked components by executing the Run Joule - Banking demo under the Undeploy use case folder.

In case we want to execute complete shut down of Joule, we can instead follow the steps below.

We should expect this output

Step 6 - Shut the environment down

Once quotes publisher has been stopped the Joule environment can now be shutdown. We have 2 options to shut Joule down.

We will execute the following command to shut down the environment.

./shutdownAndCleanJoule.sh

We should expect this output

In case we want to shut down the environment and remove all the created directories, files and containers.

./shutdownJoule.sh

We should expect this output

What did we learn?

We covered essential steps to run our first Joule including cloning the repository and running a first streaming banking use case via Postman.

In summary we have learned:

  1. How to publish continuous data streams with the quote simulator.

  2. How to see our use case in execution in the Redpanda interface.

  3. How to review and process analytics outputs through our default use case.

  4. How to stop, shut down the Joule environment and clean up the system.

What’s next?

Now that we have learned the basics about Joule, it is time to learn how to create our own use case.

Understanding of how to navigate with the command line through directories. Not sure how to navigate with command line? .

Java is installed. Don’t have Java? .

Java version needed

Postman is installed. Don’t have Postman? .

Git is installed. Don’t have Git? .

Redpanda is installed. Don’t have Redpanda? .

Expected result when images built
Postman collection
Setting the environment
Deploying the example
Running the example
Expected result in Postman
Expected result when the quote publisher has started

To learn how to navigate the interface, .

Expected result when Redpanda interface loaded
Expected result when the quote publisher has been stopped
Expected result shutdown and clean Joule
Expected result only shutdown Joule
this tutorial
Follow this tutorial
Follow this tutorial
Follow this tutorial
Follow this tutorial
Follow this tutorial
look at this tutorial

Access the Redpanda interface

Expected result when containers built