Looks like a platform bug to me. Couple of thoughts:
- Is expected behaviour for setting ConnectionPoolingMaxActive defined at all? I can imagine that if you set this above the treshold Amazon uses, unexpected things happen. Also, are you sure 5000 is a sensible setting? For a database running on a physical machine, 2*(number of cpus) is a sensible setting. I do not know enough about how the v4 cloud works in this regard to know if 5000 makes sense, but it seems awfully high to me.
- If the platform would be working correctly, I would expect requests that come in when the number of database connections is exhausted to wait until a connection becomes available, and after a certain timeout return a 500 error.
- The connections not being cleared must be a platform bug. Or do you see 50 running actions in the "running now" overview?
The settings you're referring to are the application settings. On the database side, it is still limited to 50.
If you file a ticket at support.mendix.com, Support can raise the database limit so you'll have the possibility to use more than the default 50.