]> git.koha-community.org Git - koha.git/commit
Bug 34587: File upload - Background job
authorPedro Amorim <pedro.amorim@ptfs-europe.com>
Mon, 21 Aug 2023 14:50:45 +0000 (14:50 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Tue, 31 Oct 2023 19:46:15 +0000 (16:46 -0300)
commitcf87082682343503a6fdff66fcf2cae35fb232d2
treef332eb7ebeac2213eccf3aaacdf1953158cea49e
parente5ec3df36e915debe642cda099cb334754fa14df
Bug 34587: File upload - Background job

ErmSushiHarvester background job will now be initiated by either
enqueue_counter_file_processing_job or by enqueue_sushi_harvest_jobs
from Koha/ERM/UsageDataProvider.pm, the former if triggered by a manual
file upload, the latter if by the 'run now' button or by the cron script.

This commit also includes some rewording/refactoring, namely:
- COUNTER file validation now happens in the API, before enqueuing the job.
- Removal of no longer used POST /erm/counter_files endpoint
- Koha/ERM/UsageDataProvider.pm:
-- run method is now enqueue_sushi_harvest_jobs
-- new enqueue_counter_file_processing_job method
-- harvest method is now harvest_sushi
-- new set_background_job_callbacks method to set the background job callbacks
- REST/V1/ERM/UsageDataProviders
-- run method is now process_SUSHI_response
-- new process_COUNTER_file endpoint

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>
12 files changed:
Koha/BackgroundJob/ErmSushiHarvester.pm
Koha/ERM/CounterFile.pm
Koha/ERM/UsageDataProvider.pm
Koha/REST/V1/ERM/CounterFiles.pm
Koha/REST/V1/ERM/UsageDataProviders.pm
api/v1/swagger/paths/erm_counter_files.yaml
api/v1/swagger/paths/erm_usage_data_providers.yaml
api/v1/swagger/swagger.yaml
koha-tmpl/intranet-tmpl/prog/en/includes/background_jobs/erm_sushi_harvester.inc
koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/UsageStatisticsDataProvidersFileImport.vue
koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/UsageStatisticsDataProvidersList.vue
koha-tmpl/intranet-tmpl/prog/js/vue/fetch/erm-api-client.js