Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
3.1M3
-
None
Description
Turns out System.getProperty(String) is synchronized internally, and can create a global contention point for the app. DefaultRuntimeProperties is calling System.getProperty every time, so if we want to minimize the impact of this lock, we need to cache property values when we read them. A specific case where this happened a lot was JdbcAdapter (and subclasses) createEJBQLTranslatorFactory and getQualifierTranslator methods. Both of these methods checked for whether we have a case-insensitive collation. These 2 methods are used a lot, so will cache the value of the property in the adapter instance.