Serverless services or FaaS like Azure Functions lets you run code without provisioning or managing servers. You pay only for the compute time you consume there is no charge when your code is not running. You can run code for virtually any type of application or backend service all with zero administration. Just upload your code and FaaS provider would take care of everything required to run and scale your code with high availability. You can set up your code to automatically trigger other services or call it directly from any web or mobile app.
You can read more about FaaS or Serverless here.
Quick Snapshot
A function app lets you group functions as a logic unit for easier management, deployment, and sharing of resources.
Once you login to Azure Portal,Click the New button on the upper left-hand corner of the Azure portal, then select Compute > Function App.
On the Function app,choose App name,Resource group appropriately
The hosting plan defines how resources are allocated to your function app. Default is Consumption Plan, resources are added dynamically as required by your functions.
Click on ‘Create’ to create a new function app.
So now we have a function app, the next step is to create a new function that gets triggered by the HTTP request.
On the left-hand side, under the new Functions app, Click on ‘+’ to create new function.
Choose Webhook + API scenario since we are going to create a function based on the HTTP trigger. Appropriate language can be chosen, I’m going ahead with default language CSharp.In the next step, we can write a sample code to print Hello <user>
Now that a new function is created, we can test it by issuing HTTP request.
Below is the console where you can modify the code if needed since this is an example, I’m going to the next step. Below code parses query parameter & sets it to a variable then printed.
There is an option to test the code inside the console itself.
Copy the function URL.
To the function URL append query parameter &name=<name>
and make request to the function.
Congrats! you have now created a function app that can be triggered by the HTTP request. In the next article, we can check on how to store the requested data on Azure Cosmos DB.
Like this post? Don’t forget to share it!
There are few things as valuable to a business as well-designed software. Organizations today rely…
The cryptocurrency industry is being reshaped by the fusion of blockchain technology and artificial intelligence…
Introduction Artificial Intelligence (AI) has also found its relevance in graphic design and is quickly…
Imagine a world where the brilliance of Artificial Intelligence (AI) meets the unbreakable security of…
In today’s fast-paced digital landscape, automation is not just a luxury but a necessity for…
The world of casino gaming has leveraged the emerging technology advancements to create immersive and…
This website uses cookies.