Part of the Serverless Azure-based .Net 2.0 Standard Broadcast solution. See this client library repository for more.
These Azure Functions are part of the Bitfox.AzureBroadcast feature and should be used in combination with a Azure SignalR service in Serverless mode and the Bitfox.AzureBroadcast.Client for easy real-time messaging in .Net 2.0 Standard solutions. For example: Desktop applications (WPF/WinForms) in need of an easy interclient communication, comparable with UDP broadcasting on a local network.
In any .Net 2.0 Standard solution:
var client = new BroadcastClient<string>('endpoint-of-azure-functions','hostkey');
client.onMessage = (msg, info) => {
//do something useful with received messages;
}
client.Start();
client.Broadcast("Hello World!");
- Create the Azure SignalR service in Azure Portal
- Change the service Feature Flag
- Copy and save the service endpoint in settings/key menu for later use.
- Use the Azure portal to setup an Azure Function.
- Within the created Azure Function navigate to Platform Features / Application Settings.
- Add new Application Setting with the name
AzureSignalRConnectionString
and the value of the Azure SignalR endpoint as recorded in step 3. - Deploy the functions (see below)
- Write down the default host key found when you click on manage on one of the deployed functions.
Use the latest release on Github tab releases to get the precompiled functions as zip. Upload the zipfile in the Azure Portal.
Clone this repo. You will need .net 2.x SDK for building.
dotnet restore
dotnet build
dotnet publish --configuration Release
- Deploy from Visual Studio Code
Install the Azure Functions extension, this allows easy deployment directly from vs-code.
- Zip file deployment.
Download the latest release zip file s.zip
from the GitHub release tab. Go to https://.scm.azurewebsites.net/ZipDeployUI and drop the zip file.
- Use the
Get publish profile
option in the overview page of the Azure Function in the Azure Portal. Publish with MSDeploy.
Go to the Azure Portal Function
Go to the info
function, this function is reachable anonymous, without a host key. And click 'run'.