Azure API Management Versions Vs Revisions

With the new Version and Revision features its confusing on when to use revisions or versions, my take is as follows

When should you use  Revisions:

  • If you want to do changes that are above your backend services, for example using policies.
    • Add authentication: your api did not have any authentication and you want to have one without disturbing your existing service, so you would add that in the in the new revision
    • Logging: you api did not have any logging of incoming and outgoing requests and you don’t want to disturb your backend service so you create a revision for that feature
  • Note: only 1 revision is exposed to the outside world

When should you use Versions:

  • Use versions when you introduce a breaking change in your api and deploy it as a new backend server and want to support both those deployments.

Increase Timeout for ASP.NET Core applications

Recently we came across a situation where in we had to increase the timeout of a aspnet web application, by default an aspnet core project does not generate a web.config file and did not find enough documentation on how to modify the appsetting.json file.

 

Google always ended up showing on how to do that in a web.config, which we did not have. After playing around we found that we could add a web.config to the solution

 

 

And add the following, there might be better ways of doing it, but wonder why Visual Studio (using 2017) does not add a web.config file automatically ?? maybe another blog post.

 

  1. <?xml version=“1.0” encoding=“utf-8”?>  
  2. <configuration>  
  3.   
     
  4.   <!– To customize the asp.net core module uncomment and edit the following section.   
  5.   For more info see https://go.microsoft.com/fwlink/?linkid=838655 –>  
  6.     
     
  7.   <system.webServer>  
  8.     <handlers>  
  9.       <remove name=“aspNetCore”/>  
  10.       <add name=“aspNetCore” path=“*” verb=“*” modules=“AspNetCoreModule” resourceType=“Unspecified”/>  
  11.     </handlers>  
  12.     <aspNetCore processPath=“%LAUNCHER_PATH%” arguments=“%LAUNCHER_ARGS%” stdoutLogEnabled=“false” stdoutLogFile=“.\logs\stdout”   
  13.                 requestTimeout=“00:20:00”/>  
  14.   </system.webServer>  
  15.     
     
  16. </configuration>