Does an Azure vnet affect performance - azure

Does an Azure Vnet improve or degrade performance compared to a connection via public endpoint?
By performance I mean latency or throughput.
For example when connecting from a web app to a database.

If communicating resources are on the same VNet OR in VNets that are on the SAME Azure Region, there will be NO degradation.
On the oder hand, if the peer VNets are on different Azure Regions, there will be degradation because the peers are in different data centers.

Vnets are primarily used to add an additional layer of security. They do not offer performance benefits - but if you use Vnet connectivity in any part of your application then you need to be aware of the correct configuration to avoid (unnecessary) degradation.
Lets' say for example you have a simple web app made up of an App Service instance with a SQL Database. If you connect your App to a Vnet to access some on-premise resource (via VPN or Expressroute), and that vnet is configured with forced tunnelling to on-premise then you will have degradation: Traffic from the web app to SQL db is getting hair-pinned via your on-premise network. If you then set-up a Service Endpoint for the SQL database on your VNet, the traffic will stay in Azure and you will get optimal routing Source. However it won't be any faster than if you had no VNet.
For a more detailed explanation take a look at this blog: Improve security and performance with Virtual Network Service Endpoints and Firewalls for Azure Storage

Related

Hub VNET in cloud-only environment approach

I was told recently that the Hub VNET is only used in case there is on-premise networking to/from considerations.
I am quite surprised as were many, at the table.
I was under the impression if I have, say, a AZURE Cloud only env. that I could still have a Hub Spoke approach. Or is this not so? What would be the preferred non-Hub Spoke approach if there is peering or inter-VNET access required?
I am aware of VNET Peering and other methods to access resources in other VNETs, API's and Private Link.
The hub-spoke approach works great in some scenarios in cloud-only environments - although in most of docs or architectural patterns Microsoft shows it together with on-prem connectivity.
I used it frequently when we shared some resources like ACR, Log Analytics or simply to host a jump host (with Bastion) to access resources in other networks.
One of the most common scenarios is also the Azure Monitor Private Link Scope, where the hub-spoke topology is recommended:
https://learn.microsoft.com/en-us/azure/azure-monitor/logs/private-link-design#hub-and-spoke-networks
In an Azure Cloud only environment, you can still have a Hub-Spoke approach and this is the recommended one.
While you can cross-peer different spokes to form a Mesh for spokes to exchange data (in a non-Hub scenario), this will become complicated as the number of spokes increases. You will have to configure 1:n Peering in every VNet.
With Hub-Spoke model, you have to route spoke-spoke traffic via Hub Vnet, but the advantage here is that the Hub Vnet becomes the single point entry for the environment and you can deploy resources here that would be shared and used by all other VNets (such as custom DNS server, Firewall)

Azure Networking - Application GW, Virtual Network GW, VWAN, ExpressRotue, PrivateLink, Arc

can anyone explain difference between Azure Application Gateway, Virtual Network Gateway, Virtual WAN, ExpressRoute, Arc and Private Link, please?
It seems to me all services are pretty similar helping with connecting either on-prem to Azure, in-Azure to in-Azure or public to Azure.
They're similar in that they all involve network traffic, but that's pretty much where the similarities end.
Application Gateway is a Layer 7 load balancing service with advanced features like SSL termination. It's used to route client requests to your applications.
Virtual Network Gateway is a VPN gateway for point-to-site (user) and site-to-site (office/datacenter) VPN connections to your own Azure VNETs. This would, for example, allow you to RDP into Azure VMs from your on-prem office using their private IPs.
ExpressRoute is similar to site-to-site, however it doesn't use IpSec tunnels, it's a dedicated, unencrypted connection from your location directly into Microsoft's backbone. (i.e. you don't traverse the public internet). There's no encryption and the connection is faster. This is a service you need to work with a 3rd party internet provider to implement.
Virtual WAN is more like a networking hub where there would be many site-to-site, point-to-site, ExpressRoute, etc... connections spanning a wide area (as the name implies). This would be for large enterpise organizations with many on-prem locations.
Arc is a means of adding your on-prem resources into Azure for management. e.g. you have a physical server somewhere and you want to manage it though ARM/portal.
Azure Private Link is a feature of many Azure services (storage, SQL PaaS, etc..) which allows you to create a private DNS record and assign a private IP address on your internal VNETs. This is used when you want to disable all public network access to a resource and only allow access from within your own VNET.
I have barely scratched the surface of the differences here, but suffice it to say, there are many differences. From this page, you can type the service name into the search and get more specific details on the offering. Hope this helps.
https://learn.microsoft.com/en-us/search/?terms=networking%20in%20azure

Understanding Outbound Data Transfer for Azure App Service Plan

For the purpose of migrating a very small business web application from on-premise to Azure PAAS service environment, We have identified the below tentative solution..
Use Azure Storage Account to Host the front end (Angular SPA).
Use App Service Plan to run the Back-End Spring Boot Application.
Use Application Gateway V2 (with WAF) as public end point which will re-route traffic to both Storage account and App Service (SSL will be hosted in Gateway as it is the public endpoint)
Use Azure SQL Server as database.
Use VPN gateway Site to Site connection from Azure service to on-premise for out going SFTP file transfer.(very small in size).
But it seems App Service Plan will not be placed within the Application VNET, and hence a VNET integration from Azure service to Application VNET is first required to enable the VPN connectivity. Ours is a very small application with no HA or other multi zone/region requirements, hence using dedicated ASE (Azure Service Environment) is not feasible for us. Since the communication with App Service is not going to be local to application VNET, we are trying to under stand the concept of term 'Out bound data transfer (specifically which are charged and not)' in Azure networking, with respect to the above PAAS services.
Does the traffic from Application Gateway (in Application VNET) to Azure Service (Plan) are considered outbound data transfer?
If there a VNET integration is in place from Azure Service to application VNET, does the traffic going out of Azure service to application VNET is considered outbound data transfer?
From this article, we know that
Outbound data transfer: The first 5 GB per month of outbound data
transfer is free for all Azure zones, but following that the Azure
pricing tiers will kick in based on various slabs (5–10 TB, then 40TB,
100TB, 350TB, and then everything above 500 TB).
This charge should be considered if the applications deployed in Azure
are accessed over the internet. For example, when downloading data
from Azure storage accounts or websites, accessing VMs over RDP and
SSH will incur charges as data is being transferred out of an Azure
data center.
Another scenario where these charges will be applied is with hybrid
connectivity through VPN or ExpressRoute. For VPNs, the outbound data
from the VPN Gateways will be billed at outbound data charge rates.
For ExpressRoute, outbound data transfers are chargeable for metered
data plans, and the cost will vary based on the selected plan.
To your questions:
The traffic from Application Gateway (in Application VNET) to Azure Service (Plan) would be considered outbound data transfer
because if the backend pool is a public endpoint (azure app service), the application gateway uses its frontend public IP to reach the server. If there isn't a frontend public IP address, one is assigned for the outbound external connectivity. Read How an application gateway routes a request. Also, it would be charged if you have an application getaway and app service plan in different regions.
With VNet integration, the app service is connected to both a VNet and the Internet. The traffic going out of Azure service to application VNET would not be considered outbound data transfer
because the traffic usually goes over the Azure backbone network and the VMs that hosting your web app is assigned a private IP address from that integrated subnet. These IP addresses are used for outbound connectivity. You would also be charged if deployed all resources across regions(for this, you may use gateway-required VNet integration).
If you're interested, you could read that other Azure services can reduce your cloud costs.

Segmentation of Azure Subnet for applications

We manage big environments inside Azure with multiple customers, we are redesigning it and in it we wanted to manage traffic within multiple common subnets like app, web and db subnets.
So essentially no two different application inside any common subnet like db cannot communicate with each other.
By default, resources in the different subnets from the same VNet could communicate with each other. So you need to use an Azure network security group to filter network traffic to and from Azure resources in an Azure virtual network or subnet.
Application security groups enable you to configure network security as a natural extension of an application's structure, allowing you to group virtual machines and define network security policies based on those groups. You can reuse your security policy at scale without manual maintenance of explicit IP addresses. To learn more, see Application security groups.
For PaaS like Azure app service or Azure SQL database, you could use VNet Integration to access VNet resources in a private network or use virtual network service endpoints and rules for servers in Azure SQL Database.
For more information, you may know:
https://learn.microsoft.com/en-us/azure/architecture/reference-architectures/dmz/secure-vnet-dmz
https://learn.microsoft.com/en-us/azure/networking/networking-overview

Azure PaaS to PaaS network communication

When an Azure PaaS service (ex:App Service) makes a call to another PaaS service in the same region, say SQL Database, is that traffic routed through Public Internet or routed entirely through Azure backbone network (like: for DNS resolution and other subsequent network hops). Is there any difference in the way this traffic is routed if the services are in different regions?
I got the answer, so I thought it will help the community if someone has the same question.
The PaaS - PaaS traffic stays entirely within Azure backbone network.
Link here

Resources