Can I setup SignalR for Azure API Apps? - signalr

I am using Azure Api App and having a need of push notifications back to client devices. Does Azure Api App support this?

Yes, you can host your SignalR hub in an Azure App Service API app. That said, an App Service Web app works fine as well. In fact, that is my recommendation unless you need the incremental features provided by API Apps for other scenarios. In particular, you avoid the need for the gateway that is part of API Apps.

Related

How to create the webhook receiver kind of in Xamarin form(Android and iOS)?

I want to create the Xamarin Form app for both android and iOS in which when something events occurs or data update on server than server call my xamarin app and i will perform some task in my app. Push notification and SignalR both are not suitable for my case. is there anything like webhook in Xamarin form. There are many example for Web application but nothing i found in case of mobile application.
You can use the RESTful web service as a webhook.
Representational State Transfer (REST) is an architectural style for building web services. REST requests are made over HTTP using the same HTTP verbs that web browsers use to retrieve web pages and to send data to servers.
More informations you can refer to this website:
https://learn.microsoft.com/en-us/xamarin/xamarin-forms/data-cloud/web-services/rest

Azure - Sending data from IoT Hub to Web App Backend

I'm searching for a solution to get data from the Azure IoT Hub to the backend of a Web App also hosted in Azure which is written in ASP.NET 4.6.
It would be best to just receive the raw Json string as fast as possible.
I found others suggesting using Webhooks or Azure functions for a similar purpose but the delay these solutions bring aren't really acceptable.
It would be best to just connect directly to the IoT endpoint and get every message as it comes in. Can anybode please point me to the right direction?
You can simply use the EventHub .NET SDK in your web app, connect to the EventHub-compatible endpoint of the IoT Hub and directly consume the events in your app. This has minimal delay and involves no extra components.
How to guide (.NET core but same applies to .NET Framework): https://learn.microsoft.com/en-us/azure/event-hubs/event-hubs-dotnet-standard-getstarted-send#receive-events
var eventProcessorHost = new EventProcessorHost(
EventHubName,
PartitionReceiver.DefaultConsumerGroupName,
EventHubConnectionString,
StorageConnectionString,
StorageContainerName);
// Registers the Event Processor Host and starts receiving messages
await eventProcessorHost.RegisterEventProcessorAsync<SimpleEventProcessor>();
The Azure SignalR Service can help to broadcast messages to the Web App instances.
There are no direct integration between the Azure IoT Hub and Azure SignalR Service. Basically you can use two patterns for this integration such as PULL-PUSH and PUSH-PUSH.
The following screen shows these integration patterns:
Note, that the PUSH-PUSH pattern with the Azure Event Grid is suitable for solution when the subscriber (consumer) is not critical for processing events in the order.

SignalR performance counters in Azure Web App

I've been trying to load test SignalR on my Azure Web App service (E.g. how many connections it can handle before subscribe calls to the hub start failing). I found that SignalR perfomance counters (https://www.asp.net/signalr/overview/performance/signalr-performance ) can provide me such info. However, I cannot install those performance counters on Web App service, buy running
SignalR.exe ipc
Is there a way to install those performance counters on WebApp or retrieve them somehow from code?
Performance Counters can't be installed on Azure Web App, as it is provided as a managed container and not a full fledged IIS on which you can do everything.
To be able to use these performance counters you can redeploy your solution on an Azure VM or to a Cloud Service, keeping in mind you will loose the flexibility that Azure Web App offers.
You can expose the SignalR performance counters in an Azure Web App using a WebRole, as stated in this article

Which way i should connect My Android Device with ASP.NET Web API and Signal R

I have an Android App which i had currently connected with Asp.NET Web API and Now i have to implement SignalR 2 Stuff in the Web API. Now should i connect my Android App with Web API and connect Web API with SignalR (does it give me unique ConnectionID for every different request obtained so that i can check which devices are currently connected) or I have to connect SignalR and then Connect my SignalR with Web API for database work. Which flow i should follow as i want an immediate response as well as persistance of data.

google cloud endpoints configure "service accounts" for Google OAuth 2.0 endpoint supports server-to-server interactions

I am implementing Cloud Endpoints with a Python app, I need to expose the restAPI in a secure way https (this is authomatic), The consumer of this Endpoint will be a java Application (not a web browser or app android or ios), and my questions is if there are any way to limit the consume od this Services only for that application.
I've seen "Service Account" oauth but i don't know if i can use it for this problem and if is possible i don't know how to configure it.
Thanks a lot.

Resources