Skip to content

Commit

Permalink
Merge pull request #20 from hazelcast-guides/DOCS-750-Update-Viridian…
Browse files Browse the repository at this point in the history
…-airlines-connection-tutorial

Renaming Viridian > Cloud
  • Loading branch information
rebekah-lawrence authored Apr 11, 2024
2 parents 9651ae6 + 26a792b commit 1da34fb
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 11 deletions.
Binary file modified docs/modules/ROOT/images/cli_setup_window.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 26 additions & 11 deletions docs/modules/ROOT/pages/airline-connections.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
:page-lang: sql, java
:page-enterprise:
:page-est-time: 20 mins
:description: This tutorial provides detailed information and instructions for the Airline Connections demo built in to Viridian Trial.
:description: This tutorial provides detailed information and instructions for the Airline Connections demo, which is built in to Hazelcast Cloud Trial.

{description}

Expand All @@ -27,24 +27,24 @@ Specifically, you will learn how to
* Use SQL to import data from an external database
* Configure late event handling for streaming data
* Join streaming and stored data to generate continually updated results
* Submit a job to Viridian using the Command Line Client
* Submit a job to {hazelcast-cloud} using the Command Line Client

When you launch the demo in Viridian, you may see a step-by-step guide appear in conjunction with the demo. This tutorial is designed to supplement that guide, providing additional context and detail as well as links to reference materials.
When you launch the demo in {hazelcast-cloud}, you might see a step-by-step guide appear in conjunction with the demo. This tutorial is designed to supplement that guide, providing additional context and detail as well as links to reference materials. You can launch the step-by-step guide at any time by selecting the *Walk me through this Demo* link above the SQL browser.

== Before you Begin

Before starting this tutorial, make sure that you meet the following prerequisites:

* You have a running cluster in Viridian Trial
* You have a running cluster in {hazelcast-cloud} Trial
* You've downloaded and connected the Command Line Client to your cluster
* For the client, you will need
** Java 11 or greater
** Maven 3.9.0 or geater
** Java 17 or later
** Maven 3.9.0 or later
* (Optional) Java IDE to view client code

== Step 1. Review What's Already Set Up

Begin by selecting the Airline Connections demo from the Viridian dashboard. This launches a pre-set configuration and opens the SQL browser window.
Begin by selecting the Airline Connections demo from the {hazelcast-cloud} dashboard. This launches a pre-set configuration and opens the SQL browser window.

The pre-set configuration includes the following elements:

Expand All @@ -53,7 +53,11 @@ The pre-set configuration includes the following elements:
* Mappings for IMaps to hold contextual data
* Data imported from Postgres to local IMaps

The best way to build connections to external sources is to use the Connection Wizard. The wizard walks you through the steps of connecting to the external data source, then setting up the mapping so that the external data is available to the Hazelcast SQL engine
=== Manual Set Up

To illustrate how the pre-set configuration would be done in the console, we provide the details below.

The best way to build connections to external sources is to use the Connection Wizard, which guides you through the steps needed to connect an external data source. You can then set up the mapping to make the external data available to the Hazelcast SQL engine

image:connectwiz.gif[Walkthrough of Connection Wizard]

Expand Down Expand Up @@ -295,8 +299,18 @@ If you already have CLC open, you can submit the script from the CLC> prompt.
\script connections_job.sql
```

. Watch the size of `my-map` increase as entries are written to it.
+
[NOTE]
====
With a Standard or Dedicated license, you could view processing statistics and the DAG for this job as follows:
. Go to the dashboard for your cluster and open Management Center.
. In Management Center, select Stream Processing > Jobs. You should see a job called `update_connections`. Click on the job name to view processing statistics and the DAG for this job.
. In Management Center, select Stream Processing > Jobs.
. Locate the job called `update_connections`.
. Select the job name.
====

. In either the SQL browser tab or the CLC, view the contents of the IMap that stores the output of the job.
+
```sql
Expand All @@ -306,6 +320,7 @@ SELECT * FROM live_connections;
[NOTE]
====
Because you are searching the contents of an IMap, the results of the above `SELECT` are a "one and done" search. If you run the search multiple times, you will see different results, as the job is continuously updating the IMap. Your search will always display the latest data available _at the time of the search_.
====
== Step 5. Run Client
The connection data is now stored in Hazelcast and is being continually updated. Now let's make that data available to the end application that will use it.
Expand All @@ -325,7 +340,7 @@ mvn clean package exec:java -Dexec.mainClass=hazelcast.platform.labs.airline.Air
====
Hello Hazelcast testers! If you get an error regarding keystores with the above command, follow these steps:
* Go to your Viridian cluster dashboard and select the Java client icon
* Go to your {hazelcast-cloud} cluster dashboard and select the Java client icon
* Under "Advanced Setup", select "Download keystore file".
* Find your CLC home directory with `clc home`.
* Copy the zipped keystore to `$CLC_HOME/configs/<your cluster name>`
Expand All @@ -349,7 +364,7 @@ In this tutorial/demo, you learned how to:
* Use SQL import data from an external database
* Configure late event handling for streaming data
* Join streaming and stored data to generate continually-updated results
* Submit a job to Viridian using the Command Line Client
* Submit a job to {hazelcast-cloud} using the Command Line Client


== See Also
Expand Down

0 comments on commit 1da34fb

Please sign in to comment.