cancel
Showing results for 
Search instead for 
Did you mean: 

Backoffice Editor Area - Error in CollectionBrowserController.handleObjectsUpdatedEvent

raja-ubique
Member
0 Kudos

Hi,

On saving an item in the backffice editor, the save operation works well. But there is an error in the log related to CollectionBrowserController.handleObjectsUpdatedEvent. The save operation is handled through a custom EditorLogicHandler that extends DefaultEditorAreaLogicHandler.

ERROR [hybrisHTTP18] [PagingDelegateController] There is no context assigned to current thread: Thread[hybrisHTTP18,5,main]. Call #initalizeContext first!
java.lang.IllegalStateException: There is no context assigned to current thread: Thread[hybrisHTTP18,5,main]. Call #initalizeContext first!
at com.hybris.cockpitng.core.spring.RequestOperationContextHolder.prepareForOperation(RequestOperationContextHolder.java:82) ~[cockpitcore-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.engine.impl.DefaultWidgetInstanceManager.prepareLongOperation(DefaultWidgetInstanceManager.java:222) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.engine.impl.DefaultWidgetInstanceManager.executeOperationInternal(DefaultWidgetInstanceManager.java:202) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.engine.impl.DefaultWidgetInstanceManager.executeOperation(DefaultWidgetInstanceManager.java:160) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.DefaultWidgetController.executeOperation(DefaultWidgetController.java:310) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.CollectionBrowserController.callExecuteOperation(CollectionBrowserController.java:1108) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.mold.impl.PagingDelegateController.fetchPage(PagingDelegateController.java:157) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.mold.impl.PagingDelegateController.loadPage(PagingDelegateController.java:86) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.mold.impl.PagingDelegateController.process(PagingDelegateController.java:311) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.mold.impl.PagingDelegateController.process(PagingDelegateController.java:301) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.CollectionBrowserController.refreshPageable(CollectionBrowserController.java:881) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.collectionbrowser.CollectionBrowserController.handleObjectsUpdatedEvent(CollectionBrowserController.java:452) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
at com.hybris.cockpitng.util.WidgetControllers.lambda$bindGlobalEventListenerIfPresent$1(WidgetControllers.java:263) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.CockpitEventUtils.dispatchGlobalEvents(CockpitEventUtils.java:100) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.events.impl.DefaultCockpitEventQueue.publishEvent(DefaultCockpitEventQueue.java:79) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.common.explorertree.ExplorerTreeController.handleObjectsModification(ExplorerTreeController.java:1023) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.common.explorertree.ExplorerTreeController.handleObjectsUpdatedEvent(ExplorerTreeController.java:983) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
at com.hybris.cockpitng.util.WidgetControllers.lambda$bindGlobalEventListenerIfPresent$1(WidgetControllers.java:263) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.CockpitEventUtils.dispatchGlobalEvents(CockpitEventUtils.java:100) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.events.impl.DefaultCockpitEventQueue.publishEvent(DefaultCockpitEventQueue.java:79) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.common.explorertree.ExplorerTreeController.handleObjectsModification(ExplorerTreeController.java:1023) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.common.explorertree.ExplorerTreeController.handleObjectsUpdatedEvent(ExplorerTreeController.java:983) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
at com.hybris.cockpitng.util.WidgetControllers.lambda$bindGlobalEventListenerIfPresent$1(WidgetControllers.java:263) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.CockpitEventUtils.dispatchGlobalEvents(CockpitEventUtils.java:100) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.events.impl.DefaultCockpitEventQueue.publishEvent(DefaultCockpitEventQueue.java:79) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.baseeditorarea.DefaultEditorAreaController.publishCRUDCockpitEventNotification(DefaultEditorAreaController.java:883) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.baseeditorarea.DefaultEditorAreaController.saveObjectInternal(DefaultEditorAreaController.java:742) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.baseeditorarea.EditorAreaLogicHandler.executeSaveWithConfirmation(EditorAreaLogicHandler.java:41) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.baseeditorarea.DefaultEditorAreaController.executeSaveWithConfirmation(DefaultEditorAreaController.java:796) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.widgets.baseeditorarea.DefaultEditorAreaController.saveObject(DefaultEditorAreaController.java:316) ~[backoffice-widgets-22.05.18-RC2.jar:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
at com.hybris.cockpitng.util.ViewAnnotationAwareComposer.invokeListenerMethod(ViewAnnotationAwareComposer.java:100) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.DefaultWidgetController.invokeListenerMethod(DefaultWidgetController.java:175) ~[cockpitframework-22.05.18-RC2.jar:?]
at com.hybris.cockpitng.util.ViewAnnotationAwareComposer.lambda$applyEventListener$0(ViewAnnotationAwareComposer.java:117) ~[cockpitframework-22.05.18-RC2.jar:?]
at org.zkoss.zk.ui.AbstractComponent.onEvent(AbstractComponent.java:3179) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3149) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3091) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.impl.EventProcessor.process(EventProcessor.java:138) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.impl.UiEngineImpl.processEvent(UiEngineImpl.java:1845) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.impl.UiEngineImpl.process(UiEngineImpl.java:1617) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.ui.impl.UiEngineImpl.execUpdate(UiEngineImpl.java:1320) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.au.http.DHtmlUpdateServlet.process(DHtmlUpdateServlet.java:611) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.au.http.DHtmlUpdateServlet.doGet(DHtmlUpdateServlet.java:487) ~[zk-8.6.3.1.jar:8.6.3.1]
at org.zkoss.zk.au.http.DHtmlUpdateServlet.doPost(DHtmlUpdateServlet.java:495) ~[zk-8.6.3.1.jar:8.6.3.1]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:515) ~[servlet-api.jar:?]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:583) ~[servlet-api.jar:?

On debugging the code, the method below in RequestOperationContextHolder is returning false that triggers the exception above.

public boolean hasContext() {
return this.operationIds.get() != null;
}

I would really appreciate any pointers for resolving this issue. This issue happens is 2205 version. Previously, we were using 6.x and the same code works well.

Accepted Solutions (0)

Answers (0)