A system for connection labeling for use with connection pools, comprising: a computer including a processor and a database; a connection pool, including a plurality of connection objects (108, 110) which provide connections (108, 110) that software applications (109, 130) can use to make requests to access the database, wherein each of the connections can be labeled by a software application; and a connection pool logic that estimates, for connections (108, 110), a cost value indicative of resources required to reconfigure that connection to a required state, and controls one or more of the use, creation, or repurposing of connections to serve requests from the software applications (109, 130), wherein the connection pool logic performs a process of: determining, for a received request, if there is an existing matching connection (108, 110); and if there is an existing matching connection (108, 110), returning the existing matching connection (108, 110), characterized in that, otherwise finding a cheapest non-matching connection based on the estimated cost values for non-matching connections, and determining whether the cost value for the cheapest non-matching connection is less than a high-cost value, and if so repurposing the cheapest non-matching connection for use with the request, otherwise if the total number of connections (108, 110) is less than a threshold value, creating a new connection for use with the request, and returning the new connection, and if the total number of connections (108, 110) is greater than or equal to the threshold value, repurposing the cheapest connection for use with the request. a computer including a processor and a database; a connection pool, including a plurality of connection objects (108, 110) which provide connections (108, 110) that software applications (109, 130) can use to make requests to access the database, wherein each of the connections can be labeled by a software application; and a connection pool logic that estimates, for connections (108, 110), a cost value indicative of resources required to reconfigure that connection to a required state, and controls one or more of the use, creation, or repurposing of connections to serve requests from the software applications (109, 130), wherein the connection pool logic performs a process of: determining, for a received request, if there is an existing matching connection (108, 110); and if there is an existing matching connection (108, 110), returning the existing matching connection (108, 110), characterized in that, otherwise finding a cheapest non-matching connection based on the estimated cost values for non-matching connections, and determining whether the cost value for the cheapest non-matching connection is less than a high-cost value, and if so repurposing the cheapest non-matching connection for use with the request, otherwise if the total number of connections (108, 110) is less than a threshold value, creating a new connection for use with the request, and returning the new connection, and if the total number of connections (108, 110) is greater than or equal to the threshold value, repurposing the cheapest connection for use with the request. determining, for a received request, if there is an existing matching connection (108, 110); and if there is an existing matching connection (108, 110), returning the existing matching connection (108, 110), characterized in that, otherwise finding a cheapest non-matching connection based on the estimated cost values for non-matching connections, and determining whether the cost value for the cheapest non-matching connection is less than a high-cost value, and if so repurposing the cheapest non-matching connection for use with the request, otherwise if the total number of connections (108, 110) is less than a threshold value, creating a new connection for use with the request, and returning the new connection, and if the total number of connections (108, 110) is greater than or equal to the threshold value, repurposing the cheapest connection for use with the request. if the total number of connections (108, 110) is less than a threshold value, creating a new connection for use with the request, and returning the new connection, and if the total number of connections (108, 110) is greater than or equal to the threshold value, repurposing the cheapest connection for use with the request.