Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-5389

Remove now obsolete calls to NodeTypes.LastModified.update(currentNode)

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Blocker Blocker
    • 5.1.1
    • 5.1.1
    • None
    • None
    • 5.1.1

      LastUpdateContentDecorator introduced with MAGNOLIA-5351 is conflicting with explicit calls to NodeTypes.LastModified.update(currentNode). As a result we get exceptions like:

      2013-10-15 14:17:46,887 WARN  org.apache.jackrabbit.core.ItemSaveOperation      : /aschopenhauer/mgnl:lastModified: failed to restore transient state
      2013-10-15 14:17:48,517 ERROR info.magnolia.ui.contentapp.detail.DetailPresenter: An error occurred while executing an action.
      info.magnolia.ui.api.action.ActionExecutionException: javax.jcr.InvalidItemStateException: property /aschopenhauer/mgnl:lastModifiedBy: the property cannot be saved because it has been modified externally.
              at info.magnolia.ui.form.action.SaveFormAction.execute(SaveFormAction.java:97)
              at info.magnolia.ui.api.action.AbstractActionExecutor.execute(AbstractActionExecutor.java:74)
              at info.magnolia.ui.contentapp.detail.DetailPresenter.onActionFired(DetailPresenter.java:221)
              at info.magnolia.ui.dialog.actionarea.renderer.DefaultEditorActionRenderer$1.buttonClick(DefaultEditorActionRenderer.java:56)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:508)
              at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:167)
              at com.vaadin.server.AbstractClientConnector.fireEvent(AbstractClientConnector.java:968)
              at com.vaadin.ui.Button.fireClick(Button.java:368)
              at com.vaadin.ui.Button$1.click(Button.java:57)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:168)
              at com.vaadin.server.ServerRpcManager.applyInvocation(ServerRpcManager.java:118)
              at com.vaadin.server.communication.ServerRpcHandler.handleBurst(ServerRpcHandler.java:214)
              at com.vaadin.server.communication.ServerRpcHandler.handleRpc(ServerRpcHandler.java:111)
              at 
      

      As the new Decorator is taking care of updating the lastModified property now, it should be enough to remove to simply remove the explicit calls.

        Acceptance criteria

              had Jan Haderka
              dlipp Daniel Lipp
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Task DoR