Your App Engine standard configuration is as follows: service: production instance_class: B1 You want to limit the application to 5 instances. Which code snippet should you include in your configuration?
A.
manual_scaling: instances: 5 min_pending_latency: 30ms
B.
manual_scaling: max_instances: 5 idle_timeout: 10m
C.
basic_scaling: instances: 5 min_pending_latency: 30ms
D.
basic_scaling: max_instances: 5 idle_timeout: 10m
The correct answer is B. manual_scaling: max_instances: 5 idle_timeout: 10m .
Here's why:
manual_scaling : You're using App Engine Standard, which requires you to explicitly define the scaling method. manual_scaling is the correct choice for limiting the number of instances.
max_instances: 5 : This setting directly limits the maximum number of instances to 5, fulfilling your requirement.
idle_timeout: 10m : This setting defines how long an idle instance will remain active before being shut down. It's optional but helps manage costs by automatically shutting down unused instances.
Let's break down why the other options are incorrect:
A. manual_scaling: instances: 5 min_pending_latency: 30ms : While instances: 5 sets the number of instances, min_pending_latency is used for automatic scaling, which is not applicable in this case.
C. basic_scaling: instances: 5 min_pending_latency: 30ms : basic_scaling is for automatic scaling based on request rate. You want manual scaling, so this is incorrect.
D. basic_scaling: max_instances: 5 idle_timeout: 10m : Similar to option C, basic_scaling is not the correct scaling method for this scenario.
In summary: Option B provides the correct configuration for limiting your App Engine Standard application to 5 instances using manual scaling.
Basic Scaling with max_instances (Option D): Basic scaling is suitable for applications that do not need to keep instances running all the time but may require instances to handle requests and then shut down when idle. The max_instances parameter sets the maximum number of instances, and idle_timeout specifies the amount of time that an instance can stay idle before it is shut down.
The correct answer is D, only configuration permitted and lawful according to documentation:
https://cloud.google.com/appengine/docs/standard/reference/app-yaml?tab=python#manual_scaling
The correct answer is D, which specifies the max_instances parameter of the basic_scaling configuration to limit the application to a maximum of 5 instances. The basic_scaling configuration is used for applications that are driven by user activity, and it allows you to specify the maximum number of instances that you want to run using the max_instances parameter.
B is not a good solution because the manual_scaling configuration is not being used, and the idle_timeout parameter has no effect on the maximum number of instances.
A is not a good solution because the manual_scaling configuration is not being used, and the min_pending_latency parameter has no effect on the maximum number of instances.
C is not a good solution because the min_pending_latency parameter is used to specify a minimum amount of time that a request should take before an instance is started, but it has no effect on the maximum number of instances.
https://cloud.google.com/appengine/docs/standard/python/how-instances-are-managed:
"A service with basic scaling is configured by setting the maximum number of instances in the max_instances parameter of the basic_scaling setting. The number of live instances scales with the processing volume."
Answer is D
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
thewalker
4 months, 1 week agothewalker
4 months, 1 week agosantoshchauhan
8 months, 3 weeks ago__rajan__
1 year, 2 months agomaxdanny
1 year, 3 months agoomermahgoub
1 year, 10 months agoomermahgoub
1 year, 10 months agoomermahgoub
1 year, 10 months agoomermahgoub
1 year, 10 months agotomato123
2 years, 3 months agonehaxlpb
2 years, 4 months agomaxdanny
2 years, 4 months agokchp
1 year agokchp
1 year ago[Removed]
2 years, 6 months agoParagSanyashiv
2 years, 10 months agosyu31svc
3 years, 4 months agoStelSen
3 years, 9 months agoDinit
3 years, 9 months agosaurabh1805
4 years ago