Achraf Ben Alaya
No Result
View All Result
  • News
  • Blog
    • blazor
    • c#
    • Cloud
      • Azure
    • docker
    • sql
    • xamarin
    • Tricks, Tips and Fixes
  • Cloud
  • Motivation
  • General Tips & Fix
  • About
SUBSCRIBE
  • News
  • Blog
    • blazor
    • c#
    • Cloud
      • Azure
    • docker
    • sql
    • xamarin
    • Tricks, Tips and Fixes
  • Cloud
  • Motivation
  • General Tips & Fix
  • About
No Result
View All Result
Achraf Ben Alaya
No Result
View All Result
Home

Migrate and modernize your applications on Azure – Part 2.0 (Proxy Function)

achraf by achraf
April 3, 2021
in Azure, Blog, Cloud
0
Migrate and modernize your applications on Azure
0
SHARES
25
VIEWS
Share on FacebookShare on Twitter

What are Azure Function Proxies?

Azure Function Proxy are quite similar to Azure API management but they are not the same ,they allow us to define a single API surface for multiple function apps.

Azure Function Proxy is a unified API layer (façade) on top of Azure functions hosted inside the Application Service container. A proxy exists as a set of additional HTTP endpoints in front of functions based apps. One important note, proxy calls are billed the same way as Azure Functions. Because proxy is essentially another function, that is pre-warmed and always ready to receive requests.
Now any function app can define an endpoint that serves as a Reverse Proxy for another API. The endpoint can be a function app or it can be anything else.

But Why we need proxy Function ?

In a high load enterprise solution we use APi Management but since we are working with very simple projects and for the best practice for medium and low load solution the best choice is to use azure Functions Proxy .
Azure Function Proxies come to the rescue by providing a unified URI (Uniform Resource Identifier) which the client can actually consume. In the meantime, we can abstract all of the different function apps or other APIs and it would also enable us to build our API at a faster rate.

Creating Our proxy

First of all we need to create a new azure function from the portal and after it’s created we need to :

  1. Navigate to the function app in the portal.
  2. Click New proxy.
  3. Provide a Name for your proxy, such as “HiProxy”.
  4. Set the Route template to /api/Task.
  5. In Backend URL, enter the URL for the HttpTrigger you created on the backend app.
    Click Create.
  6. Copy the Proxy URL, and then use Postman or the HTTP client of your choosing, and send a GET request that URL.

In our case this is what the proxy will look like :

{
"$schema": "http://json.schemastore.org/proxies",
"proxies": {
"/api/Task": {
"matchCondition": {
"route": "/api/Task",
"methods": [
"POST"
]
},
"backendUri": "http://proxyfunction01.azurewebsites.net/api/CreateTodo"
},

"Collection redirect": {
"matchCondition": {
"route": "/api/Task",
"methods": [
"GET",
"OPTIONS"
]
},
"backendUri": "https://to-do-api.azurewebsites.net/api/Task"
},

"Item redirect": {
"matchCondition": {
"route": "/api/Task/{id}",
"methods": [
"GET",
"OPTIONS",
"DELETE",
"PUT"
]
},
"backendUri": "https://to-do-api.azurewebsites.net/api/Task/{id}"
}


}
}

In order to understand all the steps you can enjoy the below video

 

ShareTweet
Previous Post

Migrate and modernize your applications on Azure – Part 2.0 (Azure Functions)

Next Post

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

Related Posts

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps
Azure

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

April 14, 2021
33
Migrate and modernize your applications on Azure
Azure

Migrate and modernize your applications on Azure – Part 2.0 (Azure Functions)

April 3, 2021
12
Migrate and modernize your applications on Azure – Part –1 (Migrate Database)
Azure

Migrate and modernize your applications on Azure – Part –1 (Migrate Database)

April 3, 2021
7
Migrate and modernize your applications on Azure
Azure

Migrate and modernize your applications on Azure – Part –1 (Create and publish Web App)

April 3, 2021
8
Migrate and modernize your applications on Azure
Azure

Migrate and modernize your applications on Azure – Part – 00 (creating .Net 5.0 application )

March 29, 2021
9
Migrate and modernize your applications on Azure
Azure

Migrate and modernize your applications on Azure

March 26, 2021
61
Next Post
Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recommended

My book collection for 2020-2021

My book collection for 2020-2021

December 28, 2020
135
Deploy azure function from visual studio 2019

Deploy azure function from visual studio 2019

August 29, 2020
107
How to make the most of each day

How to make the most of each day

February 2, 2021
51
You forget to shutdown your virtual machine on your way home ? send an email and save your time

You forget to shutdown your virtual machine on your way home ? send an email and save your time

February 6, 2021
64
Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

April 14, 2021
33
Deploy azure function from Docker Hub CI/CD

Deploy azure function from Docker Hub CI/CD

April 27, 2020
101
Facebook Twitter LinkedIn Youtube
Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

Auto Post and Schedule Tweets & Linkedin using Azure Logic Apps

April 14, 2021
Migrate and modernize your applications on Azure

Migrate and modernize your applications on Azure – Part 2.0 (Proxy Function)

April 3, 2021
Migrate and modernize your applications on Azure

Migrate and modernize your applications on Azure – Part 2.0 (Azure Functions)

April 3, 2021

Categories

  • Apps (1)
  • Azure (25)
  • blazor (2)
  • Blog (43)
  • c# (6)
  • Cloud (24)
  • docker (2)
  • Games (1)
  • General Tips & Fix (1)
  • motivation (1)
  • Motivation (3)
  • News (7)
  • sql (3)
  • Tricks, Tips and Fixes (1)
  • xamarin (5)
No Result
View All Result
  • News
  • Blog
    • blazor
    • c#
    • Cloud
      • Azure
    • docker
    • sql
    • xamarin
    • Tricks, Tips and Fixes
  • Cloud
  • Motivation
  • General Tips & Fix
  • About