Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-45433

ContentReviewItem is detached when attempting to remove

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: RESOLVED
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 21.1, 20.4 [Tentative], 22.0 [Tentative]
    • Fix Version/s: 22.0 [Tentative]
    • Component/s: content review, Turnitin
    • Labels:
      None
    • Test Plan:
      Hide

      This steps to reproduce sound like:

      1. Create an assignment and use turnitin
      2. Student submits to assignment
      3. Run Content Review Process Queue
      4. have student resubmit to the Assignment removing the previous attachment
      5. Re run the Content Review Process Queue and this error might be seen
      Show
      This steps to reproduce sound like: Create an assignment and use turnitin Student submits to assignment Run Content Review Process Queue have student resubmit to the Assignment removing the previous attachment Re run the Content Review Process Queue and this error might be seen

      Description

      When a resource does not exist then ContentReviewQueueService will remove it from the queue.

       

      Stack trace:

      28-Apr-2021 16:00:01.945 WARN [QuartzScheduler_Worker-3] org.sakaiproject.contentreview.turnitin.TurnitinReviewServiceImpl.processQueue IdUnusedException: no resource with id /attachment/INFS-213-1-S1-2021/Assignments/b0fd7310-c1ef-491c-8966-96d3c481ce65/InlineSub_8eb68c53-4f0b-4035-a287-41e5a37177b3_10848511_2021-04-23_22-13-12.html
      28-Apr-2021 16:00:01.945 ERROR [QuartzScheduler_Worker-3] org.quartz.core.JobRunShell.run Job DEFAULT.TII QUEUE threw an unhandled Exception:
      java.lang.IllegalArgumentException: Removing a detached instance org.sakaiproject.contentreview.dao.ContentReviewItem#464484
              at org.hibernate.jpa.event.internal.core.JpaDeleteEventListener.performDetachedEntityDeletionCheck(JpaDeleteEventListener.java:69)
              at org.hibernate.event.internal.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:106)
              at org.hibernate.event.internal.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:73)
              at org.hibernate.internal.SessionImpl.fireDelete(SessionImpl.java:956)
              at org.hibernate.internal.SessionImpl.delete(SessionImpl.java:896)
              at org.sakaiproject.contentreview.dao.HibernateCommonDao.delete(HibernateCommonDao.java:65)
              at org.sakaiproject.contentreview.service.ContentReviewQueueServiceImpl.delete(ContentReviewQueueServiceImpl.java:278)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:498)
              at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
              at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
              at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
              at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
              at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
              at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
              at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
              at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
              at com.sun.proxy.$Proxy136.delete(Unknown Source)
              at org.sakaiproject.contentreview.turnitin.TurnitinReviewServiceImpl.processQueue(TurnitinReviewServiceImpl.java:1444)
              at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
              at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
              at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384)
              at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
              at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
              at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150)
              at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173)
              at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
              at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:485)
              at org.sakaiproject.contentreview.service.ContentReviewFederatedServiceImpl.processQueue(ContentReviewFederatedServiceImpl.java:258)
              at org.sakaiproject.contentreview.service.jobs.ContentReviewQueue.execute(ContentReviewQueue.java:42)
              at org.sakaiproject.component.app.scheduler.jobs.SpringStatefulJobBeanWrapper.execute(SpringStatefulJobBeanWrapper.java:36)
              at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
              at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)
      
      

        Gliffy Diagrams

          Zeplin

            Attachments

              Activity

                People

                Assignee:
                ern Earle R Nietzel
                Reporter:
                ern Earle R Nietzel
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:

                    Git Integration