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

Assignment notifications are not sent when assigned to groups

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: RESOLVED
    • Priority: Major
    • Resolution: Incorporated
    • Affects Version/s: 19.2
    • Fix Version/s: None
    • Component/s: Assignments
    • Labels:
      None
    • Test Plan:
      1. Create an assignment, set due date to 24h 10m from current time and assign it to a single section
      2. Observe stack trace in 10 minutes, emails are not sent

      Description

      When the job runs to send the assignment reminders (24h before due date), if the assignment is assigned to groups rather than the whole site the following stack trace occurs, preventing the reminders from being sent:

      04-Sep-2019 13:23:52.329 INFO [http-nio-20001-exec-455] org.sakaiproject.component.app.scheduler.ScheduledInvocationManagerImpl.createDelayedInvocation Created new Delayed Invocation: uuid=03659381-3c13-45d7-baae-ae9468cf188f
      04-Sep-2019 13:25:00.324 WARN [QuartzScheduler_Worker-4] org.sakaiproject.authz.impl.SakaiSecurity.unlock unlock(): null: null asn.all.groups /site/2cbc5001-7ddf-4fc1-ae18-d50542258796
      04-Sep-2019 13:25:00.336 ERROR [QuartzScheduler_Worker-4] org.sakaiproject.assignment.impl.reminder.AssignmentDueReminderServiceImpl.execute user=null lock=asn.read resource=87b344ed-de51-45e3-adb2-0efe43099f8f
      org.sakaiproject.exception.PermissionException: user=null lock=asn.read resource=87b344ed-de51-45e3-adb2-0efe43099f8f id: 87b344ed-de51-45e3-adb2-0efe43099f8f
      	at org.sakaiproject.assignment.impl.AssignmentServiceImpl.checkAssignmentAccessibleForUser(AssignmentServiceImpl.java:2542)
      	at org.sakaiproject.assignment.impl.AssignmentServiceImpl.getAssignment(AssignmentServiceImpl.java:1271)
      	at sun.reflect.GeneratedMethodAccessor3291.invoke(Unknown Source)
      	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.$Proxy168.getAssignment(Unknown Source)
      	at org.sakaiproject.assignment.impl.reminder.AssignmentDueReminderServiceImpl.execute(AssignmentDueReminderServiceImpl.java:118)
      	at org.sakaiproject.component.app.scheduler.jobs.ScheduledInvocationJob.execute(ScheduledInvocationJob.java:41)
      	at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
      	at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573) 

      This appears to be because the current session's userId is null causing the permission check to fail.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  ern Earle R Nietzel
                  Reporter:
                  curtisvo Curtis van Osch
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Git Source Code