I had a web app that was running in two regions. I ended up deleting it and recreate with pretty much the same configuration:
❯ fly autoscale standard -a sumiu-web
Scale Mode: Standard
Min Count: 1
Max Count: 10
...
❯ fly regions list -a sumiu-web
Region Pool:
fra
gru
Backup Region:
In the past, I would run fly scale count 2 -a sumiu-web and it would spin up a new instance in the second region. Now, when I do it, I get this message:
❯ fly scale count 2 -a sumiu-web
Warning: Autoscaling is now disabled for sumiu-web
Count changed to 2
We did have a recent bugfix for autoscaling, as in that thread. The problem you’re seeing still looks like it could be issue with switching to using processes and back, though.
Do you mind trying this and letting us know the result?
OK, so, it looks like it was an edge case to do with switching to multiple processes and back, and the app process only had one region: fra. We’ve gone in and cleaned that up on your app, so you should see the four instances, two in each region, now.
I can’t take credit for the fixing. Had to escalate that one pretty far.
The processes feature is in preview and has a lot of edge cases. Your app had configuration left over from trying that. I think you might have been able to sort it with something like fly regions set fra gru --group app, but there might have been more leftovers to find.
I think we’re hitting a similar issue @catflydotio - we were using multi processes, but then stopped and just used multiple apps instead. I’ve tried all the combinations of setting regions for a process, scaling up and down and using max-per-region → is there a canonical way to fix that that doesn’t require deleting the app and starting again?
Thanks!
edit - I’ve deleted all mentions of processes from our fly.toml, redeployed and no matter what I can’t set the max per region. fly-scale-show always returns:
VM Resources for app name
VM Size: shared-cpu-1x
VM Memory: 2 GB
Count: 6
Max Per Region: app=0 web=0 worker=0
@captainb out of curiosity have you tried doing something like below? I was experimenting with this on an app of mine that’s in a similar state and was able to get a max set by doing:
fly scale app=2 --max-per-region 4
The max is applied to only the process groups you specify in the command. That also won’t change the scale count of process groups you don’t specify.
It might help to know that apps without any process groups specified will use the app process group.