Bug 15113 - koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled
Summary: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Command-line Utilities (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Tomás Cohen Arazi
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 16190
  Show dependency treegraph
 
Reported: 2015-11-03 01:49 UTC by Tomás Cohen Arazi
Modified: 2016-12-05 21:25 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 15113: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled (6.13 KB, patch)
2016-04-01 18:39 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
[SIGNED-OFF]Bug 15113: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled (6.22 KB, patch)
2016-04-06 19:59 UTC, Héctor Eduardo Castro Avalos
Details | Diff | Splinter Review
Bug 15113: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled (6.28 KB, patch)
2016-04-07 11:52 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi 2015-11-03 01:49:48 UTC

    
Comment 1 Tomás Cohen Arazi 2016-04-01 18:39:08 UTC Comment hidden (obsolete)
Comment 2 Héctor Eduardo Castro Avalos 2016-04-06 19:59:08 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2016-04-07 11:52:15 UTC
Created attachment 50019 [details] [review]
Bug 15113: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled

This patch changes the behaviour of the koha-rebuild-zebra script in the following way:

USE_INDEXER_DAEMON=no
- Keeps the current behaviour

USE_INDEXER_DAEMON=yes
- It skips incremental indexing to avoid races.

Caveats:
- A --force option is introduced for useing in a specific situtation that might need it
 (i.e. the administrator knows what he's doing).
- If --full is passed, the reindexing is not skipped.

The documentation files and messages are adjusted accordingly.

This patch should help users that want to use the indexing daemon, in which case they wouldn't need
to change their default 5 min cronjob (it will be just skipped). Ultimately, koha-common could have
USE_INDEXER_DAEMON = yes by default, but that's subject for another bug report.

To test:
- Play with the different option switches and USE_INDEXER_DAEMON
- Things work as expected
- Sign off

Regards

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as expected

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 4 Brendan Gallagher 2016-04-19 17:49:21 UTC
Pushed to Master - Should be in the May 2016 Release.  Thanks!
Comment 5 Julian Maurice 2016-04-21 07:44:07 UTC
Patch pushed to 3.22.x, will be in 3.22.6
Comment 6 Frédéric Demians 2016-04-27 15:32:51 UTC
Pushed to 3.22.x, will be in 3.20.11.