SOLVED

How does the scale out actually increase instances on my App Services , need some help ?

%3CLINGO-SUB%20id%3D%22lingo-sub-2099663%22%20slang%3D%22en-US%22%3EHow%20does%20the%20scale%20out%20actually%20increase%20instances%20on%20my%20App%20Services%20%2C%20need%20some%20help%20%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2099663%22%20slang%3D%22en-US%22%3E%3CP%3EI%20have%20a%20server%20which%20hosts%20my%20.net%20app%20service.%3C%2FP%3E%3CP%3EThis%20app%20service%20runs%20a%20scheduled%20service%20every%202%20minutes%20and%20each%20thread%20can%20have%20thousands%20of%20transactions%20and%20you%20can%20image%20hiw%20slow%20things%20will%20get%20after%201hr.%3C%2FP%3E%3CP%3EI%20have%20scaled%20out%20and%20increased%20instances%20to%20step%26nbsp%3B%20by%202%20with%20a%20max%20of%2010.%26nbsp%3B%3C%2FP%3E%3CP%3EBut%20I%20have%20a%20few%20questions%20which%20I%20would%20appreciate%20if%20someone%20can%20clear%20them%20up%20..%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EHow%20can%20i%20see%20the%20insatcnes%20increase%20as%20the%20service%20is%20running%20and%20then%20see%20it%20scale%20back%20down%20%3F%3CBR%20%2F%3EDoes%20each%20instances%20that%20is%20created%20consume%20its%20own%20set%20of%20memoruyor%20does%20it%20share%20the%20memory%20of%20the%20server%20%3F%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EDoes%20each%20new%20instance%20created%20get%20its%20own%20ip%20address%20in%20a%20specific%20range%20%3F%3C%2FP%3E%3CP%3E%3CBR%20%2F%3Eand%20one%20big%20one%20is%20that%20if%201%20instance%20is%20running%20and%20I%20have%20a%20metric%20that%20measure%20CPU%20and%20if%20it%20reaches%20lets%20say%2050%25%20then%20spin%20up%20a%20new%20instance%2C%3CBR%20%2F%3EHow%20does%20that%20second%20instance%20help%20with%20the%20distribution%20of%20the%20transactions%20that%20were%20fired%20up%20on%20the%20first%20instance%20%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20the%20creation%20of%20a%20new%20instance%20just%20like%20increasing%20specs%20of%20the%20machine%20%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2104958%22%20slang%3D%22en-US%22%3ERe%3A%20How%20does%20the%20scale%20out%20actually%20increase%20instances%20on%20my%20App%20Services%20%2C%20need%20some%20help%20%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2104958%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F744749%22%20target%3D%22_blank%22%3E%40Command0r%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAbsolutely%20brilliant%20%2C%20thanks%20so%20much%26nbsp%3B%20learn%20alot%20from%20this%20and%20am%20now%20confident%20to%20start%20fully%20implementing%20in%20Azure.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2101912%22%20slang%3D%22en-US%22%3ERe%3A%20How%20does%20the%20scale%20out%20actually%20increase%20instances%20on%20my%20App%20Services%20%2C%20need%20some%20help%20%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2101912%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F943791%22%20target%3D%22_blank%22%3E%40KarenSaund888%3C%2FA%3E%2C%26nbsp%3Bplease%20see%20my%20answers%20below%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHow%20can%20i%20see%20the%20insatcnes%20increase%20as%20the%20service%20is%20running%20and%20then%20see%20it%20scale%20back%20down%20%3F%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EYou%20can%20see%20all%20those%20stats%20in%20the%20%3CSTRONG%3EScale-out%3C%2FSTRONG%3E%20blade%20of%20the%20App%20Service.%20The%20first%20indicator%20is%20%22Instance%20count%22%20which%20shows%20how%20many%20instances%20are%20spinning%20now%2C%20and%20the%20other%20one%20is%20the%20%22Run%20history%22%20tab%20in%20the%20same%20place%2C%20so%20you%20can%20see%20some%20historical%20changes%20(if%20you%20perform%20scale%20operations%20automatically).%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EDoes%20each%20instances%20that%20is%20created%20consume%20its%20own%20set%20of%20memoruyor%20does%20it%20share%20the%20memory%20of%20the%20server%20%3F%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EThe%20short%20answer%20is%20yes.%20Whenever%20you%20use%20any%20tier%20(aside%20from%20Isolated)%20that%20means%20you're%20using%20a%20shared%20environment.%20At%20the%20same%20time%2C%20the%20amount%20of%20resources%20allocated%20to%20a%20scaled%20instance%20is%20the%20same%20(as%20it%20uses%20the%20same%20App%20Service%20Plan).%20That%20being%20said%2C%20if%20your%20instance%20scaled%20to%20one%20more%20and%20keeps%20working%20in%20such%20an%20arrangement%2C%20you'll%20be%20paying%20twice%20as%20much%2C%20etc.%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EDoes%20each%20new%20instance%20created%20get%20its%20own%20ip%20address%20in%20a%20specific%20range%20%3F%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3ENo.%20Each%20scaled%20instance%20is%20rather%20a%20%22shadow%20copy%22%20of%20the%20primary%20one.%20It%20means%20you%20won't%20see%20it%20anywhere%20but%20the%20reports%20and%20the%20%22Insurance%20count%22%20in%20the%20%22Scale-out%22%20blade%20I%20mentioned.%20They're%20load-balanced%20automatically%20and%20the%20IP%20is%20rather%20pointing%20to%20an%20internal%20load%20balancer.%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CBR%20%2F%3Eand%20one%20big%20one%20is%20that%20if%201%20instance%20is%20running%20and%20I%20have%20a%20metric%20that%20measure%20CPU%20and%20if%20it%20reaches%20lets%20say%2050%25%20then%20spin%20up%20a%20new%20instance%2C%3CBR%20%2F%3EHow%20does%20that%20second%20instance%20help%20with%20the%20distribution%20of%20the%20transactions%20that%20were%20fired%20up%20on%20the%20first%20instance%20%3F%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EThe%20traffic%20is%20distributed%20automatically%20by%20the%20scheme%20I%20mentioned%20above.%20What%20you're%20asking%20has%20everything%20to%20do%20with%20the%20%22session%20affinity%22%20at%20the%20load%20balancer.%20That%20being%20said%2C%20it%20%22knows%22%20what%20instance%20any%20particular%20session%20should%20go%20and%20directs%20it%20to%20the%20very%20same%20instance.%20Whenever%20the%20load%20hits%20the%20scalability%20metric%20you%20defined%20(if%20to%20autoscale%20automatically)%2C%20it%20scales%20and%20the%20load%20balancer%20directs%20new%20sessions%20to%20the%20newly%20created%20instance.%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20the%20creation%20of%20a%20new%20instance%20just%20like%20increasing%20specs%20of%20the%20machine%20%3F%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EYes%2C%20the%20amount%20of%20resources%20allocated%20to%20a%20scaled%20instance%20is%20the%20same%2C%20as%20I%20mentioned%20above%20(as%20it%20uses%20%3CU%3Ethe%20same%20App%20Service%20Plan%3C%2FU%3E).%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EHope%20that%20helps%20to%20understand%20the%20specifics%20better.%20One%20caveat%20though%20-%20if%20you%20scale-out%20automatically%20(i.e.%2C%20you%20created%20%22custom%20autoscale%20rule%22)%2C%20%3CSTRONG%3Ethe%20instance%20does%20not%20scale%20down%20automatically%3C%2FSTRONG%3E.%20You%20have%20to%20create%20scale-down%20rules%20for%20the%20purpose%20as%20well.%26nbsp%3B%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CFONT%20color%3D%22%23FF6600%22%3EPlease%20mark%20it%20as%20an%20%22answer%22%2Flike%20it%2C%26nbsp%3B%20if%20it%20helps.%3C%2FFONT%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Occasional Contributor

I have a server which hosts my .net app service.

This app service runs a scheduled service every 2 minutes and each thread can have thousands of transactions and you can image hiw slow things will get after 1hr.

I have scaled out and increased instances to step  by 2 with a max of 10. 

But I have a few questions which I would appreciate if someone can clear them up .. 

 


How can i see the insatcnes increase as the service is running and then see it scale back down ?
Does each instances that is created consume its own set of memoruyor does it share the memory of the server ?


Does each new instance created get its own ip address in a specific range ?


and one big one is that if 1 instance is running and I have a metric that measure CPU and if it reaches lets say 50% then spin up a new instance,
How does that second instance help with the distribution of the transactions that were fired up on the first instance ?

 

Is the creation of a new instance just like increasing specs of the machine ?

 

 

2 Replies
best response confirmed by KarenSaund888 (Occasional Contributor)
Solution

@KarenSaund888, please see my answers below:

 

How can i see the insatcnes increase as the service is running and then see it scale back down ?

You can see all those stats in the Scale-out blade of the App Service. The first indicator is "Instance count" which shows how many instances are spinning now, and the other one is the "Run history" tab in the same place, so you can see some historical changes (if you perform scale operations automatically).


Does each instances that is created consume its own set of memoruyor does it share the memory of the server ?

The short answer is yes. Whenever you use any tier (aside from Isolated) that means you're using a shared environment. At the same time, the amount of resources allocated to a scaled instance is the same (as it uses the same App Service Plan). That being said, if your instance scaled to one more and keeps working in such an arrangement, you'll be paying twice as much, etc.


Does each new instance created get its own ip address in a specific range ?

No. Each scaled instance is rather a "shadow copy" of the primary one. It means you won't see it anywhere but the reports and the "Insurance count" in the "Scale-out" blade I mentioned. They're load-balanced automatically and the IP is rather pointing to an internal load balancer.


and one big one is that if 1 instance is running and I have a metric that measure CPU and if it reaches lets say 50% then spin up a new instance,
How does that second instance help with the distribution of the transactions that were fired up on the first instance ?

The traffic is distributed automatically by the scheme I mentioned above. What you're asking has everything to do with the "session affinity" at the load balancer. That being said, it "knows" what instance any particular session should go and directs it to the very same instance. Whenever the load hits the scalability metric you defined (if to autoscale automatically), it scales and the load balancer directs new sessions to the newly created instance.

 

Is the creation of a new instance just like increasing specs of the machine ?

Yes, the amount of resources allocated to a scaled instance is the same, as I mentioned above (as it uses the same App Service Plan).

Hope that helps to understand the specifics better. One caveat though - if you scale-out automatically (i.e., you created "custom autoscale rule"), the instance does not scale down automatically. You have to create scale-down rules for the purpose as well. 

Please mark it as an "answer"/like it,  if it helps.

@Command0r 

 

Absolutely brilliant , thanks so much  learn alot from this and am now confident to start fully implementing in Azure.