<div dir="ltr"><div>Here's a small thing you can check. I see this causing issues quite a lot for these particular hooks, make sure you have,</div><div><br></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0)">    "au.expired" : {
</span><br>        "context_org":"home_ou",
<br>        "filter"                :
<br>                        { "active":"t",
<br>                        "deleted":"f" }
<br>        },</span></div><div><span style="font-family:monospace"><br></span></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0)">    "au.created" : {
</span><br>        "context_org":"home_ou",
<br>        "filter": {
<br>            "active":"t",
<br>            "deleted":"f"
<br>        }
<br>    },<br>
<br></span></div><div>In your <span style="color:rgb(0,0,0);font-family:monospace">action_trigger_filters.json file. I've seen folks have an older version of this file and not updated to teach the triggers the context of the new hooks. </span></div><div><span style="color:rgb(0,0,0);font-family:monospace"><br></span></div><div><span style="color:rgb(0,0,0);font-family:monospace">You should be able to find a good example in the current tarbell under, </span></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0)">./Open-ILS/examples/action_trigger_filters.json.example</span><br></span></div><div><br></div><div>Maybe that would help. </div><div><br></div><div><font color="#0c343d">Steven Callender<br>Support Manager<br>Equinox Open Library Initiative<br>phone:  +1 (877) Open-ILS (673-6457)</font><br style="color:rgb(136,136,136)"><a href="mailto:stevecallender@EquinoxInitiative.org" target="_blank">email:  stevecallender@equinoxOLI.org</a><br style="color:rgb(136,136,136)"><font color="#0c343d">web:</font><span style="color:rgb(136,136,136)">  </span><a href="https://equinoxinitiative.org/" target="_blank">https://equinoxOLI.org/</a><br></div><div><br></div><div><br></div><div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jul 11, 2022 at 3:40 PM Linda Jansová via Evergreen-general <<a href="mailto:evergreen-general@list.evergreen-ils.org" target="_blank">evergreen-general@list.evergreen-ils.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div>
    <div>Hi Michele,</div>
    <div><br>
    </div>
    <div>Thank you very much for all the
      suggestions including the SQL command which I find very helpful
      for the debugging process!</div>
    <div><br>
    </div>
    <div>Linda<br>
    </div>
    <div><br>
    </div>
    <div>On 7/11/22 17:12, Morgan, Michele
      wrote:<br>
    </div>
    <blockquote type="cite">
      <div dir="ltr">
        <div>Hi Linda,</div>
        <div><br>
        </div>
        <div>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><br>
        </div>
        <div>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><br>
        </div>
        <div>We also use a granularity and custom
          filter, but adding those elements will not make triggers
          succeed that are failing.</div>
        <div><br>
        </div>
        <div>Here is our crontab entry for running
          the new user action trigger:</div>
        <div><br>
          # New User Welcome Message - check every 2 minutes<br>
          */2 * * * * . ~/.bashrc && $EG_BIN_DIR/<a href="http://action_trigger_runner.pl" target="_blank">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><br>
        </div>
        <div>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><br>
        </div>
        <div>SELECT state, count(*) </div>
        <div>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><br>
        </div>
        <div>Hope this is helpful,</div>
        <div>Michele</div>
        <div><br>
        </div>
        <div>
          <div dir="ltr">
            <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">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">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">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">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">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">http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/evergreen-general</a><br>
        </blockquote>
      </div>
    </blockquote>
    <p><br>
    </p>
  </div>

_______________________________________________<br>
Evergreen-general mailing list<br>
<a href="mailto:Evergreen-general@list.evergreen-ils.org" target="_blank">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">http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/evergreen-general</a><br>
</blockquote></div></div>