ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vladimir Ozerov <voze...@gridgain.com>
Subject Re: Upgrade from 2.1.0 to 2.4.0 resulting in error within transaction block
Date Thu, 05 Apr 2018 12:29:36 GMT
I've just fixed possible root cause in master [1]. However, as exact use
case details is not known, may be it was something else.
Is it possible to provide more info on the use case: cache configuratioh,
model classes?

[1] https://issues.apache.org/jira/browse/IGNITE-8147

On Mon, Apr 2, 2018 at 12:21 PM, Yakov Zhdanov <yzhdanov@apache.org> wrote:

> Cross posting to dev.
>
> Vladimir Ozerov, can you please take a look at NPE from query processor
> (see below - GridQueryProcessor.typeByValue(GridQueryProcessor.java:1901)
> )?
>
> --Yakov
>
> 2018-03-29 0:19 GMT+03:00 smurphy <smurphy@trustwave.com>:
>
>> Code works in Ignite 2.1.0. Upgrading to 2.4.0 produces the stack trace
>> below. The delete statement that is causing the error is:
>>
>> SqlFieldsQuery sqlQuery = new SqlFieldsQuery("delete from EngineFragment
>> where " + criteria());
>> fragmentCache.query(sqlQuery.setArgs(criteria.getArgs()));
>>
>> The code above is called from within a transactional block managed by a
>> PlatformTransactionManager which is in turn managed by Spring's
>> ChainedTransactionManager. If the @Transactional annotation is removed
>> from
>> the surrounding code, then the code works ok...
>>
>> 2018-03-28 15:50:05,748 WARN  [engine 127.0.0.1] progress_monitor_2
>> unknown
>> unknown {ProgressMonitorImpl.java:112} - Scan
>> [ec7af5e8-a773-40fd-9722-f81103de73dc] is unable to process!
>> javax.cache.CacheException: Failed to process key '247002'
>>         at
>> org.apache.ignite.internal.processors.cache.IgniteCacheProxy
>> Impl.query(IgniteCacheProxyImpl.java:618)
>>         at
>> org.apache.ignite.internal.processors.cache.IgniteCacheProxy
>> Impl.query(IgniteCacheProxyImpl.java:557)
>>         at
>> org.apache.ignite.internal.processors.cache.GatewayProtected
>> CacheProxy.query(GatewayProtectedCacheProxy.java:382)
>>         at
>> com.company.core.dao.ignite.IgniteFragmentDao.delete(IgniteF
>> ragmentDao.java:143)
>>         at
>> com.company.core.dao.ignite.IgniteFragmentDao$$FastClassBySp
>> ringCGLIB$$c520aa1b.invoke(<generated>)
>>         at org.springframework.cglib.proxy.MethodProxy.invoke(MethodPro
>> xy.java:204)
>>         at
>> org.springframework.aop.framework.CglibAopProxy$CglibMethodI
>> nvocation.invokeJoinpoint(CglibAopProxy.java:720)
>>         at
>> org.springframework.aop.framework.ReflectiveMethodInvocation
>> .proceed(ReflectiveMethodInvocation.java:157)
>>         at
>> org.springframework.dao.support.PersistenceExceptionTranslat
>> ionInterceptor.invoke(PersistenceExceptionTranslationInterce
>> ptor.java:136)
>>         at
>> org.springframework.aop.framework.ReflectiveMethodInvocation
>> .proceed(ReflectiveMethodInvocation.java:179)
>>         at
>> org.springframework.aop.framework.CglibAopProxy$DynamicAdvis
>> edInterceptor.intercept(CglibAopProxy.java:655)
>>         at
>> com.company.core.dao.ignite.IgniteFragmentDao$$EnhancerBySpr
>> ingCGLIB$$ce60f71c.delete(<generated>)
>>         at
>> com.company.core.core.service.impl.InternalScanServiceImpl.p
>> urgeScanFromGrid(InternalScanServiceImpl.java:455)
>>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>         at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
>> ssorImpl.java:62)
>>         at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
>> thodAccessorImpl.java:43)
>>         at java.lang.reflect.Method.invoke(Method.java:498)
>>         at
>> org.springframework.aop.support.AopUtils.invokeJoinpointUsin
>> gReflection(AopUtils.java:302)
>>         at
>> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(
>> JdkDynamicAopProxy.java:202)
>>         at com.sun.proxy.$Proxy417.purgeScanFromGrid(Unknown Source)
>>         at com.company.core.core.async.tasks.PurgeTask.process(PurgeTas
>> k.java:85)
>>         at sun.reflect.GeneratedMethodAccessor197.invoke(Unknown Source)
>>         at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
>> thodAccessorImpl.java:43)
>>         at java.lang.reflect.Method.invoke(Method.java:498)
>>         at
>> org.springframework.aop.support.AopUtils.invokeJoinpointUsin
>> gReflection(AopUtils.java:302)
>>         at
>> org.springframework.aop.framework.ReflectiveMethodInvocation
>> .invokeJoinpoint(ReflectiveMethodInvocation.java:190)
>>         at
>> org.springframework.aop.framework.ReflectiveMethodInvocation
>> .proceed(ReflectiveMethodInvocation.java:157)
>>         at
>> org.springframework.transaction.interceptor.TransactionInter
>> ceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
>>         at
>> org.springframework.transaction.interceptor.TransactionAspec
>> tSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
>>         at
>> org.springframework.transaction.interceptor.TransactionInter
>> ceptor.invoke(TransactionInterceptor.java:96)
>>         at
>> org.springframework.aop.framework.ReflectiveMethodInvocation
>> .proceed(ReflectiveMethodInvocation.java:179)
>>         at
>> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(
>> JdkDynamicAopProxy.java:208)
>>         at com.sun.proxy.$Proxy418.process(Unknown Source)
>>         at
>> com.company.core.core.async.impl.ProgressMonitorImpl._runTas
>> ks(ProgressMonitorImpl.java:128)
>>         at
>> com.company.core.core.async.impl.ProgressMonitorImpl.lambda$
>> null$0(ProgressMonitorImpl.java:98)
>>         at java.util.concurrent.Executors$RunnableAdapter.call(
>> Executors.java:511)
>>         at
>> com.google.common.util.concurrent.TrustedListenableFutureTas
>> k$TrustedFutureInterruptibleTask.runInterruptibly(TrustedLis
>> tenableFutureTask.java:108)
>>         at
>> com.google.common.util.concurrent.InterruptibleTask.run(
>> InterruptibleTask.java:41)
>>         at
>> com.google.common.util.concurrent.TrustedListenableFutureTas
>> k.run(TrustedListenableFutureTask.java:77)
>>         at
>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPool
>> Executor.java:1142)
>>         at
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoo
>> lExecutor.java:617)
>>         at java.lang.Thread.run(Thread.java:745)
>> Caused by: class
>> org.apache.ignite.internal.processors.query.IgniteSQLException: Failed to
>> process key '247002'
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.doDelete(DmlStatementsProcessor.java:681)
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.processDmlSelectResult(DmlStatementsProcessor.java:582)
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.executeUpdateStatement(DmlStatementsProcessor.java:534)
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.updateSqlFields(DmlStatementsProcessor.java:160)
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.updateSqlFieldsDistributed(DmlStatementsProcessor.java:334)
>>         at
>> org.apache.ignite.internal.processors.query.h2.IgniteH2Index
>> ing.doRunPrepared(IgniteH2Indexing.java:1613)
>>         at
>> org.apache.ignite.internal.processors.query.h2.IgniteH2Index
>> ing.querySqlFields(IgniteH2Indexing.java:1577)
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or$4.applyx(GridQueryProcessor.java:2039)
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or$4.applyx(GridQueryProcessor.java:2034)
>>         at
>> org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply
>> (IgniteOutClosureX.java:36)
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or.executeQuery(GridQueryProcessor.java:2555)
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or.querySqlFields(GridQueryProcessor.java:2048)
>>         at
>> org.apache.ignite.internal.processors.cache.IgniteCacheProxy
>> Impl.query(IgniteCacheProxyImpl.java:606)
>>         ... 41 more
>> Caused by: java.sql.SQLException: Failed to process key '247002'
>>         at
>> org.apache.ignite.internal.processors.cache.query.IgniteQuer
>> yErrorCode.createJdbcSqlException(IgniteQueryErrorCode.java:116)
>>         at
>> org.apache.ignite.internal.processors.query.h2.dml.DmlBatchS
>> ender.splitErrors(DmlBatchSender.java:262)
>>         at
>> org.apache.ignite.internal.processors.query.h2.dml.DmlBatchS
>> ender.processPage(DmlBatchSender.java:228)
>>         at
>> org.apache.ignite.internal.processors.query.h2.dml.DmlBatchS
>> ender.sendBatch(DmlBatchSender.java:178)
>>         at
>> org.apache.ignite.internal.processors.query.h2.dml.DmlBatchS
>> ender.flush(DmlBatchSender.java:129)
>>         at
>> org.apache.ignite.internal.processors.query.h2.DmlStatements
>> Processor.doDelete(DmlStatementsProcessor.java:663)
>>         ... 53 more
>> Caused by: javax.cache.processor.EntryProcessorException: class
>> org.apache.ignite.IgniteCheckedException: null
>>         at
>> org.apache.ignite.internal.processors.cache.CacheInvokeResul
>> t.get(CacheInvokeResult.java:102)
>>         at
>> org.apache.ignite.internal.processors.query.h2.dml.DmlBatchS
>> ender.splitErrors(DmlBatchSender.java:259)
>>         ... 57 more
>> Caused by: class org.apache.ignite.IgniteCheckedException: null
>>         at org.apache.ignite.internal.util.IgniteUtils.cast(IgniteUtils
>> .java:7244)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheContext
>> .validateKeyAndValue(GridCacheContext.java:1832)
>>         at
>> org.apache.ignite.internal.processors.cache.transactions.Ign
>> iteTxLocalAdapter.addInvokeResult(IgniteTxLocalAdapter.java:1218)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal.access$2300(GridNearTxLocal.java:122)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal$9.apply(GridNearTxLocal.java:2329)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal$9.apply(GridNearTxLocal.java:2286)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal.processLoaded(GridNearTxLocal.java:2778)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal.access$3000(GridNearTxLocal.java:122)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal$13.apply(GridNearTxLocal.java:2524)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.near
>> .GridNearTxLocal$13.apply(GridNearTxLocal.java:2519)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureChainListen
>> er.applyCallback(GridFutureChainListener.java:78)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureChainListen
>> er.apply(GridFutureChainListener.java:70)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureChainListen
>> er.apply(GridFutureChainListener.java:30)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.not
>> ifyListener(GridFutureAdapter.java:383)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.unb
>> lock(GridFutureAdapter.java:347)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.unb
>> lockAll(GridFutureAdapter.java:335)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.onD
>> one(GridFutureAdapter.java:495)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheFutureA
>> dapter.onDone(GridCacheFutureAdapter.java:55)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.onD
>> one(GridFutureAdapter.java:474)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> GridPartitionedSingleGetFuture.onDone(GridPartitionedSingleG
>> etFuture.java:778)
>>         at
>> org.apache.ignite.internal.util.future.GridFutureAdapter.onD
>> one(GridFutureAdapter.java:451)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> GridPartitionedSingleGetFuture.setResult(GridPartitionedSing
>> leGetFuture.java:684)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> GridPartitionedSingleGetFuture.onResult(GridPartitionedSingl
>> eGetFuture.java:517)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> GridDhtCacheAdapter.processNearSingleGetResponse(GridDhtCach
>> eAdapter.java:349)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> colocated.GridDhtColocatedCache.access$100(GridDhtColocatedCache.java:83)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> colocated.GridDhtColocatedCache$2.apply(GridDhtColocatedCache.java:128)
>>         at
>> org.apache.ignite.internal.processors.cache.distributed.dht.
>> colocated.GridDhtColocatedCache$2.apply(GridDhtColocatedCache.java:126)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er.processMessage(GridCacheIoManager.java:1060)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er.onMessage0(GridCacheIoManager.java:579)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er.handleMessage(GridCacheIoManager.java:378)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er.handleMessage(GridCacheIoManager.java:304)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er.access$100(GridCacheIoManager.java:99)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheIoManag
>> er$1.onMessage(GridCacheIoManager.java:293)
>>         at
>> org.apache.ignite.internal.managers.communication.GridIoMana
>> ger.invokeListener(GridIoManager.java:1555)
>>         at
>> org.apache.ignite.internal.managers.communication.GridIoMana
>> ger.processRegularMessage0(GridIoManager.java:1183)
>>         at
>> org.apache.ignite.internal.managers.communication.GridIoMana
>> ger.access$4200(GridIoManager.java:126)
>>         at
>> org.apache.ignite.internal.managers.communication.GridIoMana
>> ger$9.run(GridIoManager.java:1090)
>>         at
>> org.apache.ignite.internal.util.StripedExecutor$Stripe.run(
>> StripedExecutor.java:505)
>>         ... 1 more
>> Caused by: java.lang.NullPointerException
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or.typeByValue(GridQueryProcessor.java:1901)
>>         at
>> org.apache.ignite.internal.processors.query.GridQueryProcess
>> or.validateKeyAndValue(GridQueryProcessor.java:2755)
>>         at
>> org.apache.ignite.internal.processors.cache.GridCacheContext
>> .validateKeyAndValue(GridCacheContext.java:1829)
>>         ... 37 more
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message