Openbravo Issue Tracking System - Retail Modules | |||||
View Issue Details | |||||
ID | Project | Category | View Status | Date Submitted | Last Update |
0034464 | Retail Modules | StoreServer | public | 2016-11-10 15:26 | 2016-11-12 18:54 |
Reporter | mtaal | ||||
Assigned To | mtaal | ||||
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Platform | OS | 5 | OS Version | ||
Product Version | |||||
Target Version | RR17Q1 | Fixed in Version | |||
Merge Request Status | |||||
Review Assigned To | AugustoMauch | ||||
OBNetwork customer | No | ||||
Support ticket | |||||
Regression level | |||||
Regression date | |||||
Regression introduced in release | |||||
Regression introduced by commit | |||||
Triggers an Emergency Pack | No | ||||
Summary | 0034464: InvalidOrganizationChangeEventHandler should use adminmode when reading development/admin information | ||||
Description | See the related stacktrace [3] and [4], is caused because the call to dal here [1] [2] is not done in admin mode. [1] https://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization/file/24ecfabd909e/src/org/openbravo/retail/storeserver/synchronization/eventhandler/InvalidOrganizationChangeEventHandler.java#l68 [^] [2] https://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization/file/24ecfabd909e/src/org/openbravo/retail/storeserver/synchronization/eventhandler/InvalidOrganizationChangeEventHandler.java#l82 [^] [2] org.openbravo.base.exception.OBSecurityException: Entity strsync_custom_router is not readable by the user 100 at org.openbravo.dal.security.EntityAccessChecker.checkReadable(EntityAccessChecker.java:447) at org.openbravo.dal.service.OBDal.checkReadAccess(OBDal.java:601) at org.openbravo.dal.service.OBDal.checkReadAccess(OBDal.java:588) at org.openbravo.dal.service.OBDal.get(OBDal.java:297) at org.openbravo.retail.storeserver.synchronization.eventhandler.InvalidOrganizationChangeEventHandler.<clinit>(InvalidOrganizationChangeEventHandler.java:68) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:526) at org.jboss.weld.introspector.jlr.WeldConstructorImpl.newInstance(WeldConstructorImpl.java:206) at org.jboss.weld.injection.ConstructorInjectionPoint.newInstance(ConstructorInjectionPoint.java:117) at org.jboss.weld.bean.ManagedBean.createInstance(ManagedBean.java:340) at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.produce(ManagedBean.java:204) at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:296) at org.jboss.weld.context.unbound.DependentContextImpl.get(DependentContextImpl.java:68) at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:626) at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:232) at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:213) at org.jboss.weld.event.ObserverNotifier.notifyObserver(ObserverNotifier.java:117) at org.jboss.weld.event.ObserverNotifier.notifyObservers(ObserverNotifier.java:85) at org.jboss.weld.event.ObserverNotifier.fireEvent(ObserverNotifier.java:80) at org.jboss.weld.event.EventImpl.fire(EventImpl.java:69) at org.openbravo.client.kernel.event.PersistenceEventOBInterceptor.sendUpdateEvent(PersistenceEventOBInterceptor.java:106) at org.openbravo.client.kernel.event.PersistenceEventOBInterceptor.onFlushDirty(PersistenceEventOBInterceptor.java:75) [4] org.openbravo.base.exception.OBSecurityException: Entity STRSYNC_SynchronizedTable is not readable by the user 100 at org.openbravo.dal.security.EntityAccessChecker.checkReadable(EntityAccessChecker.java:447) at org.openbravo.dal.service.OBDal.checkReadAccess(OBDal.java:601) at org.openbravo.dal.service.OBDal.checkReadAccess(OBDal.java:588) at org.openbravo.dal.service.OBDal.createCriteria(OBDal.java:435) at org.openbravo.retail.storeserver.synchronization.eventhandler.InvalidOrganizationChangeEventHandler.getSynchronizedEntitiesRouterByOrganization(InvalidOrganizationChangeEventHandler.java:92) at org.openbravo.retail.storeserver.synchronization.eventhandler.InvalidOrganizationChangeEventHandler.getObservedEntities(InvalidOrganizationChangeEventHandler.java:86) at org.openbravo.client.kernel.event.EntityPersistenceEventObserver.isValidEvent(EntityPersistenceEventObserver.java:54) at org.openbravo.retail.storeserver.synchronization.eventhandler.InvalidOrganizationChangeEventHandler.onUpdate(InvalidOrganizationChangeEventHandler.java:110) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) | ||||
Steps To Reproduce | Run one of these testcases: org.openbravo.test.webservice.WSUpdateTest.testBReadUpdateCity org.openbravo.test.datasource.DataSourceSecurity.fetchShouldBeAllowedOnlyIfRoleIsGranted | ||||
Proposed Solution | Call dal in admin mode. You can check the results of this build. It should get green after this change: https://ci.openbravo.com/view/modules/job/mod-storeserver/ [^] | ||||
Additional Information | |||||
Tags | No tags attached. | ||||
Relationships | |||||
Attached Files | |||||
Issue History | |||||
Date Modified | Username | Field | Change | ||
2016-11-10 15:26 | mtaal | New Issue | |||
2016-11-10 15:26 | mtaal | Assigned To | => mtaal | ||
2016-11-10 15:26 | mtaal | OBNetwork customer | => No | ||
2016-11-10 15:26 | mtaal | Triggers an Emergency Pack | => No | ||
2016-11-10 15:27 | mtaal | Review Assigned To | => AugustoMauch | ||
2016-11-10 15:28 | hgbot | Checkin | |||
2016-11-10 15:28 | hgbot | Note Added: 0091337 | |||
2016-11-10 15:28 | hgbot | Status | new => resolved | ||
2016-11-10 15:28 | hgbot | Resolution | open => fixed | ||
2016-11-10 15:28 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization/rev/160ea613e4ccb54475678eebf854c0409261f7ca [^] | ||
2016-11-10 15:29 | mtaal | Proposed Solution updated | |||
2016-11-11 17:43 | shuehner | Issue Monitored: shuehner | |||
2016-11-12 00:16 | hgbot | Checkin | |||
2016-11-12 00:16 | hgbot | Note Added: 0091409 | |||
2016-11-12 00:18 | mtaal | Summary | Error when initializing EventHandler using DAL when initializing static member => InvalidOrganizationChangeEventHandler should use adminmode when reading development/admin information | ||
2016-11-12 00:18 | mtaal | Description Updated | bug_revision_view_page.php?rev_id=13651#r13651 | ||
2016-11-12 18:54 | AugustoMauch | Note Added: 0091413 | |||
2016-11-12 18:54 | AugustoMauch | Status | resolved => closed |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|