7.32.0.35531
Release notes - SonarJava - 7.32
Bug
SONARJAVA-4756 NumberFormatException in AbstractPrintfChecker.getIndex(String param)
SONARJAVA-4873 Wrong quickfix in S1066
SONARJAVA-4909 Missing parentheses in the children() method of RecordPatternTreeImpl
SONARJAVA-4913 S1181 misses issues after unknown symbol
False-Positive
SONARJAVA-4422 S6204 FP on lists used outside their instantiation scope
SONARJAVA-4438 S6204: recommendation not applicable when upcast is required
SONARJAVA-4749 FP in S1170 when field is used in a non-static member
SONARJAVA-4751 FP in S2326 when type parameters are used in the child classes or interface implementations
SONARJAVA-4752 FP in S5665 when \\" and \\' are not intended to be escaped
SONARJAVA-4758 S1113 should cover the finalizer attack
SONARJAVA-4814 S1948 should not raise issues on final fields
SONARJAVA-4816 S1948 should support jakarta.inject.Inject
SONARJAVA-4829 FP in rule S2694 on local classes
SONARJAVA-4835 FP on S3242 forcing user to add unnecessary logic
SONARJAVA-4857 S3457: FP on certain java.util.logging strings with single quotes
SONARJAVA-4865 S6856 should not raise on named regex
SONARJAVA-4904 FP on S1301 when using switch statement with type patterns
SONARJAVA-4907 FP on S1481 when using type pattern matching in case clauses of a switch
SONARJAVA-4908 FP on S131 when using switch statement on type pattern
New Feature
SONARJAVA-4823 S6885 Add clamp methods to Math
SONARJAVA-4825 S6876 SequencedCollection reversed view should be used for reverse iteration order
SONARJAVA-4826 S6880 Use switch instead of if else for pattern matching
SONARJAVA-4827 S6877 SequencedCollection reversed view should be used instead of Collections.reverse for read-only lists
SONARJAVA-4831 S6891: Avoid exact alarms
SONARJAVA-4832 S6881 VirtualThreads should be used for tasks that include heavy blocking operations
SONARJAVA-4837 S6878 Use record pattern instead of explicit field access
SONARJAVA-4838 S6901: Thread.setDaemon(boolean), Thread.setPriority(int) and Thread.getThreadGroup() should not be invoked on VirtualThread
SONARJAVA-4840 S6905: SQL queries should retrieve only necessary fields
SONARJAVA-4841 S6898: Avoid high frame rate
SONARJAVA-4842 S6909: Constant parameters in a PreparedStatement should not be set more than once
SONARJAVA-4843 S6906: Virtual threads should not run tasks that include synchronized or native code
SONARJAVA-4844 S6913 Clamp should be used with correct ranges
SONARJAVA-4845 S6914: Use Fused Location to optimize battery power
SONARJAVA-4848 S6916 Use guard instead of a single if/else in pattern match body
SONARJAVA-4849 S6915 indexOf(char|String, int, int) should be used with correct ranges
SONARJAVA-4851 S6912: Use batch Processing in JDBC
SONARJAVA-4854 S6923: Motion Sensor should not use gyroscope
SONARJAVA-4855 S6926: Bluetooth should be configured to use low power
False Negative
SONARJAVA-4784 S2093 should raise on HttpClient starting on Java 21+ code
Improvement
SONARJAVA-4415 Add parameter to ignore particular annotations in S1068
SONARJAVA-4898 S6218: Improve reporting to no highlight the entire record
SONARJAVA-4900 Provide the resolved method "symbol" in "LambdaExpressionTree"
SONARJAVA-4912 S6204 Update issue message