Set a limit on the number of total concurrent workspaces and workspaces per user per agent
MR: Pending
## Description
`As a gitlab instance administrator, I want to place a limit on the number of concurrent workspaces that can be running on an agent, so that the potential infrastructure cost can have a bounded upper limit.`
In the initial workspaces beta, a developer can create as many workspaces as they want.
There are two limits we want to implement:
1. A maximum number of concurrent workspaces that can be running in an agent
2. A maximum number of concurrent workspaces that an individual user can be running per agent
These two limits are optional and configured at an agent-level, but can be use used individually or in combination to control the amount of cloud resources that can be consumed by remote development workspaces.
The default should be `unlimited` when the value is not set.
### Later iterations
As a first iteration, we're looking for the MVC that provides safety for larger teams. This is the best first step because it doesn't involve any significant UI changes or new database tables. We'll look to expand this in later iterations by:
* Validating the availability of the agent to create a workspace before creating the workspace
* Implement some kind of queue so you don't have to try again
* Setting a limit to the number of workspaces per user
* We'll provide UI for settings that are agent or instance-specific
## Acceptance Criteria
* [ ] An attribute in agent configuration which allows agent administrators to set the number of workspaces that each user can provision using that specific agent.
* [ ] An attribute in agent configuration which allows agent administrators to set the number of workspaces that can be run concurrently on that specific agent.
_This page may contain information related to upcoming products, features and functionality. It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes. Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc._
<!-- triage-serverless v3 PLEASE DO NOT REMOVE THIS SECTION -->
*This page may contain information related to upcoming products, features and functionality.
It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes.
Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc.*
<!-- triage-serverless v3 PLEASE DO NOT REMOVE THIS SECTION -->
epic