Serverless architecture - Azure functions #edge [closed] - azure

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
We have below technical stack in our application
Angular 7
Asp.net core 2.2
Sql server
Images
To go for serverless architecture on Azure, we have map as follows
Angular 7 - Blob (as it is static)
Asp.net core 2.2 - Azure functions
SQL server - SQL as a service
Images - Blob
Now how to handle Azure functions#Edge ?
Do we have alike Lambda#Edge in AWS?

As far as I know there's no equivalent Azure service right now. In fact, back in October 2018, the comparison between Lambda#Edge and Azure IoT Edge was removed from the Services Comparison page.
The equivalent right now would be to use CloudFlare Workers combined with Azure Functions. Troy Hunt explains how he did just that to scale Have I Been Pwned in Serverless to the Max: Doing Big Things for Small Dollars with Cloudflare Workers and Azure Functions. The site has a lot of traffic and Troy Hunt pays for it out of his own pocket. Workers on the edge means that Have I Been Pwned doesn't have to hit Blob storage in most cases.
Right now this may be a very good choice. Cloudflare Workers are faster than Lambda#Edge at this point and CloudFlare offers very good caching, proxying and DDOS protection services. You'll have to consider startup time too. Javascript functions can start faster than Java or .NET Core functions, which means they can handle cold starts and request bursts better.
All of this will certainly change in the future. Functions on the edge is a lucrative market. Lambda#Edge will definitely get faster. Azure may add its own service or cooperate with CloudFlare.

Two questions:
1. Why not use any CDN on azure in order to server your static files? Blob storage is not for static content but usually for user related binaries.
2. Why not use the [Azure app service]1 to host your .net core api (if it is an api)?
You can find documentation on how to use the functions with .net core here

Related

Why are there no consumption plans for API apps? [closed]

Closed. This question is not about programming or software development. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed last month.
Improve this question
If I deploy a bunch of Azure Functions in to a functions app and setup the functions app to use a consumption plan, then each calendar month the compute cost for the first 1 million calls is basically free.
How come I can't do this with a web API using something like MVC or OData?
The only difference I can see is the framework parts used, presumably there's some infrastructural reason for this?
Which leads to ...
I'm tempted to make all API implementations a set of Azure Functions to make the most of cloud costs but it feels like I'm making the infrastructure costs dictate my technical decisions a little too much here or that I'm missing something.
As a sort of secondary question if there's any MSFT peeps out there, would Microsoft consider making it so that all Azure app Services can be consumption planned?
The big difference between an App Service and a Function App is the fact that, for your App Service, there's an App Service Plan dedicated to run the App Service which reserves a set of resources like CPU and memory.
An App Service plan defines a set of compute resources for a web app to run. These compute resources are analogous to the server farm in conventional web hosting. One or more apps can be configured to run on the same computing resources (or in the same App Service plan).
When you create an App Service plan in a certain region (for example, West Europe), a set of compute resources is created for that plan in that region. Whatever apps you put into this App Service plan run on these compute resources as defined by your App Service plan.
Source: Azure App Service plan overview
For a Function App on a Consumption Plan, this is a specialized version of an App Service Plan. In that case you have a lot less to say about how that plan is configured or what resources it gets: that's all abstracted away for you as a user.
When you're using the Consumption plan, instances of the Azure Functions host are dynamically added and removed based on the number of incoming events. The Consumption plan is the fully serverless hosting option for Azure Functions.
Source: https://learn.microsoft.com/en-us/azure/azure-functions/consumption-plan
And while the Azure Functions Host is the application constantly handling requests by checking to see if your Function App is being called and requests need to be passed on to your code, in a more traditional application like an MVC app, it is your application that actually handles the request beginning to end.
EDIT
why can't I put an MVC controller up on the same contract terms in the cloud as I can with an azure function
Because the current implementation of an App Service is "analogous to the server farm in conventional web hosting", meaning it expects an entire web application. An Azure Function expects a piece of code that can handle the request (better: trigger). A controller is more than just that, and has some (a lot...?) of fluff around it to be able to work.
And, somewhat simplified: because it hasn't been made available by Azure. Presumably because it would make Azure Functions way too biased on how the (.NET, HTTP triggered) function should be implemented.
Abstraction: a Function is a piece of code that can handle a trigger. This trigger can be a lot of things, one of which is a HTTP request. From the Functions runtime's point of view, all triggers just need to be mapped to a handler. Currently, that handler could be considered framework agnostic, Azure Functions only prescribes it adheres to a certain signature.
By allowing developers to host an MVC Controller as the handler for an Azure Function, this would also mean it needs to have all the fluff around the controller either be in place (what, how, ... ?) or the controller be slimmed down to 'just' be a handler for a HTTP trigger... which would make it a regular Azure Function.

Application insights without azure portal [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
We are building a enterprise application using UWP technology. We would like to monitor the application performance using Microsoft Application Insights. App insights telemetry data directly logged into the Azure portal. For security reason, we do not wanted to log the data to outside the boundary. Is there any way to implement the APM without using AZURE? What i meant is, we have to use app insights services, data should be logged in to on-prem server.That needs to visualized by using any tool
Thanks in advance.
Thanks
Sekar
You cannot directly send app insights data out of azure. It will be stored and retained in azure app insights purview only. But you can use options like continuous export of app insights data to move the telemtry data to other azure storage options like blobs or data lake store.
https://learn.microsoft.com/en-us/azure/azure-monitor/app/export-telemetry
App insights are various performance counters and other telemetry that we collect from the applications. If you are sure what metrics you want to collect then turn of application insights and you can have those perf counter data custom logged to blobs or put them into some queue from where they will be sent to your on premises storage (by some process). Or if you can setup some log ingestion engine on-prem to which the apps in the cloud can send the data.
Having said that app insights are a cloud native approach to application monitoring on azure which I believe would work better than other custom approaches. So you can explore the security concerns you have on app insights and see how to mitigate them.
you could if you want to invent your own whole ingestion/storage system. in the appinsights configuration you can affect the endpoint where the data created by the sdk is sent.
in the javascript sdk it is something like this
let config: ApplicationInsights_Types.IConfiguration = {
// endpoint by default is something like this:
endpointUrl: "https://dc.services.visualstudio.com/v2/track",
instrumentationKey: this._instrumentationKey
};
you'd have to find the corresponding thing in whatever SDK you are using. then invent the whole backend and storage and query system to keep all that data.
the point of APM services like Application Insights and others it to not do all that work yourself.

Which Azure services are PaaS [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
I'm trying to compare AWS and Azure for a custom web app that's essentially like any canned content management system. It requires web hosting, database, email, storage, security, some way to process ASP.NET but with high availability and load balanced.
The PaaS/IaaS distinction can sometimes be grey (in part because companies tend to use marketing jargon that portrays IaaS type services as maintenance free). From a small business perspective its quite clear though. If a service involves the SMB spend time maintaining rather than developing, its in the IaaS camp. Since I'm a single developer with limited time, a PaaS model for all services would be preferable. The ideal would be all services (web hosting, database, email, etc are offered as a zero maintenance scalable service rather than have to spin up and manage individual instances.
I find AWS can do everything but a drawback is that one still needs to manage instances (i.e. I would need to keep the software on instances updated, track instances, manage network, security, etc.) S3 doesn't process scripts. AWS Beanstalk and Optworks are still essentially mostly helper apps for starting up an IaaS type environment. (whereas say DynamoDB would count as a PaaS type service). Recently Microsoft has dropped prices on Azure which makes it an attractive alternative
In short, I am looking for a list of services offered by Azure which are actually no maintenance services that don't require I patch software or need to spin up instances to handle traffic spikes (e.g. web hosting, script processing, database, email, etc..)
web hosting, database, email, storage, security, some way to process ASP.NET but with high availability and load-balanced
All of the above are standard features which any matured cloud provider will have in the toolkit. In regards to MSFT Azure:
For web hosting - you have PaaS solutions such as App service plan
and App service environment. The upkeep of the platform (as the name suggests) is with Azure but note that any components that you deploy as part of the package belong to dev and test teams respectively
For database and storage - for a complete PaaS solution you have Azure SQL Server Database and Azure SQL Server Managed Instances, but as I said earlier you will anyways have to own any custom deployment (security policies, VNET injection and IAM's yourself)

Azure service bus: Use functions vs service fabric vs web job? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 1 year ago.
Improve this question
I am considering three ways to to build a service bus topic listener:
Azure functions: https://learn.microsoft.com/en-us/azure/azure-functions/functions-bindings-service-bus
Service fabric: https://iamrufio.com/2017/04/21/azure-service-bus-listener-with-azure-service-fabric/
Web job: https://code.msdn.microsoft.com/Processing-Service-Bus-84db27b4
I'm not sure which way to go. I'm leaning towards Azure functions since it has a direct out-of-the-box service bus integration. However since it's fairly new I'm not sure if it's a safe option.
Service fabric, from what I've read, offers most resiliency and support.
And a web job would be safest to pick since everything is easily configurable but I'm afraid I'll be reinventing the wheel as no out-of-the-box support is provided.
What direction would be best?
It's a very open ended question. You should look at the requirements that you have and other constraints such as budget. For example, running a production grade Service Fabric cluster would require at least 5 nodes. Versus running webjob that would require a hosting plan with some scale out (for HA). Versus running with Azure Functions using consumption plan, where you'd pay per execution only after free grant 1 million requests and 400,000 GB-s of resource consumption per month is used up.
I would suggest to start simple, with Azure Functions. Create your prototype and see if that's what you need. Are you running into issue or not. With Functions utilization of Azure Service Bus could be somewhat limited. For example, you can't dead-letter a message as you either have to return successfully to complete it or throw an exception to retry. You can't defer a message, rather instead would need to send another message. Nor can you use transactional option by using send-via feature of Azure Service Bus.
If you find yourself requiring those features, WebJob would be my next candidate. You will have to look how you'd utilize it. Most likely you'll need to create your own receiving pump and handle things Functions offered for free, but you'll have the flexibility required to create multiple connections, configure clients the way you need, etc.
And only after that, if you see that aside from Service Bus you have requirements like data partitioning, or HA, or DR, or deploying and scaling out multiple services, I'd be more serious about Service Fabric.
Each of these 3 technologies has its place and use cases.

Creating an effective Azure VM Backup Strategy [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I am trying to understand how to do a backup all of my stuff on Azure VM/Role
For example I have a VM and I have installed and configured various stuff like a streaming server via remote desktop.
Now what happens if for some reason the VM needs to restart, hardware failure is one example for a need to reboot. What happens, do I need to re-install all my stuff?
So I don't get it, MS SLA guarantee 99.9% up-time for the VM, does this resolve to 0.01% chance of me doing the re-install? I think that the real chance me do the re-install is 100% sooner or later.
On AWS you can backup the EC2 to ESB or S3, you install all the stuff, take a snapshot and if the EC2 goes down, the snapshot is restored.
Here I found a post about how Azure doesn't support this, but it is from 1 year ago and I wonder if this has changed, but can't find any info.
backup/snapshot a vm image (vhd) in windows azure
In the management portal I see a lame button called [reimage], but what it does is quite different from what the name implies.
If this is still not possible, I fell that this will be a deal breaker and I will have to ditch Azure in favor of a mature solution from AWS
It sounds like you're looking for the recently announced Windows Azure Virtual Machine (IaaS) functionality. This new feature allows Azure to compete directly with Amazon's EC2 offering. With a Windows Azure Virtual Machine, the disk is a writable .vhd file stored in blob storage. If the machine stops for any reason (hardware failure or manual stoppage), the .vhd just sits in blob storage waiting for the machine to start up again. This article from the Windows Azure blog describes the new persistence options provided with the advent of Windows Azure VMs.

Resources