Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
-
None
-
None
Description
On line 48(JMS_MAJOR_VERSION = Integer.valueOf(versionProps.getProperty("activemq.version.implementation.majorVersion", "2")), a truly boxed primitive is created from a string simply to extract the value of the unboxed primitive. This approach is inefficient and can lead to code redundancy and loss of performance.
A more efficient approach would be to immediately convert strings to primitive values without creating boxed primitives. For example, use the Integer.parseInt() method to directly convert a string to an int without creating an Integer object.
Attachments
Issue Links
- is superceded by
-
ARTEMIS-4740 Reduce unnecessary boxing
- Closed