Contents
Cirrus Link Resources
Cirrus Link Website
Contact Us (Sales/Support)
Forum
Cirrus Link Modules Docs for Ignition 7.9.x
Inductive Resources
Ignition User Manual
Knowledge Base Articles
Inductive University
Forum
Info | ||
---|---|---|
| ||
We are in the process of updating this documentation for the upcoming release of the IoT Bridge for Snowflake v2.0.0. The documentation AWS Quickstart for the IoT Bridge for Snowflake v1.0.0 through v1.0.3 can be found here. |
...
If you don't have a Snowflake account, open a Web Browser and go to https://www.snowflake.com. Follow the instructions there to start a free trial. After creating an account, log in to Snowflake via the Web Console. You should see something like what is shown below.
Create a new 'SQL Worksheet' by clicking the blue + button in the upper right hand corner of the window as shown below.
Copy and paste SQL Script 01 from Snowflake Setup Scripts into the center pane of the SQL Worksheet, click the drop down arrow next to the blue play button in the upper right corner of the window and click 'Run All' as shown below.
After doing so, you should see a message in the 'Results' pane denoting the SPARKPLUG_RAW table was created successfully as shown below.
Now, repeat the process for each of the following scripts in the Snowflake Setup Scripts in order. Each time, fully replace the contents of the SQL script with the new script and click the 'Run All' button after pasting each script. Make sure no errors are displayed in the Results window after running each script.
SQL Script 02 Expected Result: Stream NBIRTH_STREAM successfully created.
SQL Script 03 Expected Result: Function GENERATE_DEVICE_ASOF_VIEW_DDL successfully created.
SQL Script 04 Expected Result: Function CREATE_EDGE_NODE_SCHEMA successfully created.
SQL Script 05 Expected Result: Function CREATE_ALL_EDGE_NODE_SCHEMAS successfully created.
SQL Script 06 Expected Result: Statement executed successfully.
SQL Script 07 Expected Result: Statement executed successfully.
SQL Script 08 Expected Result: Statement executed successfully.
After all of the scripts have successfully executed, create a new user in Snowflake. This user will be used by IoT Bridge for Snowflake to push data into Snowflake. In the Snowflake Web UI, go to Admin → Users & Roles and then click '+ User' in the upper right hand corner. Give it a username of your choice and a secure password as shown below. For this example we're calling the user IBSNOW_INGEST so we know this user is for ingest purposes. See below for an example and then click 'Create User'.
Warning |
---|
Force user to change password on first time login must be set to False. |
In addition, the user must have a specific role to be able to stream data into Snowflake. Click the newly created user to see the following.
In the bottom of the center 'Granted Roles' pane you will see this user has no roles. Click 'Grant Role' to set up a new role. Then, select the 'CL_BRIDGE_PROCESS_RL' role and click 'Grant' as shown below.
After this has been done successfully you will see the role now associated with the new user as shown below.
Now an unencrypted key pair must be generated and uploaded to Snowflake. This will be used for authentication by the IoT Bridge for Snowflake application to push data to Snowflake via the Snowflake Streaming API.
Attach the generated unencrypted public key to the IBSNOW_INGEST user that we just created for Snowflake ingest purposes.
...
See this document for details on how to generate this unencrypted key and assign this to a user in your snowflake account: https://docs.snowflake.com/en/user-guide/key-pair-auth.
Note: The step "Configuring the Snowflake Client to User Key Pair Authentication" in the linked tutorial can be skipped.
Find the IoT Bridge Setup Assistant Snowflake application in the Snowflake Marketplace and install it. This application will aid in creating and configuring all required Snowflake databases, stored procedures, user defined functions, roles, warehouses, etc.
<Screenshot Placeholder: IoT Bridge Setup Assistant Snowflake application in the Marketplace>
Once the IoT Bridge Setup Assistant is installed, launch it by navigating to the application under Data Products → Apps.
<Screenshot Placeholder: IoT Bridge Setup Assistant Snowflake application running post-install>
Navigate to 'Setup Step 1' to accept default configuration as it defined or customize the configuration as desired. Note the cl_bridge_reader_warehouse must already exist and the cl_bridge_snowflake_user_public_key must contain the public key created following the steps below.
Generate an unencrypted key pair and copy the public key contents into the cl_bridge_snowflake_user_public_key text area. This will be used for authentication by the IoT Bridge for Snowflake application to push data to Snowflake via the Snowflake Streaming API.
Tip | ||
---|---|---|
See this document for details on how to generate this unencrypted key pair: https://docs.snowflake.com/en/user-guide/key-pair-auth. The IoT Bridge Setup Assistant will create the required IoT Ingest user and assign the public key provided to this user. Note: The step "Configuring the Snowflake Client to User Key Pair Authentication" in the linked tutorial can be skipped.
|
<Screenshot Placeholder: IoT Bridge Setup Assistant Snowflake 'Setup Step 1'>
When 'Setup Step 1' configuration is finalized, click the 'Setup Environment' button and wait for the step to complete. Once complete, navigate to 'Setup Step 2'. This step will output a custom Snowflake SQL script with the configuration provided in Step 1 and this script will create all required Snowflake artifacts when executed.
To run this script, follow the instructions in 'Setup Step 2'.
<Screenshot Placeholder: IoT Bridge Setup Assistant Snowflake 'Setup Step 2'>
Once Step 2 is complete, the application will display the following message indicating that setup is now complete.
<Screenshot Placeholder: IoT Bridge Setup Assistant Snowflake 'Setup Complete'>
...
First you will need access to the Snowflake IoT Bridge EC2 instance via SSH. See this document for information on how to do this.
...