dependabot[bot] opened a new pull request, #21410: URL: https://github.com/apache/camel/pull/21410
Bumps [com.cedarsoftware:java-util](https://github.com/jdereg/java-util) from 4.90.0 to 4.93.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/jdereg/java-util/blob/master/changelog.md">com.cedarsoftware:java-util's changelog</a>.</em></p> <blockquote> <h4>4.93.0 - 2026-02-10</h4> <ul> <li><strong>BUG FIX</strong>: <code>ArrayConversions.enumSetToArray()</code> - <code>ArrayStoreException</code> when converting <code>EnumSet</code> to <code>Long[]</code>. Ordinal values (autoboxed <code>Integer</code>) were stored directly into <code>Long[]</code> arrays. Split <code>Integer</code>/<code>Long</code> branches and added explicit <code>(long)</code> cast.</li> <li><strong>BUG FIX</strong>: <code>CollectionHandling.sizeOrDefault()</code> - <code>ArrayBlockingQueue</code> overflow when converting arrays with >16 elements. <code>sizeOrDefault()</code> only handled <code>Collection</code> sources, returning hardcoded 16 for arrays. Added <code>Array.getLength()</code> path for array sources.</li> <li><strong>BUG FIX</strong>: <code>CollectionHandling</code> - <code>SynchronousQueue</code> and <code>DelayQueue</code> now throw descriptive <code>IllegalArgumentException</code> when used as conversion targets, instead of silently failing at runtime (<code>Queue full</code> / <code>ClassCastException</code>).</li> <li><strong>BUG FIX</strong>: <code>MapConversions.toThrowable()</code> - <code>ClassCastException</code> when <code>causeMessage</code> map entry was a non-String value (e.g., <code>Integer</code>). Replaced unchecked <code>(String)</code> cast with <code>.toString()</code>.</li> <li><strong>BUG FIX</strong>: <code>MapConversions.analyzeTarget()</code> - Failed to detect <code>UnmodifiableSortedMap</code>, <code>UnmodifiableNavigableMap</code>, and their synchronized/checked variants. <code>endsWith("$UnmodifiableMap")</code> missed inner class names like <code>$UnmodifiableSortedMap</code>. Changed to <code>contains("$Unmodifiable") && endsWith("Map")</code> (and similarly for Synchronized, Checked, Empty, Singleton).</li> <li><strong>BUG FIX</strong>: <code>MapConversions.toColor()</code> - Packed <code>rgb</code> integer ignored explicit <code>alpha</code> map entry. When both <code>rgb</code> and <code>alpha</code> keys were present, alpha bits from the packed int (often 0) overwrote the explicit alpha value. Now decomposes RGB channels and applies explicit alpha separately.</li> <li><strong>BUG FIX</strong>: <code>MapConversions.copyEntries()</code> - Caught all <code>Exception</code> types, silently swallowing errors during map entry copying. Narrowed to <code>ClassCastException | NullPointerException</code> (the only exceptions <code>Map.put()</code> throws for incompatible entries).</li> <li><strong>BUG FIX</strong>: <code>NumberConversions.toYear()</code> - Used <code>shortValue()</code> instead of <code>intValue()</code>, silently truncating year values outside -32768..32767 (e.g., year 40000 became -25536).</li> <li><strong>BUG FIX</strong>: <code>NumberConversions.floatingPointToBigInteger()</code> - <code>NaN</code> and <code>Infinity</code> caused <code>NumberFormatException</code> from <code>new BigInteger("NaN")</code>. Added explicit guard with descriptive <code>IllegalArgumentException</code>.</li> <li><strong>BUG FIX</strong>: <code>NumberConversions.floatToString()</code> / <code>doubleToString()</code> - Negative zero (<code>-0.0</code>) collapsed to <code>"0"</code> because <code>== 0</code> is <code>true</code> for both <code>-0.0</code> and <code>+0.0</code>. Used <code>floatToRawIntBits</code> / <code>doubleToRawLongBits</code> to distinguish them, preserving IEEE 754 round-tripping.</li> <li><strong>BUG FIX</strong>: <code>BigIntegerConversions.toUUID()</code> - Silently truncated values exceeding 128 bits instead of throwing. A 129-bit value would have its high bits dropped, producing a completely wrong UUID. Added overflow check.</li> <li><strong>BUG FIX</strong>: <code>DateConversions</code> - <code>toString()</code>, <code>toYear()</code>, <code>toYearMonth()</code>, <code>toMonthDay()</code>, <code>toSqlDate()</code> called <code>date.toInstant()</code> directly, which throws <code>UnsupportedOperationException</code> on <code>java.sql.Date</code>. Replaced with the safe <code>toInstant(from, converter)</code> helper that wraps sql.Date via <code>new Date(date.getTime())</code>.</li> <li><strong>BUG FIX</strong>: <code>CalendarConversions</code> - <code>toYear()</code>, <code>toYearMonth()</code>, <code>toMonthDay()</code>, <code>toSqlDate()</code> used the converter's configured zone instead of the Calendar's own timezone, inconsistent with <code>toZonedDateTime()</code>/<code>toLocalDate()</code>/<code>toLocalDateTime()</code> which correctly use the Calendar's zone. Added direct <code>Calendar →</code> registrations for Year, YearMonth, MonthDay, and SqlDate in Converter to bypass the surrogate bridge (which was routing through <code>ZonedDateTimeConversions</code> and applying the converter's zone). Now all Calendar conversions consistently use the Calendar's own timezone.</li> <li><strong>PERFORMANCE</strong>: <code>CalendarConversions</code> - <code>toString()</code> created two new <code>DateTimeFormatter</code> instances per call. Cached as static final fields.</li> <li><strong>PERFORMANCE</strong>: <code>CalendarConversions</code> - <code>toLong()</code>, <code>toAtomicLong()</code>, <code>toDouble()</code>, <code>toBigDecimal()</code>, <code>toBigInteger()</code> used <code>calendar.getTime().getTime()</code> creating an intermediate <code>Date</code> object. Replaced with <code>calendar.getTimeInMillis()</code>.</li> <li><strong>BUG FIX</strong>: <code>InstantConversions.toOffsetDateTime()</code> - Used <code>System.currentTimeMillis()</code> to determine timezone offset instead of the instant's own epoch time. A summer Instant (DST active, e.g. EDT -04:00) converted in winter would incorrectly get the winter offset (EST -05:00). Replaced with <code>instant.atZone(zoneId).toOffsetDateTime()</code> which determines the correct offset at the instant's point in time.</li> <li><strong>BUG FIX</strong>: <code>LocalDateConversions.toTimestamp()</code> - Ignored converter's timezone by computing epoch millis via <code>toEpochDay() * 86400 * 1000</code> (hardcoded UTC midnight). Inconsistent with <code>toLong()</code>, <code>toDate()</code>, <code>toInstant()</code> which all respect the converter's zone. Replaced with <code>Timestamp.from(toInstant())</code>.</li> <li><strong>BUG FIX</strong>: <code>LocalDateConversions.toOffsetDateTime()</code> - Same <code>System.currentTimeMillis()</code> DST bug as InstantConversions. A summer LocalDate with a DST-observing zone would get the wrong offset. Delegated through <code>toZonedDateTime().toOffsetDateTime()</code>.</li> <li><strong>PERFORMANCE</strong>: <code>LocalDateConversions.toZonedDateTime()</code> - Replaced <code>LocalTime.parse("00:00:00")</code> with <code>LocalTime.MIDNIGHT</code> constant.</li> <li><strong>BUG FIX</strong>: <code>MonthDayConversions.toByte()</code> - Silent overflow for nearly all valid MonthDay values. MMDD format produces 101–1231 but byte range is -128..127, so <code>(byte) 1225</code> silently became <code>(byte) -55</code>. Added overflow check.</li> <li><strong>BUG FIX</strong>: <code>DurationConversions.toOffsetDateTime()</code> - Same <code>System.currentTimeMillis()</code> DST bug. Delegated through <code>toZonedDateTime().toOffsetDateTime()</code>.</li> <li><strong>BUG FIX</strong>: <code>DurationConversions.toSqlDate()</code> - Hardcoded UTC (<code>ZoneOffset.UTC</code>) for day boundary calculation while sibling methods <code>toLocalDate()</code> and <code>toLocalDateTime()</code> use the converter's zone. Delegated through <code>toLocalDate()</code> for consistency.</li> <li><strong>BUG FIX</strong>: <code>StringConversions.toLong()</code> - Used <code>compareTo() == -1</code> and <code>compareTo() == 1</code> instead of <code>< 0</code> / <code>> 0</code> for range checks. The <code>Comparable.compareTo()</code> contract only guarantees negative/zero/positive, not specifically -1/0/1.</li> <li><strong>BUG FIX</strong>: <code>StringConversions.toCharacter()</code> - Silent truncation for digit strings representing values > 65535. <code>(char) Integer.parseInt("65536")</code> silently became <code>'\0'</code>. Added range check to throw <code>IllegalArgumentException</code> for values outside 0–65535.</li> <li><strong>BUG FIX</strong>: <code>StringConversions.toColor()</code> - <code>rgb()</code> and <code>rgba()</code> functional notation parsing was case-sensitive. <code>"RGB(255,0,0)"</code> or <code>"Rgb(255,0,0)"</code> failed with <code>IllegalArgumentException</code>. Now uses case-insensitive prefix matching.</li> <li><strong>BUG FIX</strong>: <code>EnumConversions.processElement()</code> - String elements in collections/arrays bypassed the <code>maxEnumNameLength</code> guard when converting to <code>EnumSet</code>. The <code>stringToEnum()</code> method enforced the limit, but <code>processElement()</code> called <code>Enum.valueOf()</code> directly without the length check. Now applies the same guard consistently.</li> <li><strong>BUG FIX</strong>: <code>PatternConversions.toMap()</code> / <code>MapConversions.toPattern()</code> - Pattern flags (<code>CASE_INSENSITIVE</code>, <code>MULTILINE</code>, etc.) were lost during serialization. <code>toMap()</code> only stored the pattern string, and <code>toPattern()</code> compiled without flags. Now <code>toMap()</code> includes a <code>"flags"</code> entry when non-zero, and <code>toPattern()</code> reads it to restore the original flags.</li> <li><strong>BUG FIX</strong>: <code>PathConversions.toFile()</code> - <code>UnsupportedOperationException</code> propagated uncaught when converting a <code>Path</code> from a non-default filesystem (e.g., zip filesystem) to <code>File</code>. <code>Path.toFile()</code> only works for the default filesystem provider. Now catches <code>UnsupportedOperationException</code> and wraps it in a descriptive <code>IllegalArgumentException</code>.</li> <li><strong>BUG FIX</strong>: <code>DimensionConversions.toInteger()</code> - Silent integer overflow when computing area (<code>width * height</code>). For example, <code>50000 × 50000 = 2,500,000,000</code> exceeds <code>Integer.MAX_VALUE</code> and wrapped to a negative value. Replaced with <code>Math.multiplyExact()</code> which throws <code>ArithmeticException</code> on overflow.</li> <li><strong>BUG FIX</strong>: <code>PointConversions.toInteger()</code> / <code>toLong()</code> / <code>toBigInteger()</code> - Silently discarded the Y coordinate, returning only X. A 2D Point has no meaningful single-number representation. Now throws <code>IllegalArgumentException</code>, consistent with <code>toBigDecimal()</code> which already threw.</li> <li><strong>BUG FIX</strong>: <code>RectangleConversions.toInteger()</code> - Silent integer overflow when computing area (<code>width * height</code>). Replaced with <code>Math.multiplyExact()</code> which throws <code>ArithmeticException</code> on overflow.</li> <li><strong>BUG FIX</strong>: <code>RectangleConversions.toInsets()</code> - Silent integer overflow when computing <code>bottom</code> (<code>y + height</code>) and <code>right</code> (<code>x + width</code>). Replaced with <code>Math.addExact()</code> which throws <code>ArithmeticException</code> on overflow.</li> <li><strong>BUG FIX</strong>: <code>InsetsConversions.toInteger()</code> - Silent integer overflow when summing <code>top + left + bottom + right</code>. Replaced with chained <code>Math.addExact()</code> calls.</li> <li><strong>BUG FIX</strong>: <code>InsetsConversions.toDimension()</code> - Silent integer overflow when computing <code>left + right</code> (width) and <code>top + bottom</code> (height). Replaced with <code>Math.addExact()</code>.</li> <li><strong>BUG FIX</strong>: <code>InsetsConversions.toRectangle()</code> - Silent integer overflow when computing <code>right - left</code> (width) and <code>bottom - top</code> (height). Replaced with <code>Math.subtractExact()</code>.</li> <li><strong>PERFORMANCE</strong>: <code>ConverterOptions.getCustomOptions()</code> / <code>getConverterOverrides()</code> - Default implementations allocated a new <code>HashMap<>()</code> on every call. Replaced with <code>Collections.emptyMap()</code> since the defaults represent empty, read-only maps.</li> <li><strong>CLEANUP</strong>: Removed ~131 dead conversion methods across 25 source files. These methods were not registered in <code>Converter.CONVERSION_DB</code> and not called internally by any registered method. The surrogate/bridge system (e.g., <code>X → Long → AtomicLong</code>, <code>Calendar → ZonedDateTime → *</code>) auto-chains these conversions, making the explicit methods redundant. Key removals: all <code>toAtomicLong</code> from 9 temporal classes, geometry cross-conversion methods from <code>DimensionConversions</code>/<code>PointConversions</code>/<code>RectangleConversions</code>/<code>InsetsConversions</code>, 26 geometry+atomic methods from <code>NumberConversions</code> (807→366 lines), all numeric methods from <code>MonthDayConversions</code>, 25 unused array/atomic/string methods from <code>UniversalConversions</code> (1035→726 lines), and atomic bridge methods from <code>BooleanConversions</code>/<code>CharacterConversions</code>/<code>StringC onversions</code>/<code>CalendarConversions</code>/<code>BigDecimalConversions</code>/<code>UrlConversions</code>/<code>ColorConversions</code>/<code>DurationConversions</code>/<code>OffsetTimeConversions</code>/<code>YearConversions</code>. All 18,652 existing tests pass.</li> <li><strong>CLEANUP</strong>: Temporal hub-and-spoke — extended the surrogate/bridge system to treat <code>Instant</code>, <code>LocalDateTime</code>, <code>LocalDate</code>, <code>OffsetDateTime</code>, <code>Date</code>, and <code>Timestamp</code> as surrogates of <code>ZonedDateTime</code>. Removed ~45 passthrough methods that simply chained <code>X → ZonedDateTime → Target</code> (e.g., <code>InstantConversions.toLocalDate()</code> was <code>toZonedDateTime(from, converter).toLocalDate()</code>). The bridge system now auto-generates these composite conversions at init time. Removed methods from <code>InstantConversions</code> (5), <code>LocalDateTimeConversions</code> (15), <code>LocalDateConversions</code> (10), <code>OffsetDateTimeConversions</code> (7), and <code>DateConversions</code> (8). Net gain of 4 new conversion paths discovered by the bridge (e.g., <code>Instant → MonthDay/Year/YearMonth</code>, <code>LocalDate → LocalTime</code>). All 18,640 tests pass.</ li> <li><strong>BUG FIX</strong>: <code>ObjectConversions.convertFieldValueIterative()</code> - Complex nested objects inside collections, maps, and arrays were converted to <code>toString()</code> (e.g., <code>"Foo@1a2b3c4"</code>), losing all structured data. Now recursively converts them to Map representations preserving field names and values.</li> <li><strong>PERFORMANCE</strong>: <code>ObjectConversions.isRecord()</code> - <code>ReflectionUtils.getMethod(Class.class, "isRecord")</code> was called on every invocation. Cached the <code>Method</code> reference in a static final field.</li> <li><strong>PERFORMANCE</strong>: <code>ObjectConversions.convertToJsonCompatible()</code> - Numbers were round-tripped through <code>toString()</code> → <code>parseToMinimalNumericType()</code>, which could change types (e.g., <code>int 30</code> → <code>Long 30</code>). Standard numeric types now pass through directly.</li> <li><strong>BUG FIX</strong>: <code>UniversalConversions</code> - 7 bidirectional array methods (<code>byteArrayToByteArray</code>, <code>integerArrayToIntArray</code>, etc.) always threw <code>ClassCastException</code> in the else branch. Cast <code>(primitive[]) (Object) Wrapper[]</code> is invalid — <code>Byte[]</code> cannot be cast to <code>byte[]</code>. Changed return types to <code>Object</code> to support both directions.</li> <li><strong>BUG FIX</strong>: <code>UniversalConversions</code> - 5 NIO buffer-to-array methods (<code>intBufferToIntArray</code>, <code>longBufferToLongArray</code>, etc.) destroyed pre-existing marks on the source buffer via <code>mark()</code>/<code>reset()</code>. Replaced with <code>duplicate().get()</code> which reads from a copy, leaving the original buffer's position and mark untouched.</li> <li><strong>PERFORMANCE</strong>: <code>UniversalConversions</code> - <code>intArrayToAtomicIntegerArray()</code> and <code>longArrayToAtomicLongArray()</code> used manual element-by-element loops instead of <code>new AtomicIntegerArray(int[])</code> / <code>new AtomicLongArray(long[])</code> constructors which copy the array directly.</li> <li><strong>BUG FIX</strong>: <code>CharacterArrayConversions</code> - Null elements in <code>Character[]</code> produced literal <code>"null"</code> string instead of being skipped. <code>StringBuilder.append(Object)</code> converts null to <code>"null"</code>, so <code>{'a', null, 'b'}</code> became <code>"anullb"</code>. Now skips null elements in <code>toString()</code>, <code>toStringBuilder()</code>, and <code>toStringBuffer()</code>.</li> <li><strong>BUG FIX</strong>: <code>TimeZoneConversions.toZoneOffset()</code> - Used <code>getRawOffset()</code> which ignores DST. For a zone currently in daylight saving (e.g., Australia/Sydney in February = AEDT +11:00), returned the standard offset (+10:00) instead. Now delegates through <code>toZoneId().getRules().getOffset(Instant.now())</code>, consistent with <code>ZoneIdConversions.toZoneOffset()</code>.</li> <li><strong>JAVA 25+ PREP</strong>: <code>Unsafe</code> - Added <code>ReflectionFactory.newConstructorForSerialization()</code> as preferred strategy for constructor-bypassing instantiation, falling back to <code>sun.misc.Unsafe</code> only when ReflectionFactory is unavailable. Caches serialization constructors per class.</li> <li><strong>BUG FIX</strong>: <code>RegexUtilities</code> - Pattern caches used <code>ConcurrentHashMap</code> which rejects null from <code>computeIfAbsent</code>, causing <code>NullPointerException</code> on every invalid regex pattern. Switched to <code>ConcurrentHashMapNullSafe</code>.</li> <li><strong>BUG FIX</strong>: <code>GraphComparator.processPrimitiveArray()</code> - <code>NullPointerException</code> when both source and target array elements were null (missing null guard before <code>.equals()</code> call).</li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/jdereg/java-util/commit/4a8923f92ad270525a19da7e6ac7b08de4133fc6"><code>4a8923f</code></a> Add bulk eviction for massive cache overshoots in ThreadedLRUCacheStrategy</li> <li><a href="https://github.com/jdereg/java-util/commit/7989efbf388a6fb2b1c3c38ebe15f65cebd8143a"><code>7989efb</code></a> updated version date</li> <li><a href="https://github.com/jdereg/java-util/commit/fbd391fcccf33a247a0b83f881463431d746bd49"><code>fbd391f</code></a> Update changelog for 4.93.0 release</li> <li><a href="https://github.com/jdereg/java-util/commit/673b179aca47b7767ffcd1c949006c67d6281d56"><code>673b179</code></a> Fix mutable self-conversions to clone instead of returning same instance</li> <li><a href="https://github.com/jdereg/java-util/commit/bad7931529ddef5847e7a00956261158120218e1"><code>bad7931</code></a> Add UUID ↔ ByteBuffer conversions</li> <li><a href="https://github.com/jdereg/java-util/commit/649821ef8cbefbf55940167c254a892992c62cc8"><code>649821e</code></a> Add UUID ↔ byte[] conversions and remove dead conversion methods</li> <li><a href="https://github.com/jdereg/java-util/commit/558b6ebff9b19b1f229655ca84277708cd184889"><code>558b6eb</code></a> Temporal hub-and-spoke refactoring + new MonthDay/YearMonth/OffsetTime conver...</li> <li><a href="https://github.com/jdereg/java-util/commit/5ed53de4b1725b4ae991f59b749d940fe82adaf8"><code>5ed53de</code></a> Remove ~131 dead conversion methods made redundant by surrogate/bridge system</li> <li><a href="https://github.com/jdereg/java-util/commit/5d78fad91be96a02f57045d81912d963298bebf9"><code>5d78fad</code></a> Avoid needless HashMap allocation in ConverterOptions default methods</li> <li><a href="https://github.com/jdereg/java-util/commit/c1b810ccf785ca233ffc10590e0466dc8fe0d8ae"><code>c1b810c</code></a> Fix InsetsConversions int overflow in toInteger(), toDimension(), toRectangle()</li> <li>Additional commits viewable in <a href="https://github.com/jdereg/java-util/compare/4.90.0...4.93.0">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
