Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Task 02: Create a KQL database and an Eventstream

Introduction

To ensure optimal in-store conditions during Zava’s Thanksgiving sale, the operations team needs near real-time visibility into IoT telemetry such as thermostat readings. In this task, you’ll create an Eventstream and prepare a KQL database to ingest streaming data for real-time analysis and anomaly detection.

Description

In this task, you’ll create an Eventstream and configure a KQL database to ingest and store streaming telemetry data.

Example scenario

Zava needs a scalable way to capture and analyze IoT data as it arrives.

Success criteria

Streaming data appears in the KQL database and can be queried.

Learning resources

  • Eventstream concepts
  • KQL databases in Fabric

Key steps

01: Create an Eventstream and ingest data into a KQL database

  1. Open Microsoft Edge and go to Power BI homepage.

  2. If prompted, sign in.

  3. In the left pane, select the Zava@lab.LabInstance.Id workspace.

    gphbgcea.jpg

  4. On the workspace page, select + New item.

    dypvdnir.jpg

  5. In the New item window, in the Get data section, select Eventstream.

    40b2djlz.jpg

  6. In the Name field, enter RealtimeDataToKQLDB@lab.LabInstance.Id and then select Create.

    ud6ydfpv.jpg

  7. On the Eventstream canvas, select Connect data sources.

    eda44l1t.jpg

  8. In the Select a data source dialog, select evh-@lab.LabInstance.Id.

    3um4zgl7.jpg

  9. In the configure connection settings dialog, in the Select an Azure Event Hubs field, select thermostat.

  10. In the Select an Azure Event Hub Key field, select RootManagedSharedAccessKey.

    jdatrxqh.jpg

  11. Select New Connection.

    7nu1xsio.jpg

  12. Select Connect.

    xi9oa0ug.jpg

    The values for the Connection settings dialog should be prepopulated for you.

  13. Select Next.

    ak3znurp.jpg

  14. Select Add.

    uqbrxtkq.jpg

  15. On the command bar, select Add destination and then select Eventhouse.

    zhscjphq.jpg

  16. Configure the Eventhouse pane by using the following information:

    Field Value
    Destination name Eventhouse@lab.LabInstance.Id
    Workspace ZavaSales@lab.LabInstance.Id
    Eventhouse thermostat
    KQL database thermostat
    Table thermostat

    For the Eventhouse and KQL Destination table fields, you’ll need to select Create new to add the resource.

    y1qoadlq.jpg

  17. Select Save.

    ktdxav3w.jpg

  18. Place your mouse cursor over the green circle that appears on the right side of the RealtimeDataToKQLDatabase node on the canvas.

    ttor3bfy.jpg

  19. Hold your left mouse button down and drag the cursor to the red circle that appears on the left side of the Eventhouse@lab.LabInstance.Id node. This creates a connection between the nodes. Your canvas should resemble the screenshot below.

    uzxro3dn.jpg

  20. Select Publish.

    bwfhdxi9.jpg

  21. Once the data starts streaming into EventHub, you can see the data in the Data preview pane that appears at the bottom of the window.

    It may take several minutes before you start seeing data. On the design canvas, the status for the Eventhouse@lab.LabInstance.Id node changes from Loading to Ready once the resources are ready to ingest data.

    u8tmbusc.jpg

  22. Do not proceed to Task 3 until the Data preview pane displays records.

    k9yjwntv.jpg