Azure Files Streaming Configuration
This document provides information on how to configure Azure Files connection with real-time events monitoring and data streaming.
Last updated
Was this helpful?
This document provides information on how to configure Azure Files connection with real-time events monitoring and data streaming.
Last updated
Was this helpful?
Existing Azure Files connection: An Azure Files scan configuration must already exist.
If an Azure Files scan does not already exist, follow this guide to create a new Azure Files scan and ensure the necessary credentials are set up.
Go to the Scan configurations page in the product UI.
Locate your existing Azure Files scan configuration and select Edit Configuration from the options menu. Note the configured path (folder) and save it, as it will be used in step 9 to replace {FolderPath}
.
Within the Edit Azure Files Scan Configuration page, toggle Data Streaming to ON.
Copy the Webhook URL provided, as you will use it later in the Azure Portal. Save this Webhook URL, as it will be used in step 9 to replace {WebhookUrl}
.
Click Save & Close button to save configuration.
Navigate to Azure Portal Event hubs and click Create
In Create Namespace Window fill in the details
Give it a Name
Select your subscription and resource group
Select location
Pricing tier - standard
Throughput Units - 1
Click on Review + Create and then Create after validation
After namespace is created, click on + Event Hub button
In Create Event Hub Window fill in name and click Create + Review and Create after validation. Save the name of the Event Hub you created in this step, as it will be used later in step 9 to replace {eventHubName}
.
Configure access policy
In the event hubs namespace window click on Settings/Shared access policies and then +Add button
Fill in the details in the new tab, set LogicAppsListenerPolicy as name, select Listen policy, and click Save.
Click on the newly created policy, then copy and save the Connection string–primary key. This will be needed later in step 8b.
Navigate to Azure Portal and open your Storage Account.
Select needed account from the Storage Accounts
In the left-hand menu, select Monitoring/Diagnostic settings and click file
In Diagnostic settings Window click on "+ Add diagnostic setting" button
In Create Diagnostic setting Window fill in the details:
Give it a Name
Select Category groups allLogs
Select Destination details Stream to an event hub and select newly created Event Hub Namespace and Event Hub
Click Save.
Go to Azure logic apps and click "Add" button
In Create Logic App Window select Workflow Service Plan
In Create Logic App (Workflow Service Plan) Window fill in the details and click "Create + Review":
Select your subscription and resource group
Give logic app name
Select region
Pricing plan should be WS1
In the monitoring tab select No for the application insights
Click Review + create button
Click Create after validation
In newly created logic app click on Workflows/Workflows and then +Add button
In new workflow tab fill in name, select State type: Stateful and click Create
In created workflow go to Developer/Designer and click on Add a trigger, then in search type "Event hub" and select "When events are available in Event Hub"
Configure API connection
Click on the trigger, set "Temp" for Event Hub Name and then click on Change connection.
Then click Add New and fill in the details. Enter any name for the connection name and use the connection string {Connection string–primary key}
from step 3.6.c.
On the Change Connection tab, click Details and copy the Name from the connection details. Save this Name, as it will be used later in step 9 to replace {connectionName}
.
Click save on workflow designer window
In workflow navigation tab go to Developer/Code and set the provided code, then click save:
Replace {FolderPath}
with a path to the streaming folder. For ex., you want to get events from the folder "StreamingFolder" which is located in file share with the name "DocumentsShare" and in the folder with the name "Personal". In this case, the path should be "DocumentsShare/Personal/StreamingFolder"
Replace {WebhookUrl}
with webhook url provided in the application in the scan configuration window
Replace {eventHubName}
with azure event hub name that was created previously
Replace {connectionName}
with connection name from previouse step
After configuring the event subscription:
You may upload documents to the configured path.
The events triggered by these uploads will be processed by the Data Streaming setup, and the results will appear in your Getvisibility dashboard.
If you experience any issues with the configuration, ensure that:
The Webhook URL is correct and matches the configuration in Azure.
Steps 5.8 and 5.9 properly executed and all the variables are replaced with real values.
You can also check if the trigger was unsuccessful by navigating to your configured in previos steps Logic App, then Workflow and Trigger History. If you see any failed triggers, you can inspect the error details to identify the issue.