Jatin
Jatin

Reputation: 31754

Understanding Azure Functions with App Service Plan

While creating an Azure Function. It provides an option to create an App Service Plan.

enter image description here

Let's say we select P2V2 which has 7GB Ram and 2 Cores. Here are the questions:

  1. Let's say when the function is triggered, and each invocation consumes 1GB Ram. Does it mean that the same instance at maximum can concurrently run ~6 (leaving aside 1GB for OS let's say). Where all the 6 concurrent triggered functions re-use the same cores?
  2. When does the App Service plan decide to scale out to multiple instances?

Upvotes: 0

Views: 888

Answers (1)

rickvdbosch
rickvdbosch

Reputation: 15621

  1. Yes, probably. As stated in Azure Functions hosting options - Service limits the number of Function apps per plan is unbounded, but:

The actual number of function apps that you can host depends on the activity of the apps, the size of the machine instances, and the corresponding resource utilization.

  1. By default, an App Service Plan doesn't scale. In the same article I linked to before, it states that for a Dedicated Plan you can use Manual scaling or Autoscale. For autoscale, you control the rules.

For more information, see the documentation Juunas linked to in this comment.
Best practices for Autoscale

Upvotes: 1

Related Questions