[ 
https://issues.apache.org/jira/browse/IGNITE-26254?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Aleksey Plekhanov updated IGNITE-26254:
---------------------------------------
    Ignite Flags: Release Notes Required

> Fix CacheColumnDescriptor for QueryEntity with java.sql.Date
> ------------------------------------------------------------
>
>                 Key: IGNITE-26254
>                 URL: https://issues.apache.org/jira/browse/IGNITE-26254
>             Project: Ignite
>          Issue Type: Bug
>            Reporter: Maksim Davydov
>            Assignee: Maksim Davydov
>            Priority: Major
>              Labels: ise
>             Fix For: 2.18
>
>         Attachments: SqlDateCacheTest.java
>
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> When creating a cache with a `QueryEntity` that uses `java.sql.Date` as a 
> value field type, Ignite fails to start the cache due to a 
> `NullPointerException` inside schema management.
> This happens both with Calcite and H2 query engines.
> {code}
> [2025-08-20T18:47:57,531][WARN 
> ][exchange-worker-#57%cache.SqlDateCacheTest0%][GridQueryProcessor] Some 
> classes in query configuration cannot be written in binary format because 
> they either implement Externalizable interface or have writeObject/readObject 
> methods. Instances of these classes will be deserialized in order to build 
> indexes. Please ensure that all nodes have these classes in classpath. To 
> enable binary serialization either implement Binarylizable interface or set 
> explicit serializer using BinaryTypeConfiguration.setSerializer() method: 
> [class java.sql.Date]
> [2025-08-20T18:47:57,535][WARN 
> ][exchange-worker-#57%cache.SqlDateCacheTest0%][SchemaManager$CompoundSchemaChangeListener]
>  Failed to notify listener (will ignore): Cannot invoke 
> "org.apache.ignite.internal.processors.query.calcite.schema.CacheColumnDescriptor.fieldIndex()"
>  because the return value of "java.util.Map.get(Object)" is null
>  java.lang.NullPointerException: Cannot invoke 
> "org.apache.ignite.internal.processors.query.calcite.schema.CacheColumnDescriptor.fieldIndex()"
>  because the return value of "java.util.Map.get(Object)" is null
>       at 
> org.apache.ignite.internal.processors.query.calcite.schema.CacheTableDescriptorImpl.<init>(CacheTableDescriptorImpl.java:186)
>  ~[classes/:?]
> {code}
> The issue lies in `QueryUtils#buildProperty()`, where `KeyOrValProperty` is 
> instantiated without considering column aliases.
> Reproducer: [^SqlDateCacheTest.java] 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to