Skip to content

RC-442 Move vibebot to ruling_java and align ruling project keys - #6297

Open
romainbrenguier wants to merge 3 commits into
masterfrom
romain/rc-442
Open

romainbrenguier wants to merge 3 commits into
masterfrom
romain/rc-442

Conversation

@romainbrenguier

@romainbrenguier romainbrenguier commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Move the unchanged vibebot project from its/vibebot into ruling_java/vibebot, update the its/sources submodule, and use the common ruling helper for its analysis. Companion PR: RC-442 Move vibebot ruling project from sonar-java ruling_java#16.
  • Align ruling project keys with their source folder names: mall, guava, commons-beanutils, regex-examples, vibebot, and sonarqube-6.5; jboss-ejb3-tutorial already matches.
  • Simplify the standard test_project helper so the source folder name is also the project key. Keep the nested SonarQube POM location unchanged.
  • Use eclipse-jetty and java-time-example as the shared keys for their respective main and incremental PR analyses, while preserving separate expected folders for the incremental variants.
  • Rename the sonar-server expected folder to sonarqube-6.5 and update baseline component keys without changing expected issue locations. Keep vibebot excluded from the normal ruling workflow.

Merge order

Merge ruling_java PR #16 first. If squash-merging changes its commit SHA, update the submodule pointer here to the merged commit before merging this draft.

Validation

  • The moved vibebot project packages successfully with Maven; its three files are byte-for-byte identical to the original versions.
  • Validated all 1,260 expected JSON baselines against the previous commit: all 163,755 issue locations are unchanged, component keys match the new project keys, and expected folders match project keys except for incremental variants.
  • git diff --check passes; both working trees are clean after committing and pushing.
  • Ruling integration tests were not run locally, per repository guidance.
  • Ruling test compilation was attempted during the migration: the isolated build lacks local snapshot dependencies; the reactor build fails in unchanged sonar-java-plugin code because GeneratedCheckList is missing.
  • The explicit secrets scan passed for the initial migration. Its commit/push hooks also scanned unchanged regex-examples private-key fixtures through the gitlink, so they were bypassed for those commands only after confirming the fixtures were unchanged. The subsequent project-key/baseline commit and push used the normal hooks.

Deep analysis

Analyzed all 1,199 final modified files in one DEEP invocation; the service automatically split the large request into batches, which may reduce cross-file context. No issues were reported on changed lines. Only these existing findings remain on untouched JavaRulingTest.java lines:

[1] line 568  Format specifiers should be used instead of string concatenation.  java:S3457
[2] line 569  Format specifiers should be used instead of string concatenation.  java:S3457
[3] line 570  Format specifiers should be used instead of string concatenation.  java:S3457

Agent workflow

Tool link: https://github.com/SonarSource/languages-experimental-tooling/tree/romain/my-tickets/personal/romain-brenguier
PR created using uv run create_with_claude.py /tmp/action_plan_romain/rc-442.txt

Iterated on the PR with uv run ci_loop.py for 1 iterations.
✔️ The PR is now ready for review.

@hashicorp-vault-sonar-prod

hashicorp-vault-sonar-prod Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

RC-442

Comment thread its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java
@romainbrenguier romainbrenguier changed the title RC-442 Move vibebot project to ruling_java RC-442 Move vibebot to ruling_java and align ruling project keys Oct 5, 2026
@gitar-bot

gitar-bot Bot commented Oct 5, 2026

Copy link
Copy Markdown
Code Review ✅ Approved 1 closed / 1 findings

🟡 Medium risk · Ruling test project keys, helper behavior, and source layout change together.

Migrates vibebot project to ruling_java and aligns ruling project keys with source folder names (mall, guava, commons-beanutils, regex-examples, vibebot, sonarqube-6.5). AGENTS.md documentation updated to reflect the new project keys and format. All 163,755 issue locations across 1,260 baselines remain unchanged, with component keys and expected folders validated. No issues found.

✅ 1 closed
✅ Quality: AGENTS.md ruling docs still describe old project name and key format

📄 its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java:399-406 📄 its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java:445-447
This commit renames the sonar-server baseline folder to sonarqube-6.5 and moves all baseline keys from groupId:artifactId:path (for example com.google.guava:guava:...) to <project-folder>:path (for example guava:..., sonarqube-6.5:...). AGENTS.md was not updated. It still lists sonar-server as a ruling project and still says the format is {"group:artifact:path/to/File.java": [...]}. Agents and contributors who follow it will look in the wrong expected folder or write baseline keys that no longer match what test_project sets as sonar.projectKey. The fix is to replace sonar-server with sonarqube-6.5 (and add mall/vibebot if wanted), and to change the format line to {"<project>:path/to/File.java": [...]}.

Review coverage

🧪 Functional validation No results

📋 Rules No rules evaluated

🤖 Auto-approval Not enabled · Set up

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Counting what did not apply, without listing it.

Comment with these commands to change the behavior for this request:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@sonarqube-next

sonarqube-next Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Ruling Diff Summary

Detected changes in 1378 rule files: 160962 issues removed, 160962 issues added.

S103 (java) on commons-beanutils - 24 issues removed, 24 issues added

Removed src/main/java/org/apache/commons/beanutils2/BeanPropertyValueChangeClosure.java (line 134)

       129 |      * object.
       130 |      * @param ignoreNull Determines whether <code>null</code> objects in the property path will
       131 |      * genenerate an <code>IllegalArgumentException</code> or not.
       132 |      * @throws IllegalArgumentException If the propertyName provided is null or empty.
       133 |      */
>>>    134 |     public BeanPropertyValueChangeClosure(final String propertyName, final Object propertyValue, final boolean ignoreNull) {
       135 |         super();
       136 | 
       137 |         if (propertyName != null && propertyName.length() > 0) {
       138 |             this.propertyName = propertyName;
       139 |             this.propertyValue = propertyValue;

Removed src/main/java/org/apache/commons/beanutils2/BeanPropertyValueEqualsPredicate.java (line 164)

       159 |      * @param propertyValue The value to use in object evaluation.
       160 |      * @param ignoreNull Determines whether <code>null</code> objects in the property path will
       161 |      * genenerate an <code>IllegalArgumentException</code> or not.
       162 |      * @throws IllegalArgumentException If the property name provided is null or empty.
       163 |      */
>>>    164 |     public BeanPropertyValueEqualsPredicate(final String propertyName, final Object propertyValue, final boolean ignoreNull) {
       165 |         super();
       166 | 
       167 |         if (propertyName != null && propertyName.length() > 0) {
       168 |             this.propertyName = propertyName;
       169 |             this.propertyValue = propertyValue;

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1319)

      1314 |          * @param cls  the class to reflect, must not be null
      1315 |          * @param methodName  the method name to obtain
      1316 |          * @param paramTypes the array of classes representing the parameter types
      1317 |          * @param exact whether the match has to be exact.
      1318 |          */
>>>   1319 |         public MethodDescriptor(final Class<?> cls, final String methodName, Class<?>[] paramTypes, final boolean exact) {
      1320 |             if (cls == null) {
      1321 |                 throw new IllegalArgumentException("Class cannot be null");
      1322 |             }
      1323 |             if (methodName == null) {
      1324 |                 throw new IllegalArgumentException("Method Name cannot be null");

Removed src/main/java/org/apache/commons/beanutils2/RowSetDynaClass.java (line 236)

       231 |      *  is <code>null</code>
       232 |      * @throws SQLException if the metadata for this result set
       233 |      *  cannot be introspected
       234 |      * @since 1.8.3
       235 |      */
>>>    236 |     public RowSetDynaClass(final ResultSet resultSet, final boolean lowerCase, final int limit, final boolean useColumnLabel)
       237 |                                                             throws SQLException {
       238 | 
       239 |         if (resultSet == null) {
       240 |             throw new NullPointerException();
       241 |         }

Removed src/main/java/org/apache/commons/beanutils2/converters/DateTimeConverter.java (line 555)

       550 |      * @param format The DateFormat to parse the String value.
       551 |      *
       552 |      * @return The converted Calendar object.
       553 |      * @throws ConversionException if the String cannot be converted.
       554 |      */
>>>    555 |     private Calendar parse(final Class<?> sourceType, final Class<?> targetType, final String value, final DateFormat format) {
       556 |         logFormat("Parsing", format);
       557 |         format.setLenient(false);
       558 |         final ParsePosition pos = new ParsePosition(0);
       559 |         final Date parsedDate = format.parse(value, pos); // ignore the result (use the Calendar)
       560 |         if (pos.getErrorIndex() >= 0 || pos.getIndex() != value.length() || parsedDate == null) {

Removed src/main/java/org/apache/commons/beanutils2/converters/NumberConverter.java (line 546)

       541 |      * @param format The NumberFormat to parse the String value.
       542 |      *
       543 |      * @return The converted Number object.
       544 |      * @throws ConversionException if the String cannot be converted.
       545 |      */
>>>    546 |     private Number parse(final Class<?> sourceType, final Class<?> targetType, final String value, final NumberFormat format) {
       547 |         final ParsePosition pos = new ParsePosition(0);
       548 |         final Number parsedNumber = format.parse(value, pos);
       549 |         if (pos.getErrorIndex() >= 0 || pos.getIndex() != value.length() || parsedNumber == null) {
       550 |             String msg = "Error converting from '" + toString(sourceType) + "' to '" + toString(targetType) + "'";
       551 |             if (format instanceof DecimalFormat) {

Removed src/main/java/org/apache/commons/beanutils2/locale/BaseLocaleConverter.java (line 111)

       106 |      * @param defaultValue  The default value to be returned
       107 |      * @param locale        The locale
       108 |      * @param pattern       The convertion pattern
       109 |      * @param locPattern    Indicate whether the pattern is localized or not
       110 |      */
>>>    111 |     protected BaseLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       112 | 
       113 |         this(defaultValue, locale, pattern, true, locPattern);
       114 |     }
       115 | 
       116 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleBeanUtils.java (line 618)

       613 |      * @throws InvocationTargetException if the property accessor method
       614 |      *  throws an exception
       615 |      *
       616 |      * @see LocaleBeanUtilsBean#invokeSetter(Object, String, String, int, Object)
       617 |      */
>>>    618 |     protected static void invokeSetter(final Object target, final String propName, final String key, final int index, final Object newValue)
       619 |             throws IllegalAccessException, InvocationTargetException {
       620 | 
       621 |        LocaleBeanUtilsBean.getLocaleBeanUtilsInstance().invokeSetter(target, propName, key, index, newValue);
       622 |     }
       623 | }

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleBeanUtilsBean.java (line 875)

       870 |      * @throws IllegalAccessException if the caller does not have
       871 |      *  access to the property accessor method
       872 |      * @throws InvocationTargetException if the property accessor method
       873 |      *  throws an exception
       874 |      */
>>>    875 |     protected void invokeSetter(final Object target, final String propName, final String key, final int index, final Object newValue)
       876 |             throws IllegalAccessException, InvocationTargetException {
       877 | 
       878 |         try {
       879 |             if (index >= 0) {
       880 |                 getPropertyUtils().setIndexedProperty(target, propName,

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleConvertUtils.java (line 235)

       230 |      * @param locale The locale
       231 |      * @param pattern The convertion pattern
       232 |      * @return the converted value
       233 |      * @see LocaleConvertUtilsBean#convert(String[], Class, Locale, String)
       234 |      */
>>>    235 |     public static Object convert(final String[] values, final Class<?> clazz, final Locale locale, final String pattern) {
       236 | 
       237 |         return LocaleConvertUtilsBean.getInstance().convert(values, clazz, locale, pattern);
       238 |     }
       239 | 
       240 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/BigDecimalLocaleConverter.java (line 197)

       192 |      * @param defaultValue  The default value to be returned
       193 |      * @param locale        The locale
       194 |      * @param pattern       The convertion pattern
       195 |      * @param locPattern    Indicate whether the pattern is localized or not
       196 |      */
>>>    197 |     public BigDecimalLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       198 | 
       199 |         super(defaultValue, locale, pattern, locPattern);
       200 |     }
       201 | 
       202 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/BigIntegerLocaleConverter.java (line 198)

       193 |      * @param defaultValue  The default value to be returned
       194 |      * @param locale        The locale
       195 |      * @param pattern       The convertion pattern
       196 |      * @param locPattern    Indicate whether the pattern is localized or not
       197 |      */
>>>    198 |     public BigIntegerLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       199 | 
       200 |         super(defaultValue, locale, pattern, locPattern);
       201 |     }
       202 | 
       203 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/ByteLocaleConverter.java (line 198)

       193 |      * @param defaultValue  The default value to be returned
       194 |      * @param locale        The locale
       195 |      * @param pattern       The convertion pattern
       196 |      * @param locPattern    Indicate whether the pattern is localized or not
       197 |      */
>>>    198 |     public ByteLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       199 | 
       200 |         super(defaultValue, locale, pattern, locPattern);
       201 |     }
       202 | 
       203 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/DateLocaleConverter.java (line 219)

       214 |      * @param defaultValue  The default value to be returned
       215 |      * @param locale        The locale
       216 |      * @param pattern       The convertion pattern
       217 |      * @param locPattern    Indicate whether the pattern is localized or not
       218 |      */
>>>    219 |     public DateLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       220 | 
       221 |         super(defaultValue, locale, pattern, locPattern);
       222 |     }
       223 | 
       224 |     // --------------------------------------------------------- Methods

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/DecimalLocaleConverter.java (line 208)

       203 |      * @param defaultValue  The default value to be returned
       204 |      * @param locale        The locale
       205 |      * @param pattern       The convertion pattern
       206 |      * @param locPattern    Indicate whether the pattern is localized or not
       207 |      */
>>>    208 |     public DecimalLocaleConverter(final Object defaultValue, final Locale locale, final String pattern, final boolean locPattern) {
       209 | 
       210 |         super(defaultValue, locale, pattern, locPattern);
       211 | 
       212 |     }
       213 | 
S104 (java) on commons-beanutils - 1 issues removed, 1 issues added

Removed src/main/java/org/apache/commons/beanutils2/PropertyUtilsBean.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software

Added src/main/java/org/apache/commons/beanutils2/PropertyUtilsBean.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software
S105 (java) on commons-beanutils - 2 issues removed, 2 issues added

Removed src/main/java/org/apache/commons/beanutils2/BeanUtilsBean.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software

Removed src/main/java/org/apache/commons/beanutils2/DynaProperty.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software

Added src/main/java/org/apache/commons/beanutils2/BeanUtilsBean.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software

Added src/main/java/org/apache/commons/beanutils2/DynaProperty.java (file-level)

>>> FILE-LEVEL ISSUE
         1 | /*
         2 |  * Licensed to the Apache Software Foundation (ASF) under one or more
         3 |  * contributor license agreements.  See the NOTICE file distributed with
         4 |  * this work for additional information regarding copyright ownership.
         5 |  * The ASF licenses this file to You under the Apache License, Version 2.0
         6 |  * (the "License"); you may not use this file except in compliance with
         7 |  * the License.  You may obtain a copy of the License at
         8 |  *
         9 |  *      http://www.apache.org/licenses/LICENSE-2.0
        10 |  *
        11 |  * Unless required by applicable law or agreed to in writing, software
S106 (java) on commons-beanutils - 2 issues removed, 2 issues added

Removed src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 855)

       850 |      *
       851 |      * @param ex  the exception to log
       852 |      */
       853 |     protected void logInfo(final Exception ex) {
       854 |         // Deliberately do not use LOG4J or Commons Logging to avoid dependencies
>>>    855 |         System.out.println( "INFO: Exception: " + ex );
       856 |     }
       857 | 
       858 |     /**
       859 |      * Logs the given exception to <code>System.err</code>.  Used to display
       860 |      * errors while accessing/mutating the bean.

Removed src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 866)

       861 |      *
       862 |      * @param ex  the exception to log
       863 |      */
       864 |     protected void logWarn(final Exception ex) {
       865 |         // Deliberately do not use LOG4J or Commons Logging to avoid dependencies
>>>    866 |         System.out.println( "WARN: Exception: " + ex );
       867 |         ex.printStackTrace();
       868 |     }
       869 | }

Added src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 855)

       850 |      *
       851 |      * @param ex  the exception to log
       852 |      */
       853 |     protected void logInfo(final Exception ex) {
       854 |         // Deliberately do not use LOG4J or Commons Logging to avoid dependencies
>>>    855 |         System.out.println( "INFO: Exception: " + ex );
       856 |     }
       857 | 
       858 |     /**
       859 |      * Logs the given exception to <code>System.err</code>.  Used to display
       860 |      * errors while accessing/mutating the bean.

Added src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 866)

       861 |      *
       862 |      * @param ex  the exception to log
       863 |      */
       864 |     protected void logWarn(final Exception ex) {
       865 |         // Deliberately do not use LOG4J or Commons Logging to avoid dependencies
>>>    866 |         System.out.println( "WARN: Exception: " + ex );
       867 |         ex.printStackTrace();
       868 |     }
       869 | }
S1066 (java) on commons-beanutils - 1 issues removed, 1 issues added

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1295)

      1290 |      * @param md The method descriptor
      1291 |      * @param method The method to cache
      1292 |      */
      1293 |     private static void cacheMethod(final MethodDescriptor md, final Method method) {
      1294 |         if (CACHE_METHODS) {
>>>   1295 |             if (method != null) {
      1296 |                 cache.put(md, new WeakReference<>(method));
      1297 |             }
      1298 |         }
      1299 |     }
      1300 | 

Added src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1295)

      1290 |      * @param md The method descriptor
      1291 |      * @param method The method to cache
      1292 |      */
      1293 |     private static void cacheMethod(final MethodDescriptor md, final Method method) {
      1294 |         if (CACHE_METHODS) {
>>>   1295 |             if (method != null) {
      1296 |                 cache.put(md, new WeakReference<>(method));
      1297 |             }
      1298 |         }
      1299 |     }
      1300 | 
S1067 (java) on commons-beanutils - 5 issues removed, 5 issues added

Removed src/main/java/org/apache/commons/beanutils2/BasicDynaBean.java (line 436)

       431 |      * @return <code>true</code> if the source class is assignable to the
       432 |      * destination class, otherwise <code>false</code>
       433 |      */
       434 |     protected boolean isAssignable(final Class<?> dest, final Class<?> source) {
       435 | 
>>>    436 |         if (dest.isAssignableFrom(source) ||
       437 |                 dest == Boolean.TYPE && source == Boolean.class ||
       438 |                 dest == Byte.TYPE && source == Byte.class ||
       439 |                 dest == Character.TYPE && source == Character.class ||
       440 |                 dest == Double.TYPE && source == Double.class ||
       441 |                 dest == Float.TYPE && source == Float.class ||

Removed src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 848)

       843 |      * @param type The class of the property
       844 |      * @return The new value
       845 |      */
       846 |     protected Object createOtherProperty(final String name, final Class<?> type) {
       847 | 
>>>    848 |         if (type == Object.class    ||
       849 |             type == String.class    ||
       850 |             type == Boolean.class   ||
       851 |             type == Character.class ||
       852 |             Date.class.isAssignableFrom(type)) {
       853 | 

Removed src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 929)

       924 |      * @return <code>true</code> if the source class is assignable to the
       925 |      * destination class, otherwise <code>false</code>
       926 |      */
       927 |     protected boolean isAssignable(final Class<?> dest, final Class<?> source) {
       928 | 
>>>    929 |         if (dest.isAssignableFrom(source) ||
       930 |                 dest == Boolean.TYPE && source == Boolean.class ||
       931 |                 dest == Byte.TYPE && source == Byte.class ||
       932 |                 dest == Character.TYPE && source == Character.class ||
       933 |                 dest == Double.TYPE && source == Double.class ||
       934 |                 dest == Float.TYPE && source == Float.class ||

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1067)

      1062 |             final Log log = LogFactory.getLog(MethodUtils.class);
      1063 |             if (!loggedAccessibleWarning) {
      1064 |                 boolean vulnerableJVM = false;
      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
>>>   1067 |                     if (specVersion.charAt(0) == '1' &&
      1068 |                             (specVersion.charAt(2) == '0' ||
      1069 |                              specVersion.charAt(2) == '1' ||
      1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 

Removed src/main/java/org/apache/commons/beanutils2/locale/converters/StringLocaleConverter.java (line 236)

       231 |     @Override
       232 |     protected Object parse(final Object value, final String pattern) throws ParseException {
       233 | 
       234 |         String result = null;
       235 | 
>>>    236 |         if (value instanceof Integer ||
       237 |                 value instanceof Long ||
       238 |                 value instanceof BigInteger ||
       239 |                 value instanceof Byte ||
       240 |                 value instanceof Short) {
       241 | 

Added src/main/java/org/apache/commons/beanutils2/BasicDynaBean.java (line 436)

       431 |      * @return <code>true</code> if the source class is assignable to the
       432 |      * destination class, otherwise <code>false</code>
       433 |      */
       434 |     protected boolean isAssignable(final Class<?> dest, final Class<?> source) {
       435 | 
>>>    436 |         if (dest.isAssignableFrom(source) ||
       437 |                 dest == Boolean.TYPE && source == Boolean.class ||
       438 |                 dest == Byte.TYPE && source == Byte.class ||
       439 |                 dest == Character.TYPE && source == Character.class ||
       440 |                 dest == Double.TYPE && source == Double.class ||
       441 |                 dest == Float.TYPE && source == Float.class ||

Added src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 848)

       843 |      * @param type The class of the property
       844 |      * @return The new value
       845 |      */
       846 |     protected Object createOtherProperty(final String name, final Class<?> type) {
       847 | 
>>>    848 |         if (type == Object.class    ||
       849 |             type == String.class    ||
       850 |             type == Boolean.class   ||
       851 |             type == Character.class ||
       852 |             Date.class.isAssignableFrom(type)) {
       853 | 

Added src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 929)

       924 |      * @return <code>true</code> if the source class is assignable to the
       925 |      * destination class, otherwise <code>false</code>
       926 |      */
       927 |     protected boolean isAssignable(final Class<?> dest, final Class<?> source) {
       928 | 
>>>    929 |         if (dest.isAssignableFrom(source) ||
       930 |                 dest == Boolean.TYPE && source == Boolean.class ||
       931 |                 dest == Byte.TYPE && source == Byte.class ||
       932 |                 dest == Character.TYPE && source == Character.class ||
       933 |                 dest == Double.TYPE && source == Double.class ||
       934 |                 dest == Float.TYPE && source == Float.class ||

Added src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1067)

      1062 |             final Log log = LogFactory.getLog(MethodUtils.class);
      1063 |             if (!loggedAccessibleWarning) {
      1064 |                 boolean vulnerableJVM = false;
      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
>>>   1067 |                     if (specVersion.charAt(0) == '1' &&
      1068 |                             (specVersion.charAt(2) == '0' ||
      1069 |                              specVersion.charAt(2) == '1' ||
      1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 

Added src/main/java/org/apache/commons/beanutils2/locale/converters/StringLocaleConverter.java (line 236)

       231 |     @Override
       232 |     protected Object parse(final Object value, final String pattern) throws ParseException {
       233 | 
       234 |         String result = null;
       235 | 
>>>    236 |         if (value instanceof Integer ||
       237 |                 value instanceof Long ||
       238 |                 value instanceof BigInteger ||
       239 |                 value instanceof Byte ||
       240 |                 value instanceof Short) {
       241 | 
S108 (java) on commons-beanutils - 3 issues removed, 3 issues added

Removed src/test/java/org/apache/commons/beanutils2/MappedPropertyTestCase.java (line 290)

       285 |         final String property = "protectedMapped";
       286 |         final Class<?> clazz = MappedPropertyChildBean.class;
       287 |         try {
       288 |             new MappedPropertyDescriptor(property, clazz);
       289 |             fail("Property '" + property + "' found in " + clazz.getName());
>>>    290 |         } catch (final Exception ex) {
       291 |         }
       292 |     }
       293 | 
       294 | 
       295 |     /**

Removed src/test/java/org/apache/commons/beanutils2/MappedPropertyTestCase.java (line 320)

       315 |         final String property = "XXXXXX";
       316 |         final Class<?> clazz = MappedPropertyTestInterface.class;
       317 |         try {
       318 |             new MappedPropertyDescriptor(property, clazz);
       319 |             fail("Property '" + property + "' found in " + clazz.getName());
>>>    320 |         } catch (final Exception ex) {
       321 |         }
       322 |     }
       323 | 
       324 |     /**
       325 |      * Test Interface Inherited mapped property

Removed src/test/java/org/apache/commons/beanutils2/bugs/Jira347TestCase.java (line 114)

       109 |             try {
       110 |                 long i = 0;
       111 |                 while (true && ref.get() != null) {
       112 |                     list.add("A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String " + i++);
       113 |                 }
>>>    114 |             } catch (final Throwable ignored) {
       115 |             }
       116 |             list.clear();
       117 |             list = null;
       118 |             // System.out.println("Count " + count + " : " + getMemoryStats());
       119 |             System.gc();

Added src/test/java/org/apache/commons/beanutils2/MappedPropertyTestCase.java (line 290)

       285 |         final String property = "protectedMapped";
       286 |         final Class<?> clazz = MappedPropertyChildBean.class;
       287 |         try {
       288 |             new MappedPropertyDescriptor(property, clazz);
       289 |             fail("Property '" + property + "' found in " + clazz.getName());
>>>    290 |         } catch (final Exception ex) {
       291 |         }
       292 |     }
       293 | 
       294 | 
       295 |     /**

Added src/test/java/org/apache/commons/beanutils2/MappedPropertyTestCase.java (line 320)

       315 |         final String property = "XXXXXX";
       316 |         final Class<?> clazz = MappedPropertyTestInterface.class;
       317 |         try {
       318 |             new MappedPropertyDescriptor(property, clazz);
       319 |             fail("Property '" + property + "' found in " + clazz.getName());
>>>    320 |         } catch (final Exception ex) {
       321 |         }
       322 |     }
       323 | 
       324 |     /**
       325 |      * Test Interface Inherited mapped property

Added src/test/java/org/apache/commons/beanutils2/bugs/Jira347TestCase.java (line 114)

       109 |             try {
       110 |                 long i = 0;
       111 |                 while (true && ref.get() != null) {
       112 |                     list.add("A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String A Big String " + i++);
       113 |                 }
>>>    114 |             } catch (final Throwable ignored) {
       115 |             }
       116 |             list.clear();
       117 |             list = null;
       118 |             // System.out.println("Count " + count + " : " + getMemoryStats());
       119 |             System.gc();
S109 (java) on commons-beanutils - 19 issues removed, 19 issues added

Removed src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 119)

       114 |              */
       115 |         }
       116 | 
       117 |         // If there's no read method, then look for just a write method
       118 |         if (mappedReadMethod == null) {
>>>    119 |             mappedWriteMethod = getMethod(beanClass, "set" + base, 2);
       120 |         }
       121 | 
       122 |         if (mappedReadMethod == null && mappedWriteMethod == null) {
       123 |             throw new IntrospectionException("Property '" + propertyName +
       124 |                     "' not found on " +

Removed src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 175)

       170 |             final Class<?>[] params = { String.class, mappedReadMethod.getReturnType() };
       171 |             mappedWriteMethod =
       172 |                 getMethod(beanClass, mappedSetterName, params);
       173 |         } else {
       174 |             mappedWriteMethod =
>>>    175 |                 getMethod(beanClass, mappedSetterName, 2);
       176 |         }
       177 |         mappedReadMethodRef  = new MappedMethodReference(mappedReadMethod);
       178 |         mappedWriteMethodRef = new MappedMethodReference(mappedWriteMethod);
       179 | 
       180 |         findMappedPropertyType();

Removed src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 302)

       297 |                 }
       298 |             }
       299 | 
       300 |             if (mappedWriteMethod != null) {
       301 |                 final Class<?>[] params = mappedWriteMethod.getParameterTypes();
>>>    302 |                 if (params.length != 2) {
       303 |                     throw new IntrospectionException
       304 |                             ("bad mapped write method arg count");
       305 |                 }
       306 |                 if (mappedPropertyType != null &&
       307 |                         mappedPropertyType != params[1]) {

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1068)

      1063 |             if (!loggedAccessibleWarning) {
      1064 |                 boolean vulnerableJVM = false;
      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
      1067 |                     if (specVersion.charAt(0) == '1' &&
>>>   1068 |                             (specVersion.charAt(2) == '0' ||
      1069 |                              specVersion.charAt(2) == '1' ||
      1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 
      1073 |                         vulnerableJVM = true;

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1069)

      1064 |                 boolean vulnerableJVM = false;
      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
      1067 |                     if (specVersion.charAt(0) == '1' &&
      1068 |                             (specVersion.charAt(2) == '0' ||
>>>   1069 |                              specVersion.charAt(2) == '1' ||
      1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 
      1073 |                         vulnerableJVM = true;
      1074 |                     }

Removed src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1070)

      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
      1067 |                     if (specVersion.charAt(0) == '1' &&
      1068 |                             (specVersion.charAt(2) == '0' ||
      1069 |                              specVersion.charAt(2) == '1' ||
>>>   1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 
      1073 |                         vulnerableJVM = true;
      1074 |                     }
      1075 |                 } catch (final SecurityException e) {

Removed src/main/java/org/apache/commons/beanutils2/PropertyUtilsBean.java (line 1619)

      1614 |         if (descriptor instanceof IndexedPropertyDescriptor) {
      1615 |             Method writeMethod = ((IndexedPropertyDescriptor) descriptor).
      1616 |                     getIndexedWriteMethod();
      1617 |             writeMethod = MethodUtils.getAccessibleMethod(bean.getClass(), writeMethod);
      1618 |             if (writeMethod != null) {
>>>   1619 |                 final Object[] subscript = new Object[2];
      1620 |                 subscript[0] = Integer.valueOf(index);
      1621 |                 subscript[1] = value;
      1622 |                 try {
      1623 |                     if (log.isTraceEnabled()) {
      1624 |                         final String valueClassName =

Removed src/main/java/org/apache/commons/beanutils2/PropertyUtilsBean.java (line 1787)

      1782 |             Method mappedWriteMethod =
      1783 |                     ((MappedPropertyDescriptor) descriptor).
      1784 |                     getMappedWriteMethod();
      1785 |             mappedWriteMethod = MethodUtils.getAccessibleMethod(bean.getClass(), mappedWriteMethod);
      1786 |             if (mappedWriteMethod != null) {
>>>   1787 |                 final Object[] params = new Object[2];
      1788 |                 params[0] = key;
      1789 |                 params[1] = value;
      1790 |                 if (log.isTraceEnabled()) {
      1791 |                     final String valueClassName =
      1792 |                         value == null ? "<null>" : value.getClass().getName();

Removed src/main/java/org/apache/commons/beanutils2/converters/DateTimeConverter.java (line 303)

       298 |             // ---------------------- JDK 1.3 Fix ----------------------
       299 |             // N.B. Prior to JDK 1.4 the Timestamp's getTime() method
       300 |             //      didn't include the milliseconds. The following code
       301 |             //      ensures it works consistently accross JDK versions
       302 |             final java.sql.Timestamp timestamp = (java.sql.Timestamp)value;
>>>    303 |             long timeInMillis = ((timestamp.getTime() / 1000) * 1000);
       304 |             timeInMillis += timestamp.getNanos() / 1000000;
       305 |             // ---------------------- JDK 1.3 Fix ----------------------
       306 |             return toDate(targetType, timeInMillis);
       307 |         }
       308 | 

Removed src/main/java/org/apache/commons/beanutils2/converters/DateTimeConverter.java (line 304)

       299 |             // N.B. Prior to JDK 1.4 the Timestamp's getTime() method
       300 |             //      didn't include the milliseconds. The following code
       301 |             //      ensures it works consistently accross JDK versions
       302 |             final java.sql.Timestamp timestamp = (java.sql.Timestamp)value;
       303 |             long timeInMillis = ((timestamp.getTime() / 1000) * 1000);
>>>    304 |             timeInMillis += timestamp.getNanos() / 1000000;
       305 |             // ---------------------- JDK 1.3 Fix ----------------------
       306 |             return toDate(targetType, timeInMillis);
       307 |         }
       308 | 
       309 |         // Handle Date (includes java.sql.Date & java.sql.Time)

Removed src/main/java/org/apache/commons/beanutils2/expression/DefaultResolver.java (line 98)

        93 |                 if (value.length() == 0) {
        94 |                     throw new IllegalArgumentException("No Index Value");
        95 |                 }
        96 |                 int index = 0;
        97 |                 try {
>>>     98 |                     index = Integer.parseInt(value, 10);
        99 |                 } catch (final Exception e) {
       100 |                     throw new IllegalArgumentException("Invalid index value '"
       101 |                             + value + "'");
       102 |                 }
       103 |                 return index;

Added src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 119)

       114 |              */
       115 |         }
       116 | 
       117 |         // If there's no read method, then look for just a write method
       118 |         if (mappedReadMethod == null) {
>>>    119 |             mappedWriteMethod = getMethod(beanClass, "set" + base, 2);
       120 |         }
       121 | 
       122 |         if (mappedReadMethod == null && mappedWriteMethod == null) {
       123 |             throw new IntrospectionException("Property '" + propertyName +
       124 |                     "' not found on " +

Added src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 175)

       170 |             final Class<?>[] params = { String.class, mappedReadMethod.getReturnType() };
       171 |             mappedWriteMethod =
       172 |                 getMethod(beanClass, mappedSetterName, params);
       173 |         } else {
       174 |             mappedWriteMethod =
>>>    175 |                 getMethod(beanClass, mappedSetterName, 2);
       176 |         }
       177 |         mappedReadMethodRef  = new MappedMethodReference(mappedReadMethod);
       178 |         mappedWriteMethodRef = new MappedMethodReference(mappedWriteMethod);
       179 | 
       180 |         findMappedPropertyType();

Added src/main/java/org/apache/commons/beanutils2/MappedPropertyDescriptor.java (line 302)

       297 |                 }
       298 |             }
       299 | 
       300 |             if (mappedWriteMethod != null) {
       301 |                 final Class<?>[] params = mappedWriteMethod.getParameterTypes();
>>>    302 |                 if (params.length != 2) {
       303 |                     throw new IntrospectionException
       304 |                             ("bad mapped write method arg count");
       305 |                 }
       306 |                 if (mappedPropertyType != null &&
       307 |                         mappedPropertyType != params[1]) {

Added src/main/java/org/apache/commons/beanutils2/MethodUtils.java (line 1068)

      1063 |             if (!loggedAccessibleWarning) {
      1064 |                 boolean vulnerableJVM = false;
      1065 |                 try {
      1066 |                     final String specVersion = System.getProperty("java.specification.version");
      1067 |                     if (specVersion.charAt(0) == '1' &&
>>>   1068 |                             (specVersion.charAt(2) == '0' ||
      1069 |                              specVersion.charAt(2) == '1' ||
      1070 |                              specVersion.charAt(2) == '2' ||
      1071 |                              specVersion.charAt(2) == '3')) {
      1072 | 
      1073 |                         vulnerableJVM = true;
S110 (java) on commons-beanutils - 1 issues removed, 1 issues added

Removed src/main/java/org/apache/commons/beanutils2/NestedNullException.java (line 27)

        22 |  * against given bean since a nested bean referenced is null.
        23 |  *
        24 |  * @since 1.7
        25 |  */
        26 | 
>>>     27 | public class NestedNullException extends BeanAccessLanguageException {
        28 | 
        29 |     private static final long serialVersionUID = 1L;
        30 | 
        31 |     // --------------------------------------------------------- Constuctors
        32 | 

Added src/main/java/org/apache/commons/beanutils2/NestedNullException.java (line 27)

        22 |  * against given bean since a nested bean referenced is null.
        23 |  *
        24 |  * @since 1.7
        25 |  */
        26 | 
>>>     27 | public class NestedNullException extends BeanAccessLanguageException {
        28 | 
        29 |     private static final long serialVersionUID = 1L;
        30 | 
        31 |     // --------------------------------------------------------- Constuctors
        32 | 
S1105 (java) on commons-beanutils - 2 issues removed, 2 issues added

Removed src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 201)

       196 | 
       197 |         if (!comparator.equals(beanComparator.comparator)) {
       198 |             return false;
       199 |         }
       200 |         if (property != null)
>>>    201 |         {
       202 |             if (!property.equals(beanComparator.property)) {
       203 |                 return false;
       204 |             }
       205 |         }
       206 |         else

Removed src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 207)

       202 |             if (!property.equals(beanComparator.property)) {
       203 |                 return false;
       204 |             }
       205 |         }
       206 |         else
>>>    207 |         {
       208 |             return beanComparator.property == null;
       209 |         }
       210 | 
       211 |         return true;
       212 |     }

Added src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 201)

       196 | 
       197 |         if (!comparator.equals(beanComparator.comparator)) {
       198 |             return false;
       199 |         }
       200 |         if (property != null)
>>>    201 |         {
       202 |             if (!property.equals(beanComparator.property)) {
       203 |                 return false;
       204 |             }
       205 |         }
       206 |         else

Added src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 207)

       202 |             if (!property.equals(beanComparator.property)) {
       203 |                 return false;
       204 |             }
       205 |         }
       206 |         else
>>>    207 |         {
       208 |             return beanComparator.property == null;
       209 |         }
       210 | 
       211 |         return true;
       212 |     }
S1107 (java) on commons-beanutils - 53 issues removed, 53 issues added

Removed src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 168)

       163 |         try {
       164 |             final Object value1 = PropertyUtils.getProperty( o1, property );
       165 |             final Object value2 = PropertyUtils.getProperty( o2, property );
       166 |             return internalCompare( value1, value2 );
       167 |         }
>>>    168 |         catch ( final IllegalAccessException iae ) {
       169 |             throw new RuntimeException( "IllegalAccessException: " + iae.toString() );
       170 |         }
       171 |         catch ( final InvocationTargetException ite ) {
       172 |             throw new RuntimeException( "InvocationTargetException: " + ite.toString() );
       173 |         }

Removed src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 171)

       166 |             return internalCompare( value1, value2 );
       167 |         }
       168 |         catch ( final IllegalAccessException iae ) {
       169 |             throw new RuntimeException( "IllegalAccessException: " + iae.toString() );
       170 |         }
>>>    171 |         catch ( final InvocationTargetException ite ) {
       172 |             throw new RuntimeException( "InvocationTargetException: " + ite.toString() );
       173 |         }
       174 |         catch ( final NoSuchMethodException nsme ) {
       175 |             throw new RuntimeException( "NoSuchMethodException: " + nsme.toString() );
       176 |         }

Removed src/main/java/org/apache/commons/beanutils2/BeanComparator.java (line 174)

       169 |             throw new RuntimeException( "IllegalAccessException: " + iae.toString() );
       170 |         }
       171 |         catch ( final InvocationTargetException ite ) {
       172 |             throw new RuntimeException( "InvocationTargetException: " + ite.toString() );
       173 |         }
>>>    174 |         catch ( final NoSuchMethodException nsme ) {
       175 |             throw new RuntimeException( "NoSuchMethodException: " + nsme.toString() );
       176 |         }
       177 |     }
       178 | 
       179 |     /**

Removed src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 295)

       290 |         Class<? extends Object> beanClass = null;
       291 |         try {
       292 |             beanClass = bean.getClass();
       293 |             bean = beanClass.newInstance();
       294 |         }
>>>    295 |         catch (final Exception e) {
       296 |             final UnsupportedOperationException uoe =
       297 |                 new UnsupportedOperationException("Could not create new instance of class: " + beanClass);
       298 |             BeanUtils.initCause(uoe, e);
       299 |             throw uoe;
       300 |         }

Removed src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 361)

       356 |             final Method method = getReadMethod( name );
       357 |             if ( method != null ) {
       358 |                 try {
       359 |                     return method.invoke( bean, NULL_ARGUMENTS );
       360 |                 }
>>>    361 |                 catch (  final IllegalAccessException e ) {
       362 |                     logWarn( e );
       363 |                 }
       364 |                 catch ( final IllegalArgumentException e ) {
       365 |                     logWarn(  e );
       366 |                 }

Removed src/main/java/org/apache/commons/beanutils2/BeanMap.java (line 364)

       359 |                     return method.invoke( bean, NULL_ARGUMENTS );
       360 |                 }
       361 |                 catch (  final IllegalAccessException e ) {
       362 |                     logWarn( e );
       363 |                 }
>>>    364 |                 catch ( final IllegalArgumentException e ) {
       365 |                     logWarn(  e );
       366 |                 }
       367 |                 catch ( final InvocationTargetException e ) {
       368 |                     logWarn(  e );
       369 |                 }

Removed src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 725)

       720 |                 indexedProperty = defaultIndexedProperty(name);
       721 |             } else {
       722 |                 try {
       723 |                     indexedProperty = type.newInstance();
       724 |                 }
>>>    725 |                 catch (final Exception ex) {
       726 |                     throw new IllegalArgumentException
       727 |                         ("Error instantiating indexed property of type '" +
       728 |                                    type.getName() + "' for '" + name + "' " + ex);
       729 |                 }
       730 |             }

Removed src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 764)

       759 | 
       760 |         } else if (Map.class.isAssignableFrom(type)) {
       761 |             try {
       762 |                 mappedProperty = type.newInstance();
       763 |             }
>>>    764 |             catch (final Exception ex) {
       765 |                 throw new IllegalArgumentException
       766 |                     ("Error instantiating mapped property of type '" +
       767 |                             type.getName() + "' for '" + name + "' " + ex);
       768 |             }
       769 |         } else {

Removed src/main/java/org/apache/commons/beanutils2/LazyDynaBean.java (line 789)

       784 |      */
       785 |     protected Object createDynaBeanProperty(final String name, final Class<?> type) {
       786 |         try {
       787 |             return type.newInstance();
       788 |         }
>>>    789 |         catch (final Exception ex) {
       790 |             if (logger().isWarnEnabled()) {
       791 |                 logger().warn("Error instantiating DynaBean property of type '" +
       792 |                         type.getName() + "' for '" + name + "' " + ex);
       793 |             }
       794 |             return null;

Removed src/main/java/org/apache/commons/beanutils2/ResultSetDynaClass.java (line 243)

       238 |     protected Class<?> loadClass(final String className) throws SQLException {
       239 | 
       240 |         try {
       241 |             return getClass().getClassLoader().loadClass(className);
       242 |         }
>>>    243 |         catch (final Exception e) {
       244 |             throw new SQLException("Cannot load column class '" +
       245 |                                    className + "': " + e);
       246 |         }
       247 |     }
       248 | }

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleBeanUtilsBean.java (line 647)

       642 |             sb.append(name);
       643 |             sb.append(", ");
       644 |             if (value == null) {
       645 |                 sb.append("<NULL>");
       646 |             }
>>>    647 |             else if (value instanceof String) {
       648 |                 sb.append((String) value);
       649 |             }
       650 |             else if (value instanceof String[]) {
       651 |                 final String[] values = (String[]) value;
       652 |                 sb.append('[');

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleBeanUtilsBean.java (line 650)

       645 |                 sb.append("<NULL>");
       646 |             }
       647 |             else if (value instanceof String) {
       648 |                 sb.append((String) value);
       649 |             }
>>>    650 |             else if (value instanceof String[]) {
       651 |                 final String[] values = (String[]) value;
       652 |                 sb.append('[');
       653 |                 for (int i = 0; i < values.length; i++) {
       654 |                     if (i > 0) {
       655 |                         sb.append(',');

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleBeanUtilsBean.java (line 661)

       656 |                     }
       657 |                     sb.append(values[i]);
       658 |                 }
       659 |                 sb.append(']');
       660 |             }
>>>    661 |             else {
       662 |                 sb.append(value.toString());
       663 |             }
       664 |             sb.append(')');
       665 |             log.trace(sb.toString());
       666 |         }

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleConvertUtilsBean.java (line 144)

       139 |     public void setDefaultLocale(final Locale locale) {
       140 | 
       141 |         if (locale == null) {
       142 |             defaultLocale = Locale.getDefault();
       143 |         }
>>>    144 |         else {
       145 |             defaultLocale = locale;
       146 |         }
       147 |     }
       148 | 
       149 |     /**

Removed src/main/java/org/apache/commons/beanutils2/locale/LocaleConvertUtilsBean.java (line 440)

       435 |         Map<Class<?>, LocaleConverter> localeConverters;
       436 | 
       437 |         if (locale == null) {
       438 |             localeConverters = (Map<Class<?>, LocaleConverter>) mapConverters.get(defaultLocale);
       439 |         }
>>>    440 |         else {
       441 |             localeConverters = (Map<Class<?>, LocaleConverter>) mapConverters.get(locale);
       442 | 
       443 |             if (localeConverters == null) {
       444 |                 localeConverters = create(locale);
       445 |                 mapConverters.put(locale, localeConverters);

... and 1367 more rules with changes (diff too large to display fully)

@romainbrenguier
romainbrenguier marked this pull request as ready for review October 5, 2026 09:42

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant