Jeff Sanders Technical Blog

I am a Microsoft employee that has worked on all aspects of the Web Stack for a long time. I hope these blogs are useful to you! Use this information at your own risk.


Earlier Posts

You can add Push Notification Hubs to your Azure Web App, Azure Api App etc… (all Azure App Services).  If you try to use the portal to add Push (a Notification Hub) to a Slot however this will fail.  You will see the portal will just sit there with the message: “Connecting Web App to Notification Hub” forever.


Here are some simplified instructions on how to setup and use Azure Active Directory authentication for Azure App Services and code that will allow an application to use a Bearer Token to access that app.


Here are some simplified instructions on how to setup and use Azure Active Directory authentication for a client Azure App Services application and code that will allow a client application to use a Bearer Token to access a different target app.   In this scenario there are two web apps.  The client app is the app that has code to call to the target app.  Anyone can reach the client app without authentication and the client app then uses a Bearer token to access the target app which requires Active Directory Authentication.  This assumes you have already created both apps in the Azure Portal


Calling Register or RegisterAsync in the client code can result in a 400 status code coming back with an inner exception of: ‘Cannot read property ‘listRegistrationsByTag’ of undefined’


Your Azure Web App (or any Azure App Service) has authentication enabled but you want to use Traffic Manager.  Since the probe returns the HTTP status code 401, the endpoint is considered degraded.  This blog only applies to Azure App Service Authentication.  If you are using a third Party like Auth0 you need to provide a non-authenticated URL using a different method.


There are a ton of blogs on getting full memory dumps but some get complicated.  Note then when you create a full memory dump it will have the effect of pausing your web app so use this judiciously!  Here is my simple version


Sometimes it is difficult to isolate Azure App Service issues to determine is the problem is the client or server.  You can remove the client easily using a tool like Fiddler or Postman however is you are using authentication there are some tricks you need to use.  I will demonstrate this with Azure Mobile Apps, but this will work with any Azure App Service using authentication.


Sometimes it is difficult to isolate Azure App Service issues to determine is the problem is the client or server.  You can remove the client easily using a tool like Fiddler or Postman however is you are using authentication there are some tricks you need to use.  I will demonstrate this with Azure Mobile Apps, but this will work with any Azure App Service using authentication.


I had someone ask how to run an async task in Main of a console app.  Yes there are different ways to do it and this is just one!


You could use the Azure CLI to create Azure Mobile Service tables for the node.js backend.  You can no longer do this but there is a much easier solution.  You can simply drop a .json file in the ‘Tables’ directory and when the app starts it will create the table in the database and make it accessible to the /tables/ route in your Azure Mobile App.  This only works for the node.js backend.


Using the Azure Mobile App API interface (like: https://mymobileapp.azurewebsites.net/api/doTransActionStuff ) with a node.js backend, I found documentation around executing SQL Transactions a little light.  So… Here are some options you could use:


If you want to deny HTTP methods or verbs in Azure Web Apps you can do this be changing your web.config file.