<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <div class="moz-cite-prefix">Hi Michele,</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Thank you very much for all the
      suggestions including the SQL command which I find very helpful
      for the debugging process!</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Linda<br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">On 7/11/22 17:12, Morgan, Michele
      wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CADwhoNKA_1dyX28sezUaQDQgVWz6EignPxW1HLZYSKjP5iL8DA@mail.gmail.com">
      <div dir="ltr">
        <div class="gmail_default">Hi Linda,</div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">We have had triggers running using
          both the au.created and au.expired hooks for some time without
          problems. We've had success with them configured at both the
          consortium and system levels.</div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">Our configurations are similar to the
          stock ones you referenced. Of course, we have set Enabled to
          TRUE, whereas they are not enabled by default.</div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">We also use a granularity and custom
          filter, but adding those elements will not make triggers
          succeed that are failing.</div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">Here is our crontab entry for running
          the new user action trigger:</div>
        <div class="gmail_default"><br>
          # New User Welcome Message - check every 2 minutes<br>
          */2 * * * * . ~/.bashrc && $EG_BIN_DIR/<a
            href="http://action_trigger_runner.pl" target="_blank"
            moz-do-not-send="true">action_trigger_runner.pl</a>
          --osrf-config $SRF_CORE --process-hooks --run-pending
          --granularity welcome --granularity-only --custom-filters
          $AT_FILTERS/a_t_filters.welcome_public.json<br>
        </div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">If you have access to the database,
          you can run this query as a basic check to see if triggers
          specified by the event definition id for the current day are
          processing:<br>
        </div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">SELECT state, count(*) </div>
        <div class="gmail_default">FROM action_trigger.event<br>
          WHERE date(add_time) = date(now())<br>
          AND event_def = <event definition id><br>
          GROUP BY 1<br>
          ORDER BY 1<br>
        </div>
        <div class="gmail_default"><br>
        </div>
        <div class="gmail_default">Hope this is helpful,</div>
        <div class="gmail_default">Michele</div>
        <div class="gmail_default"><br>
        </div>
        <div>
          <div dir="ltr" data-smartmail="gmail_signature">
            <div dir="ltr">
              <div dir="ltr">
                <div dir="ltr">
                  <div dir="ltr">
                    <div dir="ltr">
                      <div><span>--</span><br>
                      </div>
                      <div>Michele M. Morgan, <span>Technical Support
                          Analyst<br>
                        </span></div>
                      <div><span>North of Boston Library Exchange,
                          Danvers Massachusetts</span></div>
                      <div><span><a href="mailto:mmorgan@noblenet.org"
                            target="_blank" moz-do-not-send="true"
                            class="moz-txt-link-freetext">mmorgan@noblenet.org</a></span></div>
                      <div><br>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
        <br>
      </div>
      <br>
      <div class="gmail_quote">
        <div dir="ltr" class="gmail_attr">On Mon, Jul 11, 2022 at 7:40
          AM Linda Jansová via Evergreen-general <<a
            href="mailto:evergreen-general@list.evergreen-ils.org"
            target="_blank" moz-do-not-send="true"
            class="moz-txt-link-freetext">evergreen-general@list.evergreen-ils.org</a>>
          wrote:<br>
        </div>
        <blockquote class="gmail_quote">
          <div>
            <p>Dear all,</p>
            <p>In our current 3.6 production system, we are trying to
              make the following triggers work:</p>
            <ul>
              <li>New User Created Welcome Notice using the au.created
                hook (like this one:
                <a
href="https://demo.evergreencatalog.com/eg2/en-US/staff/admin/local/action_trigger/event_definition/109"
                  target="_blank" moz-do-not-send="true"
                  class="moz-txt-link-freetext">https://demo.evergreencatalog.com/eg2/en-US/staff/admin/local/action_trigger/event_definition/109</a>);</li>
              <li>30 Day Account Expiration Courtesy Notice using the
                au.expired hook (like this one:
                <a
href="https://demo.evergreencatalog.com/eg2/en-US/staff/admin/local/action_trigger/event_definition/108"
                  target="_blank" moz-do-not-send="true"
                  class="moz-txt-link-freetext">https://demo.evergreencatalog.com/eg2/en-US/staff/admin/local/action_trigger/event_definition/108</a>).</li>
            </ul>
            <p>In both cases we use the predefined triggers but not on
              the consortium level as in the examples above - instead,
              they are defined on a system level for a particular
              library system (which I suppose should be fine (?)).</p>
            <p>So far the emails are not sent out as expected.</p>
            <p>Does anyone else also use these triggers/hooks? Could you
              please share your working configuration (maybe including a
              particular cron setup which is in your case relevant for
              this hook)? Or is there a procedure to follow that may
              help in the debugging process?<br>
            </p>
            <p>Or do you have any idea about what might do the trick for
              these two hooks in particular?<br>
            </p>
            <p>Thank you very much!</p>
            <p>Linda<br>
            </p>
          </div>
          _______________________________________________<br>
          Evergreen-general mailing list<br>
          <a href="mailto:Evergreen-general@list.evergreen-ils.org"
            target="_blank" moz-do-not-send="true"
            class="moz-txt-link-freetext">Evergreen-general@list.evergreen-ils.org</a><br>
          <a
href="http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/evergreen-general"
            rel="noreferrer" target="_blank" moz-do-not-send="true"
            class="moz-txt-link-freetext">http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/evergreen-general</a><br>
        </blockquote>
      </div>
    </blockquote>
    <p><br>
    </p>
  </body>
</html>