Uploaded image for project: 'SimplyE 2.0'
  1. SimplyE 2.0
  2. SIMPLY-524

Only create circulation_events on circulation managers

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Medium Medium
    • 2.2.9cm
    • Server - Core
    • None

      Because CirculationEvents are tied in with core actions, they're being calculated on the metadata wrangler, resulting in lots of records and slower migration times. It would be nice to make event tracking optional outside of the circulation manager.

      These are the types of events that are currently being tracked:

      metadata=> select distinct type, count(id) from circulationevents group by type;
                    type               | count
      ---------------------------------+--------
       distributor_availability_notify |  33286
       distributor_license_add         |  74282
       distributor_title_remove        | 109046
       distributor_check_out           | 985066
       distributor_title_add           | 392437
       distributor_license_remove      |  14224
       distributor_check_in            | 989866
       distributor_hold_place          | 650488
       distributor_hold_release        | 339769
      (9 rows)
      

      A brief glance suggests this might be happening in

      metadata_layer.py:CirculationData#license_pool

      and

      model.py:LicensePool#update_availability

      .

      Issue is synchronized with a GitHub issue
      Repository Name: server_core
      Issue Number: 502

            Unassigned Unassigned
            github Github Sync
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: