Koha/misc/cronjobs
Pedro Amorim 2951edc697
Bug 34587: SUSHI COUNTER Harvester
This commit is a squash of the following:

SUSHI harvesting process in the data providers class:
* Builds the URL query and requests the SUSHI service endpoint
* Parses the JSON response and builds the csv COUNTER file and adds it to counter_files table

Usage statistics data processing:
* When a counter_files entry is stored, CounterFile.pm will:
* Parse the csv COUNTER file and
* Add a usage_titles entry for each unique title in the COUNTER file
* Add the title's respective erm_usage_mus (monthly usage) entries, repeating for each metric_type
* Add the title's respective erm_usage_yus (yearly usage) entries, repeating for each metric_type

Harvesting cronjob;

'Run now':
* API endpoint to start the harvesting process of a data provider
* Button in the data providers list to run the harvesting process for each data provider upon clicked

ERM SUSHI: Background job

Job progress is updated to total amount of usage titles after retrieving
the response from SUSHI;
Job warning and success messages are added accordingly
Redundant duplicate titles will not be added
Redundant duplicate monthly and yearly usage statistics will not be added
Data provider harvest background job harvests once per report_type

Enqueue one background job for each report_type in the usage data provider

Update the way we measure progress in the background job.
It now uses the COUNTER report body rows instead of SUSHI response results.
We're now incrementing and showing the number of skipped mus, skipped
yus, added mus and added yus
There's a bug in the way we calculate yus
Updates to background job progress bar - Depends on 34468

Signed-off-by: Jessica Zairo <jzairo@bywatersolutions.com>
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-10-31 16:45:58 -03:00
..
holds Bug 34569: (QA follow-up) Tidy block 2023-09-01 12:08:38 -03:00
recalls Bug 33992: Only consider the date when auto-expiring problematic recalls 2023-07-19 12:06:50 -03:00
rss Bug 17600: Fix POSIX imports 2021-07-29 14:37:26 +02:00
social_data
thirdparty Bug 31356: Use hold expiration date instead of adding days to the waiting date 2022-08-31 14:30:26 -03:00
advance_notices.pl Bug 34059: Add only issues from the branch that is creating the notice 2023-08-15 11:25:39 +03:00
archive_purchase_suggestions.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
automatic_checkin.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
automatic_item_modification_by_age.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
automatic_renewals.pl Bug 34924: (QA follow-up) correctly handle digest data compilation for successful renewal 2023-10-31 11:02:48 -03:00
backup.sh
batch_anonymise.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
build_browser_and_cloud.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
cart_to_shelf.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
check-url-quick.pl Bug 29697: Replace GetMarcBiblio occurrences with $biblio->metadata->record 2022-07-22 15:24:11 -03:00
cleanup_database.pl Bug 33837: Remove datetime parameter 2023-10-11 10:31:45 -03:00
cloud-kw.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
cloud-sample.conf
CONFIGURE.gmail Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
create_koc_db.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
crontab.example Bug 28688: Add renewal to crontab example 2023-10-10 09:22:31 -03:00
delete_items.pl Bug 33698: Add fields to the verbose output that show the barcode and title of items that cannot be deleted 2023-06-09 08:50:14 -03:00
delete_patrons.pl Bug 15504: (QA follow-up) Final changes 2023-10-24 10:05:23 -03:00
delete_records_via_leader.pl Bug 32656: Script delete_records_via_leader.pl no longer deletes items 2023-01-20 13:53:09 +00:00
edi_cron.pl Bug 16258: (QA follow-up) Capitalise EDIFACT 2022-04-13 15:55:39 +02:00
erm_run_harvester.pl Bug 34587: SUSHI COUNTER Harvester 2023-10-31 16:45:58 -03:00
fines.pl Bug 18855: Don't create duplicate overdue fines if an issue is returned 2023-07-06 10:08:44 -03:00
gather_print_notices.pl Bug 34728: (QA follow-up) Remove o modifier, bit more compact 2023-09-18 15:31:50 -03:00
import_webservice_batch.pl Bug 15869: Change framework on overlay 2023-02-07 10:32:22 -03:00
longoverdue.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
membership_expiry.pl Bug 35001: Add some checks to membership_expiry 2023-10-24 15:44:32 -03:00
merge_authorities.pl Bug 17600: Fix missing C4::AuthoritiesMARC import 2021-07-29 15:34:25 +02:00
notice_unprocessed_suggestions.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
overdue_notices.pl Bug 32740: Add a new option patron home library to OverdueNoticeFrom 2023-10-11 12:13:04 -03:00
patron_emailer.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
plugins_nightly.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
printoverdues.sh
process_message_queue.pl Bug 35148: before_send_messages plugin hook does not pass the --where option 2023-10-25 11:08:03 -03:00
purge_suggestions.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
reconcile_balances.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
remove_temporary_edifiles.pl
runreport.pl Bug 33285: (QA follow-up) add POD and fix some code style 2023-04-06 09:29:24 -03:00
serialsUpdate.pl Bug 28950: Mark serial late when past grace period 2022-10-11 10:42:26 -03:00
share_usage_with_koha_community.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
sitemap.pl Bug 33871: Use Koha object in Sitemapper, add optional filter 2023-09-01 11:23:25 -03:00
staticfines.pl Bug 27259: Add HomeOrHoldingBranch checks where it was missing from 2022-11-04 19:04:18 -03:00
stockrotation.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
update_patrons_category.pl Bug 31249: Use cronlogaction on update_patrons_category.pl 2022-08-05 11:53:15 -03:00
update_totalissues.pl Bug 31203: Alter other cronjobs that currenlty use cronlogaction 2022-10-05 16:12:59 -03:00
writeoff_debts.pl Bug 28995: Update aliases 2023-09-08 11:54:55 -03:00