主权项 |
1. A system adapted to provide low-latency computational capacity from a virtual compute fleet, the system comprising:
an electronic data store configured to store at least a program code of a user; and a virtual compute system comprising one or more hardware computing devices adapted to execute specific computer-executable instructions, said virtual compute system in communication with the electronic data store, and configured to at least: maintain a plurality of virtual machine instances on one or more physical computing devices, wherein the plurality of virtual machine instances comprise a warming pool comprising virtual machine instances having one or more software components loaded thereon and waiting to be assigned to a user, and an active pool comprising virtual machine instances currently assigned to one or more users; receive a plurality of requests to execute a program code associated with a user on the virtual compute system, the plurality of requests each specifying the program code, the user associated with the program code, and a first amount of a computing resource available on the virtual compute system to be used to execute the program code; select from the warming pool or the active pool a virtual machine instance to be used to execute the program code, the virtual machine instance having at least the first amount of the computing resource specified in the plurality of requests; create one or more containers in the selected virtual machine instance, the one or more containers each having the first amount of the computing resource specified in the plurality of requests; cause the program code associated with the user to be loaded from the electronic data store onto the one or more containers and executed in the one or more containers; determine, based on a determination that the first amount of the computing resource specified in the plurality of requests has satisfied a resource adjustment condition for a threshold number of executions in the one or more containers, that the first amount should be adjusted to improve future executions of the program code; in response to receiving additional requests specifying the program code, the user associated with the program code, and the first amount of the computing resource to be used for executing the program code, create one or more additional containers in the selected virtual machine instance such that the one or more additional containers each have a second amount of the computing resource that is different from the first amount specified in the additional requests; and cause the program code to be executed in the one or more additional containers having the second amount of the computing resource. |