Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-15881

Configured default interval for notification mails is not really taken into account in many cases

    XMLWordPrintable

Details

    • Unknown
    • N/A
    • N/A

    Description

      The notification assume that the value of the internal configured in the user profile will be either null or one of NotificationEmailInterval.

      Problem is that StringProperty values are never null and since XWIKI-10092 properties are always set. XWIKI-10092 made it very visible but you can reproduce the issue by explicitly selecting "---" in the profile in previous versions.

      The visible consequence (other than not getting your mails) is the following error in the log (quite often because it's for every user each time a notification scheduler is executed):

      java.lang.IllegalArgumentException: No enum constant org.xwiki.notifications.notifiers.email.NotificationEmailInterval.
      	at java.lang.Enum.valueOf(Enum.java:238)
      	at org.xwiki.notifications.notifiers.email.NotificationEmailInterval.valueOf(NotificationEmailInterval.java:30)
      	at org.xwiki.notifications.notifiers.internal.email.NotificationUserIterator.isSameInterval(NotificationUserIterator.java:153)
      	at org.xwiki.notifications.notifiers.internal.email.NotificationUserIterator.getNext(NotificationUserIterator.java:126)
      	at org.xwiki.notifications.notifiers.internal.email.NotificationUserIterator.initialize(NotificationUserIterator.java:104)
      	at org.xwiki.notifications.notifiers.internal.email.live.LiveNotificationEmailSender.sendEmails(LiveNotificationEmailSender.java:85)
      	at org.xwiki.notifications.notifiers.internal.email.live.LiveNotificationEmailManager.run(LiveNotificationEmailManager.java:127)
      	at org.xwiki.notifications.notifiers.internal.email.live.LiveNotificationEmailListener$NotificationGraceTimeRunnable.run(LiveNotificationEmailListener.java:99)
      	at org.xwiki.context.concurrent.ExecutionContextRunnable.run(ExecutionContextRunnable.java:70)
      	at java.lang.Thread.run(Thread.java:748)
      

      Attachments

        Issue Links

          Activity

            People

              gdelhumeau Guillaume Delhumeau
              tmortagne Thomas Mortagne
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: