Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NPE with in-memory read constraints in a cluster environment #3075

Closed
andreysubbotin opened this issue Oct 29, 2020 · 1 comment
Closed

NPE with in-memory read constraints in a cluster environment #3075

andreysubbotin opened this issue Oct 29, 2020 · 1 comment
Assignees
Labels
state: fixed Fixed by the developer type: bug Something isn't working ver: 7.2.14 Fixed in version ver: 7.3.0 Fixed in version
Milestone

Comments

@andreysubbotin
Copy link
Contributor

https://www.cuba-platform.ru/discuss/t/oshibka-pri-proverke-in-memory-constraints/5022

Environment

  • Platform version: 7.2

Description of the bug or enhancement

  • Minimal reproducible example
    • Create a design time group with an in-memory constraint for some entity.
    • Run application in a cluster with user session replication.
    • Try to open entity browser.
  • Actual behavior
java.lang.NullPointerException
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.lambda$isNotPermittedInMemory$11(PersistenceSecurityImpl.java:418)
at java.base/java.util.stream.MatchOps$1MatchSink.accept(MatchOps.java:90)
at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
at java.base/java.util.ArrayList$ArrayListSpliterator.tryAdvance(ArrayList.java:1632)
at com.google.common.collect.CollectSpliterators$FlatMapSpliterator.tryAdvance(CollectSpliterators.java:337)
at com.google.common.collect.CollectSpliterators$FlatMapSpliterator.tryAdvance(CollectSpliterators.java:337)
at com.google.common.collect.CollectSpliterators$FlatMapSpliterator.tryAdvance(CollectSpliterators.java:337)
at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:127)
at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:502)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:488)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
at java.base/java.util.stream.MatchOps$MatchOp.evaluateSequential(MatchOps.java:230)
at java.base/java.util.stream.MatchOps$MatchOp.evaluateSequential(MatchOps.java:196)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.allMatch(ReferencePipeline.java:533)
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.isNotPermittedInMemory(PersistenceSecurityImpl.java:418)
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.calculateFilteredData(PersistenceSecurityImpl.java:351)
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.calculateFilteredData(PersistenceSecurityImpl.java:376)
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.lambda$calculateFilteredData$2(PersistenceSecurityImpl.java:175)
at java.base/java.util.Vector.forEach(Vector.java:1388)
at com.haulmont.cuba.core.sys.PersistenceSecurityImpl.calculateFilteredData(PersistenceSecurityImpl.java:175)
at com.haulmont.cuba.core.app.RdbmsStore.loadList(RdbmsStore.java:248)
at jdk.internal.reflect.GeneratedMethodAccessor225.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:95)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212)
at com.sun.proxy.$Proxy288.loadList(Unknown Source)
at com.haulmont.cuba.core.app.DataManagerBean.loadList(DataManagerBean.java:78)
at com.haulmont.cuba.core.app.DataServiceBean.loadList(DataServiceBean.java:54)
at jdk.internal.reflect.GeneratedMethodAccessor184.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.aop.aspectj.MethodInvocationProceedingJoinPoint.proceed(MethodInvocationProceedingJoinPoint.java:88)
at com.haulmont.cuba.core.sys.ServiceInterceptor.aroundInvoke(ServiceInterceptor.java:90)
at jdk.internal.reflect.GeneratedMethodAccessor186.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:644)
at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:633)
at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:70)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:175)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:95)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212)
at com.sun.proxy.$Proxy152.loadList(Unknown Source)
at jdk.internal.reflect.GeneratedMethodAccessor184.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:205)
at com.sun.proxy.$Proxy244.loadList(Unknown Source)
at jdk.internal.reflect.GeneratedMethodAccessor226.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.remoting.support.RemoteInvocation.invoke(RemoteInvocation.java:215)
at com.haulmont.cuba.core.sys.remoting.CubaRemoteInvocationExecutor.invoke(CubaRemoteInvocationExecutor.java:110)
at org.springframework.remoting.support.RemoteInvocationBasedExporter.invoke(RemoteInvocationBasedExporter.java:78)
at org.springframework.remoting.support.RemoteInvocationBasedExporter.invokeAndCreateResult(RemoteInvocationBasedExporter.java:114)
@andreysubbotin
Copy link
Contributor Author

andreysubbotin commented Jul 1, 2021

RefApp AccessConstraintsCT tests in-memory predicate replication and execution in a cluster environment.

For QA: smoke test Access groups (runtime and design time) with in-memory constraints in a standard environment (without cluster).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
state: fixed Fixed by the developer type: bug Something isn't working ver: 7.2.14 Fixed in version ver: 7.3.0 Fixed in version
Projects
None yet
Development

No branches or pull requests

4 participants