Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
API 2.9.0
Description
ResourceMetadata#setParameterMap is called several thousand times per request. In my case the passed parameterMap is always empty. Since it has to create a new empty LinkedHashMap for each call, 1-2% of the rendering time is spent in this method.
Therefore, I would suggest to either ignore empty maps or use Collections.emptyMap() instead. Both solutions should work if the caller does not make any undocumented assumptions for getParameterMap().