cuba-platform / cuba

CUBA Platform is a high level framework for enterprise applications development
https://www.cuba-platform.com
Apache License 2.0
1.34k stars 219 forks source link

Exception after adding available for all users search folder into folder which not available for all users #1449

Closed myatlevEvg closed 6 years ago

myatlevEvg commented 6 years ago

Platform 7.0 Database: HSQLDB

1) Create a project on Platform 7.0 2) Enable Folders Pane by adding these properties in web-app.properties

cuba.web.foldersPaneEnabled=true

cuba.web.foldersPaneVisibleByDefault = true

3) Start application server 4) Go to some screen with filter and save search folder to root. This search folder shouldn't be available for all users. 5) Create another search folder and select folder from four step as the parent folder. Also, make it available for all users. 6) Click OK and try to save this search folder

AR Exception from below occurs and now you unable to login into. image.png

Here the demo project sidePanel.zip

2018-10-25 16:39:55.084 ERROR [http-nio-8080-exec-8/app-core/admin] com.haulmont.cuba.core.sys.ServiceInterceptor - Exception: 
javax.persistence.PersistenceException: Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.7.2.2-cuba): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLIntegrityConstraintViolationException: integrity constraint violation: unique constraint or index violation; SYS_PK_10231 table: SYS_FOLDER
Error Code: -104
Call: INSERT INTO SYS_FOLDER (ID, CREATE_TS, CREATED_BY, DELETE_TS, DELETED_BY, NAME, SORT_ORDER, TAB_NAME, UPDATE_TS, UPDATED_BY, VERSION, PARENT_ID, FOLDER_TYPE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
    bind => [2f23df36-2a51-2338-c7e3-d3df70777cbd, 2018-10-25 16:39:55.061, admin, null, null, Roles for all, null, roles for all caption, 2018-10-25 16:39:55.061, null, 1, e8bbcfa0-c952-c900-140d-18a682989e3a, S]
Query: InsertObjectQuery(Roles for all)
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.flush(EntityManagerImpl.java:976) ~[org.eclipse.persistence.jpa-2.7.2-2-cuba.jar:na]
    at com.haulmont.cuba.core.sys.persistence.PersistenceImplSupport$ContainerResourceSynchronization.detachAll(PersistenceImplSupport.java:496) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.sys.persistence.PersistenceImplSupport$ContainerResourceSynchronization.beforeCommit(PersistenceImplSupport.java:449) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at org.springframework.transaction.support.TransactionSynchronizationUtils.triggerBeforeCommit(TransactionSynchronizationUtils.java:96) ~[spring-tx-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.transaction.support.AbstractPlatformTransactionManager.triggerBeforeCommit(AbstractPlatformTransactionManager.java:922) ~[spring-tx-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:730) ~[spring-tx-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:714) ~[spring-tx-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.haulmont.cuba.core.sys.TransactionImpl.commit(TransactionImpl.java:104) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.app.RdbmsStore.commit(RdbmsStore.java:474) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.app.DataManagerBean.commit(DataManagerBean.java:161) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.app.DataServiceBean.commit(DataServiceBean.java:41) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:197) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.aspectj.MethodInvocationProceedingJoinPoint.proceed(MethodInvocationProceedingJoinPoint.java:88) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.haulmont.cuba.core.sys.ServiceInterceptor.aroundInvoke(ServiceInterceptor.java:117) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at sun.reflect.GeneratedMethodAccessor130.invoke(Unknown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:644) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:633) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:70) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:174) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) [spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.sun.proxy.$Proxy211.commit(Unknown Source) [na:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.haulmont.cuba.core.sys.remoting.LocalServiceInvokerImpl.invoke(LocalServiceInvokerImpl.java:94) [cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.remoting.LocalServiceProxy$LocalServiceInvocationHandler.invoke(LocalServiceProxy.java:154) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.sun.proxy.$Proxy33.commit(Unknown Source) [na:na]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.saveFolder(CubaFoldersPane.java:585) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.gui.components.WebFilterHelper.saveFolder(WebFilterHelper.java:86) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.components.filter.FilterDelegateImpl.saveFolder(FilterDelegateImpl.java:765) [cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.components.filter.FilterDelegateImpl.lambda$saveAsFolder$6(FilterDelegateImpl.java:812) [cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.FolderEditWindow.commit(FolderEditWindow.java:264) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.FolderEditWindow.lambda$initButtonOkListener$61446b05$1(FolderEditWindow.java:214) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:496) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:273) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:237) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.AbstractClientConnector.fireEvent(AbstractClientConnector.java:1041) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.ui.Button.fireClick(Button.java:384) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.widgets.CubaButton.fireClick(CubaButton.java:78) ~[cuba-web-widgets-7.0-SNAPSHOT.jar:na]
    at com.vaadin.ui.Button$1.click(Button.java:57) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:153) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:115) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocation(ServerRpcHandler.java:431) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocations(ServerRpcHandler.java:396) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleRpc(ServerRpcHandler.java:260) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.UidlRequestHandler.synchronizedHandleRequest(UidlRequestHandler.java:82) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:40) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1577) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinServlet.service(VaadinServlet.java:425) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.serviceAppRequest(CubaApplicationServlet.java:317) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.service(CubaApplicationServlet.java:208) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) ~[servlet-api.jar:na]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-websocket.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.springframework.web.filter.CompositeFilter$VirtualFilterChain.doFilter(CompositeFilter.java:107) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.web.filter.CompositeFilter.doFilter(CompositeFilter.java:73) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.haulmont.cuba.web.sys.CubaHttpFilter.doFilter(CubaHttpFilter.java:108) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) ~[catalina.jar:9.0.8]
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:494) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) ~[catalina.jar:9.0.8]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) ~[catalina.jar:9.0.8]
    at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:651) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) ~[catalina.jar:9.0.8]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) ~[catalina.jar:9.0.8]
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:412) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:754) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1385) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) ~[tomcat-coyote.jar:9.0.8]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_181]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_181]
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) ~[tomcat-util.jar:9.0.8]
    at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_181]
Caused by: org.eclipse.persistence.exceptions.DatabaseException: 
Internal Exception: java.sql.SQLIntegrityConstraintViolationException: integrity constraint violation: unique constraint or index violation; SYS_PK_10231 table: SYS_FOLDER
Error Code: -104
Call: INSERT INTO SYS_FOLDER (ID, CREATE_TS, CREATED_BY, DELETE_TS, DELETED_BY, NAME, SORT_ORDER, TAB_NAME, UPDATE_TS, UPDATED_BY, VERSION, PARENT_ID, FOLDER_TYPE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
    bind => [2f23df36-2a51-2338-c7e3-d3df70777cbd, 2018-10-25 16:39:55.061, admin, null, null, Roles for all, null, roles for all caption, 2018-10-25 16:39:55.061, null, 1, e8bbcfa0-c952-c900-140d-18a682989e3a, S]
Query: InsertObjectQuery(Roles for all)
    at org.eclipse.persistence.exceptions.DatabaseException.sqlException(DatabaseException.java:331) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeDirectNoSelect(DatabaseAccessor.java:949) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeNoSelect(DatabaseAccessor.java:1011) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:653) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeCall(DatabaseAccessor.java:561) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.AbstractSession.basicExecuteCall(AbstractSession.java:2090) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.sessions.server.ClientSession.executeCall(ClientSession.java:309) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:272) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.ExpressionQueryMechanism.executeCall(ExpressionQueryMechanism.java:2894) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.DatasourceCallQueryMechanism.insertObject(DatasourceCallQueryMechanism.java:394) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:165) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:180) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.DatabaseQueryMechanism.insertObjectForWrite(DatabaseQueryMechanism.java:502) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.InsertObjectQuery.executeCommit(InsertObjectQuery.java:80) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.InsertObjectQuery.executeCommitWithChangeSet(InsertObjectQuery.java:90) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.queries.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:314) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:58) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.DatabaseQuery.execute(DatabaseQuery.java:911) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.DatabaseQuery.executeInUnitOfWork(DatabaseQuery.java:810) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.ObjectLevelModifyQuery.executeInUnitOfWorkObjectLevelModifyQuery(ObjectLevelModifyQuery.java:108) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.queries.ObjectLevelModifyQuery.executeInUnitOfWork(ObjectLevelModifyQuery.java:85) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.internalExecuteQuery(UnitOfWorkImpl.java:3018) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1889) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1871) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1821) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:227) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:126) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.AbstractSession.writeAllObjectsWithChangeSet(AbstractSession.java:4381) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitToDatabase(UnitOfWorkImpl.java:1487) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitToDatabaseWithPreBuiltChangeSet(UnitOfWorkImpl.java:1633) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.sessions.RepeatableWriteUnitOfWork.writeChanges(RepeatableWriteUnitOfWork.java:455) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.flush(EntityManagerImpl.java:971) ~[org.eclipse.persistence.jpa-2.7.2-2-cuba.jar:na]
    ... 97 common frames omitted
Caused by: java.sql.SQLIntegrityConstraintViolationException: integrity constraint violation: unique constraint or index violation; SYS_PK_10231 table: SYS_FOLDER
    at org.hsqldb.jdbc.Util.sqlException(Unknown Source) ~[hsqldb-2.2.9.jar:2.2.9]
    at org.hsqldb.jdbc.Util.sqlException(Unknown Source) ~[hsqldb-2.2.9.jar:2.2.9]
    at org.hsqldb.jdbc.JDBCPreparedStatement.fetchResult(Unknown Source) ~[hsqldb-2.2.9.jar:2.2.9]
    at org.hsqldb.jdbc.JDBCPreparedStatement.executeUpdate(Unknown Source) ~[hsqldb-2.2.9.jar:2.2.9]
    at org.apache.tomcat.dbcp.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:97) ~[tomcat-dbcp.jar:9.0.8]
    at org.apache.tomcat.dbcp.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:97) ~[tomcat-dbcp.jar:9.0.8]
    at com.haulmont.cuba.core.sys.jdbc.ProxyPreparedStatement.lambda$executeUpdate$1(ProxyPreparedStatement.java:39) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.sys.jdbc.ProxyStatement.executeSqlStatement(ProxyStatement.java:257) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.core.sys.jdbc.ProxyPreparedStatement.executeUpdate(ProxyPreparedStatement.java:39) ~[cuba-core-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeDirectNoSelect(DatabaseAccessor.java:939) ~[org.eclipse.persistence.core-2.7.2-2-cuba.jar:na]
    ... 127 common frames omitted
2018-10-25 16:39:55.108 ERROR [http-nio-8080-exec-8/app/admin] com.haulmont.cuba.web.log.AppLog - Exception in com.haulmont.cuba.web.widgets.CubaButton: 
com.vaadin.server.ServerRpcManager$RpcInvocationException: Unable to invoke method click in com.vaadin.shared.ui.button.ButtonServerRpc
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:157) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:115) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocation(ServerRpcHandler.java:431) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocations(ServerRpcHandler.java:396) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleRpc(ServerRpcHandler.java:260) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.UidlRequestHandler.synchronizedHandleRequest(UidlRequestHandler.java:82) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:40) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1577) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinServlet.service(VaadinServlet.java:425) [vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.serviceAppRequest(CubaApplicationServlet.java:317) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.service(CubaApplicationServlet.java:208) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [servlet-api.jar:na]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.8]
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) [tomcat-websocket.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.8]
    at org.springframework.web.filter.CompositeFilter$VirtualFilterChain.doFilter(CompositeFilter.java:107) [spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.web.filter.CompositeFilter.doFilter(CompositeFilter.java:73) [spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.haulmont.cuba.web.sys.CubaHttpFilter.doFilter(CubaHttpFilter.java:108) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [catalina.jar:9.0.8]
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:494) [catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) [catalina.jar:9.0.8]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [catalina.jar:9.0.8]
    at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:651) [catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [catalina.jar:9.0.8]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:9.0.8]
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:412) [tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:754) [tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1385) [tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.8]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_181]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_181]
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.8]
    at java.lang.Thread.run(Thread.java:748) [na:1.8.0_181]
Caused by: java.lang.reflect.InvocationTargetException: null
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:153) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    ... 38 common frames omitted
Caused by: com.vaadin.event.ListenerMethod$MethodException: Invocation of method buttonClick in com.haulmont.cuba.web.app.folders.FolderEditWindow$$Lambda$476/1721031893 failed.
    at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:516) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:273) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:237) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.AbstractClientConnector.fireEvent(AbstractClientConnector.java:1041) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.ui.Button.fireClick(Button.java:384) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.widgets.CubaButton.fireClick(CubaButton.java:78) ~[cuba-web-widgets-7.0-SNAPSHOT.jar:na]
    at com.vaadin.ui.Button$1.click(Button.java:57) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    ... 43 common frames omitted
Caused by: com.haulmont.cuba.core.global.RemoteException: integrity constraint violation: unique constraint or index violation; SYS_PK_10231 table: SYS_FOLDER
    at com.haulmont.cuba.core.sys.ServiceInterceptor.aroundInvoke(ServiceInterceptor.java:129) ~[na:na]
    at sun.reflect.GeneratedMethodAccessor130.invoke(Unknown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:644) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:633) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:70) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:174) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) ~[spring-aop-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.sun.proxy.$Proxy211.commit(Unknown Source) ~[na:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.haulmont.cuba.core.sys.remoting.LocalServiceInvokerImpl.invoke(LocalServiceInvokerImpl.java:94) ~[na:na]
    at com.haulmont.cuba.web.sys.remoting.LocalServiceProxy$LocalServiceInvocationHandler.invoke(LocalServiceProxy.java:154) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.sun.proxy.$Proxy33.commit(Unknown Source) ~[na:na]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.saveFolder(CubaFoldersPane.java:585) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.gui.components.WebFilterHelper.saveFolder(WebFilterHelper.java:86) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.components.filter.FilterDelegateImpl.saveFolder(FilterDelegateImpl.java:765) ~[cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.components.filter.FilterDelegateImpl.lambda$saveAsFolder$6(FilterDelegateImpl.java:812) ~[cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.FolderEditWindow.commit(FolderEditWindow.java:264) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.FolderEditWindow.lambda$initButtonOkListener$61446b05$1(FolderEditWindow.java:214) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:496) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    ... 49 common frames omitted
2018-10-25 16:39:59.235 DEBUG [http-nio-8080-exec-55/app/admin] com.haulmont.cuba.web.App - Closing all windows
2018-10-25 16:39:59.238 DEBUG [http-nio-8080-exec-55/app-core/admin] com.haulmont.cuba.security.app.UserSessions - Removed session: 54d9abb4-ff67-422f-9515-22ce5fdb1ef2 [admin], since: Thu Oct 25 16:31:22 SAMT 2018, lastUsed: Thu Oct 25 16:39:50 SAMT 2018
2018-10-25 16:39:59.239 INFO  [http-nio-8080-exec-55/app-core/admin] com.haulmont.cuba.security.auth.AuthenticationManagerBean - Logged out: 54d9abb4-ff67-422f-9515-22ce5fdb1ef2 [admin]
2018-10-25 16:39:59.241 DEBUG [http-nio-8080-exec-55] com.haulmont.cuba.web.DefaultApp - connectionStateChanged connected: false, authenticated: false
2018-10-25 16:39:59.241 DEBUG [http-nio-8080-exec-55] com.haulmont.cuba.web.App - Closing all windows
2018-10-25 16:39:59.244 DEBUG [http-nio-8080-exec-55/app/anonymous] com.haulmont.cuba.web.DefaultApp - connectionStateChanged connected: true, authenticated: false
2018-10-25 16:39:59.244 DEBUG [http-nio-8080-exec-55/app/anonymous] com.haulmont.cuba.web.App - Closing all windows
2018-10-25 16:40:00.070 INFO  [http-nio-8080-exec-38/app-core/server] com.haulmont.cuba.security.auth.AuthenticationManagerBean - Logged in: 002e0873-c1c0-53cf-574d-7d50663a0fb0 [admin]
2018-10-25 16:40:00.074 DEBUG [http-nio-8080-exec-38/app/admin] com.haulmont.cuba.web.DefaultApp - connectionStateChanged connected: true, authenticated: true
2018-10-25 16:40:00.074 DEBUG [http-nio-8080-exec-38/app/admin] com.haulmont.cuba.web.App - Closing all windows
2018-10-25 16:40:00.076 DEBUG [http-nio-8080-exec-38/app/admin] com.haulmont.cuba.web.DefaultApp - Session reinitialized: HttpSession=org.apache.catalina.session.StandardSessionFacade@60c98243, timeout=1800sec, UserSession=002e0873-c1c0-53cf-574d-7d50663a0fb0 [admin]
2018-10-25 16:40:00.099 DEBUG [http-nio-8080-exec-38/app-core/admin] com.haulmont.cuba.core.app.RdbmsStore - loadList: metaClass=sec$UserSubstitution, view=com.haulmont.cuba.security.entity.UserSubstitution/app, query=select us from sec$UserSubstitution us where us.user.id = :userId and (us.endDate is null or us.endDate >= :currentDate) and (us.startDate is null or us.startDate <= :currentDate) and (us.substitutedUser.active = true or us.substitutedUser.active is null) order by us.substitutedUser.name
2018-10-25 16:40:00.118 DEBUG [http-nio-8080-exec-38/app-core/admin] com.haulmont.cuba.core.app.FoldersServiceBean - Loading AppFolders
2018-10-25 16:40:00.122 DEBUG [http-nio-8080-exec-38/app-core/admin] com.haulmont.cuba.core.app.FoldersServiceBean - Loading SearchFolders
2018-10-25 16:40:00.139 WARN  [http-nio-8080-exec-38/app/admin] com.haulmont.cuba.web.app.loginwindow.AppLoginWindow - Unable to login
java.lang.IllegalArgumentException: Parent needs to be added before children. To add root items, call with parent as null
    at com.vaadin.data.TreeData.addItem(TreeData.java:161) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.fillTree(CubaFoldersPane.java:570) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.createSearchFoldersPane(CubaFoldersPane.java:544) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.showFolders(CubaFoldersPane.java:157) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.folders.CubaFoldersPane.loadFolders(CubaFoldersPane.java:143) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.gui.components.mainwindow.WebFoldersPane.loadFolders(WebFoldersPane.java:59) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.xml.layout.loaders.FoldersPaneLoader.lambda$loadComponent$0(FoldersPaneLoader.java:43) ~[cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.xml.layout.loaders.ComponentLoaderContext.executePostInitTasks(ComponentLoaderContext.java:126) ~[cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.WebScreens.createScreen(WebScreens.java:231) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.WebScreens.create(WebScreens.java:162) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.gui.Screens.create(Screens.java:42) ~[cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.App.createTopLevelWindow(App.java:295) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.DefaultApp.initializeUi(DefaultApp.java:161) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.DefaultApp.connectionStateChanged(DefaultApp.java:87) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.bali.events.EventRouter.fireEvent(EventRouter.java:45) ~[cuba-global-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.security.ConnectionImpl.fireStateChangeListeners(ConnectionImpl.java:226) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.security.ConnectionImpl.login(ConnectionImpl.java:104) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.loginwindow.AppLoginWindow.doLogin(AppLoginWindow.java:349) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.loginwindow.AppLoginWindow.doLogin(AppLoginWindow.java:316) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.app.loginwindow.AppLoginWindow.login(AppLoginWindow.java:264) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.haulmont.cuba.gui.xml.DeclarativeAction.actionPerform(DeclarativeAction.java:96) [cuba-gui-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.gui.components.WebButton.buttonClicked(WebButton.java:60) [cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.widgets.CubaButton.fireClick(CubaButton.java:76) ~[cuba-web-widgets-7.0-SNAPSHOT.jar:na]
    at com.vaadin.ui.Button$1.click(Button.java:57) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_181]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_181]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_181]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_181]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:153) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:115) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocation(ServerRpcHandler.java:431) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleInvocations(ServerRpcHandler.java:396) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.ServerRpcHandler.handleRpc(ServerRpcHandler.java:260) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.communication.UidlRequestHandler.synchronizedHandleRequest(UidlRequestHandler.java:82) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:40) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1577) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.vaadin.server.VaadinServlet.service(VaadinServlet.java:425) ~[vaadin-server-8.5.1-19-cuba.jar:8.5.1-19-cuba]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.serviceAppRequest(CubaApplicationServlet.java:317) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at com.haulmont.cuba.web.sys.CubaApplicationServlet.service(CubaApplicationServlet.java:208) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) ~[servlet-api.jar:na]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-websocket.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.springframework.web.filter.CompositeFilter$VirtualFilterChain.doFilter(CompositeFilter.java:107) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at org.springframework.web.filter.CompositeFilter.doFilter(CompositeFilter.java:73) ~[spring-web-5.0.7.RELEASE.jar:5.0.7.RELEASE]
    at com.haulmont.cuba.web.sys.CubaHttpFilter.doFilter(CubaHttpFilter.java:108) ~[cuba-web-7.0-SNAPSHOT.jar:7.0-SNAPSHOT]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) ~[catalina.jar:9.0.8]
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:494) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) ~[catalina.jar:9.0.8]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) ~[catalina.jar:9.0.8]
    at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:651) ~[catalina.jar:9.0.8]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) ~[catalina.jar:9.0.8]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) ~[catalina.jar:9.0.8]
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:412) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:754) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1385) ~[tomcat-coyote.jar:9.0.8]
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) ~[tomcat-coyote.jar:9.0.8]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_181]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_181]
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) ~[tomcat-util.jar:9.0.8]
    at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_181]
myatlevEvg commented 6 years ago

When the first and the third level of folders are available for all users, but second level not available for all users, exception still occurs and you can not able to login into application