1. In a data processing system having a processor, a method comprising: the processor executing program code that performs the function of instrumenting an application with a first aspect, wherein the first aspect is associated with aspect source code that defines a pointcut identifying a database-related operation and wherein the first aspect is associated with an advice code that identifies a characteristic of the database-related operation and determines whether a database-related resource is returned to a pool of resources after being used by the application; and instrumenting the application with a second aspect, wherein the second aspect is associated with the pointcut identifying a second database-related operation and wherein the second aspect is associated with advice code that identifies the characteristic of the second database-related operation.