You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Андрей Григорьев <xt...@gmail.com> on 2018/12/10 14:13:04 UTC

Migrate from 2.6 to 2.7

Hello, when I tried to migrate to new version i had error. Optimistic
Serializable isn't supported?


```
Caused by: class
org.apache.ignite.internal.processors.query.IgniteSQLException: Only
pessimistic repeatable read transactions are supported at the moment.
at
org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:690)
at
org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:671)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.runQueryTwoStep(IgniteH2Indexing.java:1793)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunDistributedQuery(IgniteH2Indexing.java:2610)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunPrepared(IgniteH2Indexing.java:2315)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:2209)
at
org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2135)
at
org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2130)
at
org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
at
org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2707)
at
org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2144)
at
org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:685)
... 10 more
```
Enviroment: JDK 1.8, Apache Ignite 2.7 (clear install, persistence mode, 3
nodes).  Apache Ignite Client 2.7 from maven:

<ignite.version>2.7.0</ignite.version>

<dependency>
    <groupId>org.apache.ignite</groupId>
    <artifactId>ignite-core</artifactId>
    <version>${ignite.version}</version>
</dependency>
<dependency>
    <groupId>org.apache.ignite</groupId>
    <artifactId>ignite-indexing</artifactId>
    <version>${ignite.version}</version>
</dependency>

Cache configuration:

CacheConfiguration<K, V> cfg = new CacheConfiguration<>();
cfg.setBackups(backupsCount);
cfg.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL);

Transaction configuration:

TransactionConfiguration txCfg = new TransactionConfiguration();
txCfg.setDefaultTxConcurrency(TransactionConcurrency.OPTIMISTIC);
txCfg.setDefaultTxIsolation(TransactionIsolation.SERIALIZABLE);
cfg.setTransactionConfiguration(txCfg);

And second exception from nodes, when i try to read persisted value from
cache (set transaction mode to pessimistic repetable).

```
[15:33:46,990][SEVERE][query-#278][GridMapQueryExecutor] Failed to execute
local query.
class org.apache.ignite.IgniteCheckedException: Failed to execute SQL
query. Внутренняя ошибка: "class
org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
upper=RowSimple [vals=[null, null, null, null, null, null, null,
'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
General error: "class
org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
upper=RowSimple [vals=[null, null, null, null, null, null, null,
'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
SELECT
"HumanName".__Z0._KEY __C0_0,
"HumanName".__Z0._VAL __C0_1
FROM "HumanName".HUMANNAMEMODEL __Z0
WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1428)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQueryWithTimer(IgniteH2Indexing.java:1489)
at
org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest0(GridMapQueryExecutor.java:930)
at
org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest(GridMapQueryExecutor.java:705)
at
org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onMessage(GridMapQueryExecutor.java:240)
at
org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor$2.onMessage(GridMapQueryExecutor.java:200)
at
org.apache.ignite.internal.managers.communication.GridIoManager$ArrayListener.onMessage(GridIoManager.java:2349)
at
org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1569)
at
org.apache.ignite.internal.managers.communication.GridIoManager.processRegularMessage0(GridIoManager.java:1197)
at
org.apache.ignite.internal.managers.communication.GridIoManager.access$4200(GridIoManager.java:127)
at
org.apache.ignite.internal.managers.communication.GridIoManager$9.run(GridIoManager.java:1093)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.h2.jdbc.JdbcSQLException: Внутренняя ошибка: "class
org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
upper=RowSimple [vals=[null, null, null, null, null, null, null,
'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
General error: "class
org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
upper=RowSimple [vals=[null, null, null, null, null, null, null,
'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
SELECT
"HumanName".__Z0._KEY __C0_0,
"HumanName".__Z0._VAL __C0_1
FROM "HumanName".HUMANNAMEMODEL __Z0
WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
at org.h2.message.DbException.get(DbException.java:168)
at org.h2.message.DbException.convert(DbException.java:307)
at
org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:263)
at org.h2.index.BaseIndex.find(BaseIndex.java:130)
at org.h2.index.IndexCursor.find(IndexCursor.java:176)
at org.h2.table.TableFilter.next(TableFilter.java:471)
at
org.h2.command.dml.Select$LazyResultQueryFlat.fetchNextRow(Select.java:1452)
at org.h2.result.LazyResult.hasNext(LazyResult.java:79)
at org.h2.result.LazyResult.next(LazyResult.java:59)
at org.h2.command.dml.Select.queryFlat(Select.java:527)
at org.h2.command.dml.Select.queryWithoutCache(Select.java:633)
at org.h2.command.dml.Query.queryWithoutCacheLazyCheck(Query.java:114)
at org.h2.command.dml.Query.query(Query.java:352)
at org.h2.command.dml.Query.query(Query.java:333)
at org.h2.command.CommandContainer.query(CommandContainer.java:114)
at org.h2.command.Command.executeQuery(Command.java:202)
at
org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:114)
at
org.apache.ignite.internal.processors.query.h2.PreparedStatementExImpl.executeQuery(PreparedStatementExImpl.java:67)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1421)
... 13 more
Caused by: class
org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
upper=RowSimple [vals=[null, null, null, null, null, null, null,
'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1013)
at
org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:258)
... 29 more
Caused by: org.h2.message.DbException: Ошибка десериализации, причина:
"class org.apache.ignite.IgniteCheckedException: Not enough data to read
the value [position=1, requiredBytes=8, remainingBytes=6]"
Deserialization failed, cause: "class
org.apache.ignite.IgniteCheckedException: Not enough data to read the value
[position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
at org.h2.message.DbException.get(DbException.java:168)
at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:423)
at org.h2.value.Value.convertTo(Value.java:1006)
at org.h2.value.Value.convertTo(Value.java:617)
at org.h2.value.Value.convertTo(Value.java:592)
at org.h2.table.Table.compareTypeSafe(Table.java:1186)
at
org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex$1.compareValues(H2TreeIndex.java:181)
at
org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:92)
at
org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:90)
at
org.apache.ignite.internal.processors.query.h2.database.InlineIndexHelper.compare(InlineIndexHelper.java:381)
at
org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:306)
at
org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:55)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.compare(BPlusTree.java:5105)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findInsertionPoint(BPlusTree.java:5025)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$1300(BPlusTree.java:90)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run0(BPlusTree.java:291)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5615)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run(BPlusTree.java:271)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5600)
at
org.apache.ignite.internal.processors.cache.persistence.tree.util.PageHandler.readPage(PageHandler.java:159)
at
org.apache.ignite.internal.processors.cache.persistence.DataStructure.read(DataStructure.java:334)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findDown(BPlusTree.java:1309)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.doFind(BPlusTree.java:1276)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$8700(BPlusTree.java:90)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$AbstractForwardCursor.find(BPlusTree.java:5289)
at
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1005)
... 30 more
Caused by: org.h2.jdbc.JdbcSQLException: Ошибка десериализации, причина:
"class org.apache.ignite.IgniteCheckedException: Not enough data to read
the value [position=1, requiredBytes=8, remainingBytes=6]"
Deserialization failed, cause: "class
org.apache.ignite.IgniteCheckedException: Not enough data to read the value
[position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
... 56 more
Caused by: class org.apache.ignite.IgniteCheckedException: Not enough data
to read the value [position=1, requiredBytes=8, remainingBytes=6]
at
org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10146)
at
org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$15.deserialize(IgniteH2Indexing.java:3417)
at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:401)
... 54 more
Caused by: class org.apache.ignite.binary.BinaryObjectException: Not enough
data to read the value [position=1, requiredBytes=8, remainingBytes=6]
at
org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.ensureEnoughData(BinaryAbstractInputStream.java:305)
at
org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.readLong(BinaryAbstractInputStream.java:214)
at
org.apache.ignite.internal.binary.BinaryUtils.doReadUuid(BinaryUtils.java:1305)
at
org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize0(BinaryReaderExImpl.java:1821)
at
org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize(BinaryReaderExImpl.java:1716)
at
org.apache.ignite.internal.binary.GridBinaryMarshaller.deserialize(GridBinaryMarshaller.java:313)
at
org.apache.ignite.internal.binary.BinaryMarshaller.unmarshal0(BinaryMarshaller.java:102)
at
org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller.unmarshal(AbstractNodeNameAwareMarshaller.java:82)
at
org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10140)
... 56 more
```

Entity class:

public abstract class GenericChildModel<T extends Serializable, P
extends Serializable> implements Serializable {

    transient protected T id;
    protected transient AffinityKey<T> key;

    @QuerySqlField(notNull = true, orderedGroups =
{@QuerySqlField.Group(name = "parent_version_idx", order = 0)})
    protected P parentId;

    @QuerySqlField(notNull = true, orderedGroups =
{@QuerySqlField.Group(name = "parent_version_idx", order = 1,
descending = true)})
    protected Long version;

    transient protected P colocationId;

    public AffinityKey<T> key() {
        if (key == null)
            key = new AffinityKey<>(id, colocationId);
        return key;
    }

public class HumanNameModel extends GenericChildModel<UUID, UUID> {

    @QuerySqlField
    private Byte use;
    @QuerySqlField(notNull = true, orderedGroups =
{@QuerySqlField.Group(name = "fullname_idx", order = 0)})
    @NotNull
    @Name
    private String family;
    @QuerySqlField(orderedGroups = {@QuerySqlField.Group(name =
"fullname_idx", order = 1)})
    @Name
    private String firstName;
    @QuerySqlField(index = true, orderedGroups =
{@QuerySqlField.Group(name = "fullname_idx", order = 2)})
    @Name
    private String patronymic;

Re: Strange exception on 2.7

Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!

Can you post a small reproducer project so that I can look without
reimplementing it for the second time?

Regards,
-- 
Ilya Kasnacheev


пн, 10 дек. 2018 г. в 21:10, Andrey Davydov <an...@gmail.com>:

> I’ve got strange exception after update my project from 2.6 to 2.7. It
> happens when I run DELETE SQL query on empty cache. Smt like this "DELETE
> FROM
>
> EventNode WHERE processTimeStamp < ? ".
>
>
>
> Class definitions:
>
>
>
> public class EventNode {
>
>
>
>     @QuerySqlField(index = true)
>
>     private MlEvent event;
>
>
>
>     private UUID next;
>
>
>
>     private UUID nextTheSameModel;
>
>
>
>     private UUID nextTheSameRoot;
>
> …
>
>
>
> }
>
>
>
> public class MlEvent {
>
>
>
>     private UUID eventId;
>
>
>
>     @QuerySqlField(index = true)
>
>     private UUID rootEventId;
>
>
>
>     @QuerySqlField(index = true)
>
>     private String eventName;
>
>     @QuerySqlField(index = true)
>
>     private String modelName;
>
>     @QuerySqlField(index = true)
>
>     private String actor;
>
>
>
>     private LocalDateTime submitTimeStamp;
>
>     @QuerySqlField(index = true, descending = true)
>
>     private LocalDateTime processTimeStamp;
>
>
>
>     @QuerySqlField(index = true)
>
>     private EventProcessState state = EventProcessState.WAIT;
>
>
>
>     private Map<String, ValueNode> parameters;
>
> …
>
> }
>
>
>
> Cache definition:
>
>     <bean id="mlfw-cache-template" abstract="true"
> class="org.apache.ignite.configuration.CacheConfiguration">
>
>         <property name="atomicityMode" value="TRANSACTIONAL"/>
>
>         <property name="writeSynchronizationMode" value="FULL_SYNC"/>
>
>         <property name="rebalanceMode" value="ASYNC"/>
>
>         <property name="maxConcurrentAsyncOperations" value="4500"/>
>
>         <property name="cacheMode" value="PARTITIONED"/>
>
>         <property name="backups"
> value="${config.application.cache.backup}"/>
>
>         <property name="dataRegionName" value="mlfwPersistDataRegion"/>
>
>         <property name="storeKeepBinary" value="true"/>
>
>         <!-- Group the cache belongs to. -->
>
>         <property name="groupName" value="mlfwSystem"/>
>
>
>
>         <property name="affinity">
>
>             <bean
> class="org.apache.ignite.cache.affinity.rendezvous.RendezvousAffinityFunction">
>
>                 <property name="excludeNeighbors" value="true"/>
>
>                 <property name="partitions"
> value="${topology.parts.count}"/>
>
>             </bean>
>
>         </property>
>
>     </bean>
>
>
>
>                 <bean parent="mlfw-cache-template"
> class="org.apache.ignite.configuration.CacheConfiguration">
>
>                     <property name="name"
> value="${config.cache.event.storage}"/>
>
>                     <property name="indexedTypes">
>
>                         <list>
>
>                             <value>java.util.UUID</value>
>
>
> <value>ru.sibur.digital.mlfw.service.entity.EventNode</value>
>
>                         </list>
>
>                     </property>
>
>                 </bean>
>
>
>
> On 2.6 it was OK. More details and possible reproducer I can provide only
> tomorrow.
>
>
>
> Exception stacktrace:
>
>
>
> Caused by: javax.cache.CacheException: Failed to update meta data for
> type: java.time.Ser
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:697)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.iterativeClean(HistoryCleanService.java:100)
> ~[classes/:?]
>
>      at
> ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.clean(HistoryCleanService.java:124)
> ~[classes/:?]
>
>      ... 8 more
>
> Caused by: org.apache.ignite.binary.BinaryObjectException: Failed to
> update meta data for type: java.time.Ser
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.addMeta(CacheObjectBinaryProcessorImpl.java:477)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl$2.addMeta(CacheObjectBinaryProcessorImpl.java:186)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.registerUserClassDescriptor(BinaryContext.java:803)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.registerClassDescriptor(BinaryContext.java:762)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.descriptorForClass(BinaryContext.java:628)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:181)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:218)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:151)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.GridBinaryMarshaller.marshal(GridBinaryMarshaller.java:254)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.marshalToBinary(CacheObjectBinaryProcessorImpl.java:403)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.IgniteBinaryImpl.toBinary(IgniteBinaryImpl.java:69)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:759)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:744)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:672)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.iterativeClean(HistoryCleanService.java:100)
> ~[classes/:?]
>
>      at
> ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.clean(HistoryCleanService.java:124)
> ~[classes/:?]
>
>      ... 8 more
>
> Caused by: org.apache.ignite.internal.IgniteInterruptedCheckedException:
> Got interrupted while waiting for future to complete.
>
>      at
> org.apache.ignite.internal.util.future.GridFutureAdapter.get0(GridFutureAdapter.java:186)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.util.future.GridFutureAdapter.get(GridFutureAdapter.java:141)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.addMeta(CacheObjectBinaryProcessorImpl.java:469)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl$2.addMeta(CacheObjectBinaryProcessorImpl.java:186)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.registerUserClassDescriptor(BinaryContext.java:803)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.registerClassDescriptor(BinaryContext.java:762)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryContext.descriptorForClass(BinaryContext.java:628)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:181)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:218)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:151)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.binary.GridBinaryMarshaller.marshal(GridBinaryMarshaller.java:254)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.marshalToBinary(CacheObjectBinaryProcessorImpl.java:403)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.binary.IgniteBinaryImpl.toBinary(IgniteBinaryImpl.java:69)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:759)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:744)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:672)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>      at
> org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388)
> ~[ignite-core-2.7.0.jar:2.7.0]
>
>
>

Strange exception on 2.7

Posted by Andrey Davydov <an...@gmail.com>.
I’ve got strange exception after update my project from 2.6 to 2.7. It happens when I run DELETE SQL query on empty cache. Smt like this "DELETE FROM 
EventNode WHERE processTimeStamp < ? ".   

Class definitions:

public class EventNode {

    @QuerySqlField(index = true)
    private MlEvent event;

    private UUID next;

    private UUID nextTheSameModel;

    private UUID nextTheSameRoot;
…

}

public class MlEvent {

    private UUID eventId;

    @QuerySqlField(index = true)
    private UUID rootEventId;

    @QuerySqlField(index = true)
    private String eventName;
    @QuerySqlField(index = true)
    private String modelName;
    @QuerySqlField(index = true)
    private String actor;

    private LocalDateTime submitTimeStamp;
    @QuerySqlField(index = true, descending = true)
    private LocalDateTime processTimeStamp;

    @QuerySqlField(index = true)
    private EventProcessState state = EventProcessState.WAIT;

    private Map<String, ValueNode> parameters;
…
}

Cache definition:
    <bean id="mlfw-cache-template" abstract="true" class="org.apache.ignite.configuration.CacheConfiguration">
        <property name="atomicityMode" value="TRANSACTIONAL"/>
        <property name="writeSynchronizationMode" value="FULL_SYNC"/>
        <property name="rebalanceMode" value="ASYNC"/>
        <property name="maxConcurrentAsyncOperations" value="4500"/>
        <property name="cacheMode" value="PARTITIONED"/>
        <property name="backups" value="${config.application.cache.backup}"/>
        <property name="dataRegionName" value="mlfwPersistDataRegion"/>
        <property name="storeKeepBinary" value="true"/>        
        <!-- Group the cache belongs to. -->
        <property name="groupName" value="mlfwSystem"/> 
        
        <property name="affinity">
            <bean class="org.apache.ignite.cache.affinity.rendezvous.RendezvousAffinityFunction">
                <property name="excludeNeighbors" value="true"/>
                <property name="partitions" value="${topology.parts.count}"/>
            </bean>
        </property>
    </bean>

                <bean parent="mlfw-cache-template" class="org.apache.ignite.configuration.CacheConfiguration">
                    <property name="name" value="${config.cache.event.storage}"/>                  
                    <property name="indexedTypes">
                        <list>
                            <value>java.util.UUID</value>
                            <value>ru.sibur.digital.mlfw.service.entity.EventNode</value>
                        </list>
                    </property>                    
                </bean>

 On 2.6 it was OK. More details and possible reproducer I can provide only tomorrow. 

Exception stacktrace:

Caused by: javax.cache.CacheException: Failed to update meta data for type: java.time.Ser
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:697) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388) ~[ignite-core-2.7.0.jar:2.7.0]
	at ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.iterativeClean(HistoryCleanService.java:100) ~[classes/:?]
	at ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.clean(HistoryCleanService.java:124) ~[classes/:?]
	... 8 more
Caused by: org.apache.ignite.binary.BinaryObjectException: Failed to update meta data for type: java.time.Ser
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.addMeta(CacheObjectBinaryProcessorImpl.java:477) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl$2.addMeta(CacheObjectBinaryProcessorImpl.java:186) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.registerUserClassDescriptor(BinaryContext.java:803) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.registerClassDescriptor(BinaryContext.java:762) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.descriptorForClass(BinaryContext.java:628) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:181) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:218) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:151) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.GridBinaryMarshaller.marshal(GridBinaryMarshaller.java:254) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.marshalToBinary(CacheObjectBinaryProcessorImpl.java:403) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.IgniteBinaryImpl.toBinary(IgniteBinaryImpl.java:69) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:759) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:744) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:672) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388) ~[ignite-core-2.7.0.jar:2.7.0]
	at ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.iterativeClean(HistoryCleanService.java:100) ~[classes/:?]
	at ru.sibur.digital.mlfw.service.business.clean.HistoryCleanService.clean(HistoryCleanService.java:124) ~[classes/:?]
	... 8 more
Caused by: org.apache.ignite.internal.IgniteInterruptedCheckedException: Got interrupted while waiting for future to complete.
	at org.apache.ignite.internal.util.future.GridFutureAdapter.get0(GridFutureAdapter.java:186) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.util.future.GridFutureAdapter.get(GridFutureAdapter.java:141) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.addMeta(CacheObjectBinaryProcessorImpl.java:469) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl$2.addMeta(CacheObjectBinaryProcessorImpl.java:186) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.registerUserClassDescriptor(BinaryContext.java:803) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.registerClassDescriptor(BinaryContext.java:762) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryContext.descriptorForClass(BinaryContext.java:628) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:181) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:218) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:164) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:151) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.binary.GridBinaryMarshaller.marshal(GridBinaryMarshaller.java:254) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.CacheObjectBinaryProcessorImpl.marshalToBinary(CacheObjectBinaryProcessorImpl.java:403) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.binary.IgniteBinaryImpl.toBinary(IgniteBinaryImpl.java:69) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:759) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.convertToBinary(IgniteCacheProxyImpl.java:744) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:672) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:636) ~[ignite-core-2.7.0.jar:2.7.0]
	at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:388) ~[ignite-core-2.7.0.jar:2.7.0]


Re: Migrate from 2.6 to 2.7

Posted by xtron <xt...@gmail.com>.
Thanks. 
This helped, but it requires deactivate all cluster and delete "work" dir,
else i had error like "different field type parentId: field1: Object,
field2: uuid". Just restart cluster didn't help. I found one way: recreate
uuid field via sql (sqline) without data lost (create other column, move
data etc.).  But you are right this is bug. 





--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Migrate from 2.6 to 2.7

Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!

Looks like you can't have a generic field in your class and then put UUID
to it.
UUID is a primitive type as far as Ignite is concerned, which will take 6
bytes, but a smallest Object (which is the fallback type for generic field)
is 8 bytes, hence cryptic errors.
If you change P to UUID in your GenericChildModel it will fix your case.

I still think this is a bug. I can see that there is
https://issues.apache.org/jira/browse/IGNITE-10635
I hope it gets attention.

Regards,
-- 
Ilya Kasnacheev


вт, 11 дек. 2018 г. в 19:29, xtron <xt...@gmail.com>:

> Thanks. I use sql in transaction context, but in 2.6 I havent problem this.
> Now I changed mode to TRANSACTIONAL_SNAPSHOT and Transaction to pessimistic
> repeatable and problem was gone.
>
> About first problem.. I create small project to reproduce it.
>
> https://www.dropbox.com/s/tvxfi2pnmlouton/testproj.zip
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Migrate from 2.6 to 2.7

Posted by xtron <xt...@gmail.com>.
Thanks. I use sql in transaction context, but in 2.6 I havent problem this.
Now I changed mode to TRANSACTIONAL_SNAPSHOT and Transaction to pessimistic
repeatable and problem was gone.

About first problem.. I create small project to reproduce it. 

https://www.dropbox.com/s/tvxfi2pnmlouton/testproj.zip



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Migrate from 2.6 to 2.7

Posted by whiteman <wh...@centrum.cz>.
Hello!

thanks for prompt resolution, will try once 2.8 is out.

Best!



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Migrate from 2.6 to 2.7

Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!

Cross-posting: I have filed a blocker ticket about it.
https://issues.apache.org/jira/browse/IGNITE-10884

Regards,
-- 
Ilya Kasnacheev


чт, 3 янв. 2019 г. в 03:24, Denis Magda <dm...@apache.org>:

> Are you using JDBC/ODBC drivers? Just want to know why it's hard to
> execute SQL queries outside of transactions.
>
> Can you switch to pessimistic transactions instead?
>
> --
> Denis
>
> On Wed, Jan 2, 2019 at 7:24 AM whiteman <wh...@centrum.cz> wrote:
>
>> Hi guys,
>>
>> As far as I am concerned this is a breaking behaviour. In Apache Ignite v
>> 2.5 it was possible to have the SQL query inside the optimistic
>> serializable
>> transaction. Point here is that SQL query might not be part of the
>> transaction (no guarantees) but was at least performed. In 2.7 this code
>> won't work at all. The advice to move all SQL queries outside the
>> transactions is in real world not possible. It would greatly increased
>> complexity of the codebase. My question is if there is a switch for
>> enabling
>> pre 2.7 behaviour.
>>
>> THanks,
>> Cheers,
>> D.
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>>
>

Re: Migrate from 2.6 to 2.7

Posted by whiteman <wh...@centrum.cz>.
Hi,

No, I am not using JDBC driver.
Re switching to the pessimistic transaction, tried but is not working
correctly in some cases, for instance, .clear() on caches and some more...
which is fine as Igniters state it's not production ready yet. Obviously
happy guys you are adding new transaction semantics :)



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Migrate from 2.6 to 2.7

Posted by Denis Magda <dm...@apache.org>.
Are you using JDBC/ODBC drivers? Just want to know why it's hard to execute
SQL queries outside of transactions.

Can you switch to pessimistic transactions instead?

--
Denis

On Wed, Jan 2, 2019 at 7:24 AM whiteman <wh...@centrum.cz> wrote:

> Hi guys,
>
> As far as I am concerned this is a breaking behaviour. In Apache Ignite v
> 2.5 it was possible to have the SQL query inside the optimistic
> serializable
> transaction. Point here is that SQL query might not be part of the
> transaction (no guarantees) but was at least performed. In 2.7 this code
> won't work at all. The advice to move all SQL queries outside the
> transactions is in real world not possible. It would greatly increased
> complexity of the codebase. My question is if there is a switch for
> enabling
> pre 2.7 behaviour.
>
> THanks,
> Cheers,
> D.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Migrate from 2.6 to 2.7

Posted by whiteman <wh...@centrum.cz>.
Hi guys,

As far as I am concerned this is a breaking behaviour. In Apache Ignite v
2.5 it was possible to have the SQL query inside the optimistic serializable
transaction. Point here is that SQL query might not be part of the
transaction (no guarantees) but was at least performed. In 2.7 this code
won't work at all. The advice to move all SQL queries outside the
transactions is in real world not possible. It would greatly increased
complexity of the codebase. My question is if there is a switch for enabling
pre 2.7 behaviour. 

THanks,
Cheers,
D.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Migrate from 2.6 to 2.7

Posted by Andrey Mashenkov <an...@gmail.com>.
Hi Andrey,

It looks like you try to run "Select" sql query inside explicit transaction.
Please, let us know if it is not true.

This was workable in 2.7 as SQL had no transactional support and query just
ignored transactional context (however "Select for Update" wasn't).
For now, SQL Select query supports transactions for TRANSACTIONAL_SNAPSHOT
cache mode and tries to validate transaction context that causes exception
you have faced.
So, you have to use TRANSACTIONAL_SNAPSHOT atomicity mode as Ivan suggested
or move Select query to outside of transaction.


On Tue, Dec 11, 2018 at 5:53 PM Павлухин Иван <vo...@gmail.com> wrote:

> Hi Andrey,
>
> It looks like your persisted data was read incorrectly by upgraded
> Ignite. It would be great if you provide runnable reproducer.
>
> Regarding Optimistic Serializable transactions. They are still
> supported by caches with TRANSACTIONAL atomicity mode. In your error
> it looks like that your caches are treated as TRANSACTIONAL_SNAPSHOT
> atomicity mode. You can read about that (experimental) mode in
> documentation [1]. Briefly, this mode allows SQL transactions and
> supports only PESSIMISTIC REPEATABLE_READ transaction configuration.
>
> [1]
> https://apacheignite-sql.readme.io/v2.7/docs/multiversion-concurrency-control
> пн, 10 дек. 2018 г. в 17:13, Андрей Григорьев <xt...@gmail.com>:
> >
> > Hello, when I tried to migrate to new version i had error. Optimistic
> Serializable isn't supported?
> >
> >
> > ```
> > Caused by: class
> org.apache.ignite.internal.processors.query.IgniteSQLException: Only
> pessimistic repeatable read transactions are supported at the moment.
> > at
> org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:690)
> > at
> org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:671)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.runQueryTwoStep(IgniteH2Indexing.java:1793)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunDistributedQuery(IgniteH2Indexing.java:2610)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunPrepared(IgniteH2Indexing.java:2315)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:2209)
> > at
> org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2135)
> > at
> org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2130)
> > at
> org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
> > at
> org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2707)
> > at
> org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2144)
> > at
> org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:685)
> > ... 10 more
> > ```
> > Enviroment: JDK 1.8, Apache Ignite 2.7 (clear install, persistence mode,
> 3 nodes).  Apache Ignite Client 2.7 from maven:
> >
> > <ignite.version>2.7.0</ignite.version>
> >
> > <dependency>
> >     <groupId>org.apache.ignite</groupId>
> >     <artifactId>ignite-core</artifactId>
> >     <version>${ignite.version}</version>
> > </dependency>
> > <dependency>
> >     <groupId>org.apache.ignite</groupId>
> >     <artifactId>ignite-indexing</artifactId>
> >     <version>${ignite.version}</version>
> > </dependency>
> >
> > Cache configuration:
> >
> > CacheConfiguration<K, V> cfg = new CacheConfiguration<>();
> > cfg.setBackups(backupsCount);
> > cfg.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL);
> >
> > Transaction configuration:
> >
> > TransactionConfiguration txCfg = new TransactionConfiguration();
> > txCfg.setDefaultTxConcurrency(TransactionConcurrency.OPTIMISTIC);
> > txCfg.setDefaultTxIsolation(TransactionIsolation.SERIALIZABLE);
> > cfg.setTransactionConfiguration(txCfg);
> >
> > And second exception from nodes, when i try to read persisted value from
> cache (set transaction mode to pessimistic repetable).
> >
> > ```
> > [15:33:46,990][SEVERE][query-#278][GridMapQueryExecutor] Failed to
> execute local query.
> > class org.apache.ignite.IgniteCheckedException: Failed to execute SQL
> query. Внутренняя ошибка: "class
> org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
> Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
> null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
> upper=RowSimple [vals=[null, null, null, null, null, null, null,
> 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
> > General error: "class
> org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
> Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
> null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
> upper=RowSimple [vals=[null, null, null, null, null, null, null,
> 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
> > SELECT
> > "HumanName".__Z0._KEY __C0_0,
> > "HumanName".__Z0._VAL __C0_1
> > FROM "HumanName".HUMANNAMEMODEL __Z0
> > WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1428)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQueryWithTimer(IgniteH2Indexing.java:1489)
> > at
> org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest0(GridMapQueryExecutor.java:930)
> > at
> org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest(GridMapQueryExecutor.java:705)
> > at
> org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onMessage(GridMapQueryExecutor.java:240)
> > at
> org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor$2.onMessage(GridMapQueryExecutor.java:200)
> > at
> org.apache.ignite.internal.managers.communication.GridIoManager$ArrayListener.onMessage(GridIoManager.java:2349)
> > at
> org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1569)
> > at
> org.apache.ignite.internal.managers.communication.GridIoManager.processRegularMessage0(GridIoManager.java:1197)
> > at
> org.apache.ignite.internal.managers.communication.GridIoManager.access$4200(GridIoManager.java:127)
> > at
> org.apache.ignite.internal.managers.communication.GridIoManager$9.run(GridIoManager.java:1093)
> > at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> > at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> > at java.lang.Thread.run(Thread.java:748)
> > Caused by: org.h2.jdbc.JdbcSQLException: Внутренняя ошибка: "class
> org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
> Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
> null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
> upper=RowSimple [vals=[null, null, null, null, null, null, null,
> 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
> > General error: "class
> org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
> Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
> null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
> upper=RowSimple [vals=[null, null, null, null, null, null, null,
> 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
> > SELECT
> > "HumanName".__Z0._KEY __C0_0,
> > "HumanName".__Z0._VAL __C0_1
> > FROM "HumanName".HUMANNAMEMODEL __Z0
> > WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
> > at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
> > at org.h2.message.DbException.get(DbException.java:168)
> > at org.h2.message.DbException.convert(DbException.java:307)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:263)
> > at org.h2.index.BaseIndex.find(BaseIndex.java:130)
> > at org.h2.index.IndexCursor.find(IndexCursor.java:176)
> > at org.h2.table.TableFilter.next(TableFilter.java:471)
> > at
> org.h2.command.dml.Select$LazyResultQueryFlat.fetchNextRow(Select.java:1452)
> > at org.h2.result.LazyResult.hasNext(LazyResult.java:79)
> > at org.h2.result.LazyResult.next(LazyResult.java:59)
> > at org.h2.command.dml.Select.queryFlat(Select.java:527)
> > at org.h2.command.dml.Select.queryWithoutCache(Select.java:633)
> > at org.h2.command.dml.Query.queryWithoutCacheLazyCheck(Query.java:114)
> > at org.h2.command.dml.Query.query(Query.java:352)
> > at org.h2.command.dml.Query.query(Query.java:333)
> > at org.h2.command.CommandContainer.query(CommandContainer.java:114)
> > at org.h2.command.Command.executeQuery(Command.java:202)
> > at
> org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:114)
> > at
> org.apache.ignite.internal.processors.query.h2.PreparedStatementExImpl.executeQuery(PreparedStatementExImpl.java:67)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1421)
> > ... 13 more
> > Caused by: class
> org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException:
> Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null,
> null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]],
> upper=RowSimple [vals=[null, null, null, null, null, null, null,
> 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1013)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:258)
> > ... 29 more
> > Caused by: org.h2.message.DbException: Ошибка десериализации, причина:
> "class org.apache.ignite.IgniteCheckedException: Not enough data to read
> the value [position=1, requiredBytes=8, remainingBytes=6]"
> > Deserialization failed, cause: "class
> org.apache.ignite.IgniteCheckedException: Not enough data to read the value
> [position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
> > at org.h2.message.DbException.get(DbException.java:168)
> > at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:423)
> > at org.h2.value.Value.convertTo(Value.java:1006)
> > at org.h2.value.Value.convertTo(Value.java:617)
> > at org.h2.value.Value.convertTo(Value.java:592)
> > at org.h2.table.Table.compareTypeSafe(Table.java:1186)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex$1.compareValues(H2TreeIndex.java:181)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:92)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:90)
> > at
> org.apache.ignite.internal.processors.query.h2.database.InlineIndexHelper.compare(InlineIndexHelper.java:381)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:306)
> > at
> org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:55)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.compare(BPlusTree.java:5105)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findInsertionPoint(BPlusTree.java:5025)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$1300(BPlusTree.java:90)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run0(BPlusTree.java:291)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5615)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run(BPlusTree.java:271)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5600)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.util.PageHandler.readPage(PageHandler.java:159)
> > at
> org.apache.ignite.internal.processors.cache.persistence.DataStructure.read(DataStructure.java:334)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findDown(BPlusTree.java:1309)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.doFind(BPlusTree.java:1276)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$8700(BPlusTree.java:90)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$AbstractForwardCursor.find(BPlusTree.java:5289)
> > at
> org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1005)
> > ... 30 more
> > Caused by: org.h2.jdbc.JdbcSQLException: Ошибка десериализации, причина:
> "class org.apache.ignite.IgniteCheckedException: Not enough data to read
> the value [position=1, requiredBytes=8, remainingBytes=6]"
> > Deserialization failed, cause: "class
> org.apache.ignite.IgniteCheckedException: Not enough data to read the value
> [position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
> > at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
> > ... 56 more
> > Caused by: class org.apache.ignite.IgniteCheckedException: Not enough
> data to read the value [position=1, requiredBytes=8, remainingBytes=6]
> > at
> org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10146)
> > at
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$15.deserialize(IgniteH2Indexing.java:3417)
> > at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:401)
> > ... 54 more
> > Caused by: class org.apache.ignite.binary.BinaryObjectException: Not
> enough data to read the value [position=1, requiredBytes=8,
> remainingBytes=6]
> > at
> org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.ensureEnoughData(BinaryAbstractInputStream.java:305)
> > at
> org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.readLong(BinaryAbstractInputStream.java:214)
> > at
> org.apache.ignite.internal.binary.BinaryUtils.doReadUuid(BinaryUtils.java:1305)
> > at
> org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize0(BinaryReaderExImpl.java:1821)
> > at
> org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize(BinaryReaderExImpl.java:1716)
> > at
> org.apache.ignite.internal.binary.GridBinaryMarshaller.deserialize(GridBinaryMarshaller.java:313)
> > at
> org.apache.ignite.internal.binary.BinaryMarshaller.unmarshal0(BinaryMarshaller.java:102)
> > at
> org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller.unmarshal(AbstractNodeNameAwareMarshaller.java:82)
> > at
> org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10140)
> > ... 56 more
> > ```
> >
> > Entity class:
> >
> > public abstract class GenericChildModel<T extends Serializable, P
> extends Serializable> implements Serializable {
> >
> >     transient protected T id;
> >     protected transient AffinityKey<T> key;
> >
> >     @QuerySqlField(notNull = true, orderedGroups =
> {@QuerySqlField.Group(name = "parent_version_idx", order = 0)})
> >     protected P parentId;
> >
> >     @QuerySqlField(notNull = true, orderedGroups =
> {@QuerySqlField.Group(name = "parent_version_idx", order = 1, descending =
> true)})
> >     protected Long version;
> >
> >     transient protected P colocationId;
> >
> >     public AffinityKey<T> key() {
> >         if (key == null)
> >             key = new AffinityKey<>(id, colocationId);
> >         return key;
> >     }
> >
> > public class HumanNameModel extends GenericChildModel<UUID, UUID> {
> >
> >     @QuerySqlField
> >     private Byte use;
> >     @QuerySqlField(notNull = true, orderedGroups =
> {@QuerySqlField.Group(name = "fullname_idx", order = 0)})
> >     @NotNull
> >     @Name
> >     private String family;
> >     @QuerySqlField(orderedGroups = {@QuerySqlField.Group(name =
> "fullname_idx", order = 1)})
> >     @Name
> >     private String firstName;
> >     @QuerySqlField(index = true, orderedGroups =
> {@QuerySqlField.Group(name = "fullname_idx", order = 2)})
> >     @Name
> >     private String patronymic;
>
>
>
> --
> Best regards,
> Ivan Pavlukhin
>


-- 
Best regards,
Andrey V. Mashenkov

Re: Migrate from 2.6 to 2.7

Posted by Павлухин Иван <vo...@gmail.com>.
Hi Andrey,

It looks like your persisted data was read incorrectly by upgraded
Ignite. It would be great if you provide runnable reproducer.

Regarding Optimistic Serializable transactions. They are still
supported by caches with TRANSACTIONAL atomicity mode. In your error
it looks like that your caches are treated as TRANSACTIONAL_SNAPSHOT
atomicity mode. You can read about that (experimental) mode in
documentation [1]. Briefly, this mode allows SQL transactions and
supports only PESSIMISTIC REPEATABLE_READ transaction configuration.

[1] https://apacheignite-sql.readme.io/v2.7/docs/multiversion-concurrency-control
пн, 10 дек. 2018 г. в 17:13, Андрей Григорьев <xt...@gmail.com>:
>
> Hello, when I tried to migrate to new version i had error. Optimistic Serializable isn't supported?
>
>
> ```
> Caused by: class org.apache.ignite.internal.processors.query.IgniteSQLException: Only pessimistic repeatable read transactions are supported at the moment.
> at org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:690)
> at org.apache.ignite.internal.processors.cache.mvcc.MvccUtils.tx(MvccUtils.java:671)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.runQueryTwoStep(IgniteH2Indexing.java:1793)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunDistributedQuery(IgniteH2Indexing.java:2610)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.doRunPrepared(IgniteH2Indexing.java:2315)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.querySqlFields(IgniteH2Indexing.java:2209)
> at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2135)
> at org.apache.ignite.internal.processors.query.GridQueryProcessor$4.applyx(GridQueryProcessor.java:2130)
> at org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
> at org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2707)
> at org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:2144)
> at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:685)
> ... 10 more
> ```
> Enviroment: JDK 1.8, Apache Ignite 2.7 (clear install, persistence mode, 3 nodes).  Apache Ignite Client 2.7 from maven:
>
> <ignite.version>2.7.0</ignite.version>
>
> <dependency>
>     <groupId>org.apache.ignite</groupId>
>     <artifactId>ignite-core</artifactId>
>     <version>${ignite.version}</version>
> </dependency>
> <dependency>
>     <groupId>org.apache.ignite</groupId>
>     <artifactId>ignite-indexing</artifactId>
>     <version>${ignite.version}</version>
> </dependency>
>
> Cache configuration:
>
> CacheConfiguration<K, V> cfg = new CacheConfiguration<>();
> cfg.setBackups(backupsCount);
> cfg.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL);
>
> Transaction configuration:
>
> TransactionConfiguration txCfg = new TransactionConfiguration();
> txCfg.setDefaultTxConcurrency(TransactionConcurrency.OPTIMISTIC);
> txCfg.setDefaultTxIsolation(TransactionIsolation.SERIALIZABLE);
> cfg.setTransactionConfiguration(txCfg);
>
> And second exception from nodes, when i try to read persisted value from cache (set transaction mode to pessimistic repetable).
>
> ```
> [15:33:46,990][SEVERE][query-#278][GridMapQueryExecutor] Failed to execute local query.
> class org.apache.ignite.IgniteCheckedException: Failed to execute SQL query. Внутренняя ошибка: "class org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException: Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]], upper=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
> General error: "class org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException: Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]], upper=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
> SELECT
> "HumanName".__Z0._KEY __C0_0,
> "HumanName".__Z0._VAL __C0_1
> FROM "HumanName".HUMANNAMEMODEL __Z0
> WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1428)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQueryWithTimer(IgniteH2Indexing.java:1489)
> at org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest0(GridMapQueryExecutor.java:930)
> at org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onQueryRequest(GridMapQueryExecutor.java:705)
> at org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor.onMessage(GridMapQueryExecutor.java:240)
> at org.apache.ignite.internal.processors.query.h2.twostep.GridMapQueryExecutor$2.onMessage(GridMapQueryExecutor.java:200)
> at org.apache.ignite.internal.managers.communication.GridIoManager$ArrayListener.onMessage(GridIoManager.java:2349)
> at org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1569)
> at org.apache.ignite.internal.managers.communication.GridIoManager.processRegularMessage0(GridIoManager.java:1197)
> at org.apache.ignite.internal.managers.communication.GridIoManager.access$4200(GridIoManager.java:127)
> at org.apache.ignite.internal.managers.communication.GridIoManager$9.run(GridIoManager.java:1093)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> at java.lang.Thread.run(Thread.java:748)
> Caused by: org.h2.jdbc.JdbcSQLException: Внутренняя ошибка: "class org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException: Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]], upper=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"
> General error: "class org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException: Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]], upper=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]"; SQL statement:
> SELECT
> "HumanName".__Z0._KEY __C0_0,
> "HumanName".__Z0._VAL __C0_1
> FROM "HumanName".HUMANNAMEMODEL __Z0
> WHERE (__Z0.PARENTID = ?1) AND (__Z0.VERSION = ?2) [50000-197]
> at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
> at org.h2.message.DbException.get(DbException.java:168)
> at org.h2.message.DbException.convert(DbException.java:307)
> at org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:263)
> at org.h2.index.BaseIndex.find(BaseIndex.java:130)
> at org.h2.index.IndexCursor.find(IndexCursor.java:176)
> at org.h2.table.TableFilter.next(TableFilter.java:471)
> at org.h2.command.dml.Select$LazyResultQueryFlat.fetchNextRow(Select.java:1452)
> at org.h2.result.LazyResult.hasNext(LazyResult.java:79)
> at org.h2.result.LazyResult.next(LazyResult.java:59)
> at org.h2.command.dml.Select.queryFlat(Select.java:527)
> at org.h2.command.dml.Select.queryWithoutCache(Select.java:633)
> at org.h2.command.dml.Query.queryWithoutCacheLazyCheck(Query.java:114)
> at org.h2.command.dml.Query.query(Query.java:352)
> at org.h2.command.dml.Query.query(Query.java:333)
> at org.h2.command.CommandContainer.query(CommandContainer.java:114)
> at org.h2.command.Command.executeQuery(Command.java:202)
> at org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:114)
> at org.apache.ignite.internal.processors.query.h2.PreparedStatementExImpl.executeQuery(PreparedStatementExImpl.java:67)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.executeSqlQuery(IgniteH2Indexing.java:1421)
> ... 13 more
> Caused by: class org.apache.ignite.internal.processors.cache.persistence.tree.CorruptedTreeException: Runtime failure on bounds: [lower=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]], upper=RowSimple [vals=[null, null, null, null, null, null, null, 'e3f070fa-7888-4fbb-baac-a02d5338e217', 1]]]
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1013)
> at org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex.find(H2TreeIndex.java:258)
> ... 29 more
> Caused by: org.h2.message.DbException: Ошибка десериализации, причина: "class org.apache.ignite.IgniteCheckedException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]"
> Deserialization failed, cause: "class org.apache.ignite.IgniteCheckedException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
> at org.h2.message.DbException.get(DbException.java:168)
> at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:423)
> at org.h2.value.Value.convertTo(Value.java:1006)
> at org.h2.value.Value.convertTo(Value.java:617)
> at org.h2.value.Value.convertTo(Value.java:592)
> at org.h2.table.Table.compareTypeSafe(Table.java:1186)
> at org.apache.ignite.internal.processors.query.h2.database.H2TreeIndex$1.compareValues(H2TreeIndex.java:181)
> at org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:92)
> at org.apache.ignite.internal.processors.query.h2.database.H2Tree$1.compare(H2Tree.java:90)
> at org.apache.ignite.internal.processors.query.h2.database.InlineIndexHelper.compare(InlineIndexHelper.java:381)
> at org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:306)
> at org.apache.ignite.internal.processors.query.h2.database.H2Tree.compare(H2Tree.java:55)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.compare(BPlusTree.java:5105)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findInsertionPoint(BPlusTree.java:5025)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$1300(BPlusTree.java:90)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run0(BPlusTree.java:291)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5615)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$Search.run(BPlusTree.java:271)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$GetPageHandler.run(BPlusTree.java:5600)
> at org.apache.ignite.internal.processors.cache.persistence.tree.util.PageHandler.readPage(PageHandler.java:159)
> at org.apache.ignite.internal.processors.cache.persistence.DataStructure.read(DataStructure.java:334)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.findDown(BPlusTree.java:1309)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.doFind(BPlusTree.java:1276)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.access$8700(BPlusTree.java:90)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree$AbstractForwardCursor.find(BPlusTree.java:5289)
> at org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.find(BPlusTree.java:1005)
> ... 30 more
> Caused by: org.h2.jdbc.JdbcSQLException: Ошибка десериализации, причина: "class org.apache.ignite.IgniteCheckedException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]"
> Deserialization failed, cause: "class org.apache.ignite.IgniteCheckedException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]" [90027-197]
> at org.h2.message.DbException.getJdbcSQLException(DbException.java:357)
> ... 56 more
> Caused by: class org.apache.ignite.IgniteCheckedException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]
> at org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10146)
> at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing$15.deserialize(IgniteH2Indexing.java:3417)
> at org.h2.util.JdbcUtils.deserialize(JdbcUtils.java:401)
> ... 54 more
> Caused by: class org.apache.ignite.binary.BinaryObjectException: Not enough data to read the value [position=1, requiredBytes=8, remainingBytes=6]
> at org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.ensureEnoughData(BinaryAbstractInputStream.java:305)
> at org.apache.ignite.internal.binary.streams.BinaryAbstractInputStream.readLong(BinaryAbstractInputStream.java:214)
> at org.apache.ignite.internal.binary.BinaryUtils.doReadUuid(BinaryUtils.java:1305)
> at org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize0(BinaryReaderExImpl.java:1821)
> at org.apache.ignite.internal.binary.BinaryReaderExImpl.deserialize(BinaryReaderExImpl.java:1716)
> at org.apache.ignite.internal.binary.GridBinaryMarshaller.deserialize(GridBinaryMarshaller.java:313)
> at org.apache.ignite.internal.binary.BinaryMarshaller.unmarshal0(BinaryMarshaller.java:102)
> at org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller.unmarshal(AbstractNodeNameAwareMarshaller.java:82)
> at org.apache.ignite.internal.util.IgniteUtils.unmarshal(IgniteUtils.java:10140)
> ... 56 more
> ```
>
> Entity class:
>
> public abstract class GenericChildModel<T extends Serializable, P extends Serializable> implements Serializable {
>
>     transient protected T id;
>     protected transient AffinityKey<T> key;
>
>     @QuerySqlField(notNull = true, orderedGroups = {@QuerySqlField.Group(name = "parent_version_idx", order = 0)})
>     protected P parentId;
>
>     @QuerySqlField(notNull = true, orderedGroups = {@QuerySqlField.Group(name = "parent_version_idx", order = 1, descending = true)})
>     protected Long version;
>
>     transient protected P colocationId;
>
>     public AffinityKey<T> key() {
>         if (key == null)
>             key = new AffinityKey<>(id, colocationId);
>         return key;
>     }
>
> public class HumanNameModel extends GenericChildModel<UUID, UUID> {
>
>     @QuerySqlField
>     private Byte use;
>     @QuerySqlField(notNull = true, orderedGroups = {@QuerySqlField.Group(name = "fullname_idx", order = 0)})
>     @NotNull
>     @Name
>     private String family;
>     @QuerySqlField(orderedGroups = {@QuerySqlField.Group(name = "fullname_idx", order = 1)})
>     @Name
>     private String firstName;
>     @QuerySqlField(index = true, orderedGroups = {@QuerySqlField.Group(name = "fullname_idx", order = 2)})
>     @Name
>     private String patronymic;



-- 
Best regards,
Ivan Pavlukhin