| 1 | package KinoSearch1::Index::IndexFileNames; | ||
| 2 | 40 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | 40 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 40 | ▶ | use KinoSearch1::Util::ToolSet; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 40 | ▶ | use base qw( Exporter ); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 40 | our @EXPORT_OK = qw( | |
| 9 | SEGMENTS | ||
| 10 | DELETEABLE | ||
| 11 | SORTFILE_EXTENSION | ||
| 12 | @INDEX_EXTENSIONS | ||
| 13 | @COMPOUND_EXTENSIONS | ||
| 14 | @VECTOR_EXTENSIONS | ||
| 15 | @SCRATCH_EXTENSIONS | ||
| 16 | |||
| 17 | WRITE_LOCK_NAME | ||
| 18 | WRITE_LOCK_TIMEOUT | ||
| 19 | COMMIT_LOCK_NAME | ||
| 20 | COMMIT_LOCK_TIMEOUT | ||
| 21 | ); | ||
| 22 | |||
| 23 | # name of the index segments file | ||
| 24 | 40 | ▶ | use constant SEGMENTS => 'segments'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 25 | |||
| 26 | # name of the index deletable file | ||
| 27 | 40 | ▶ | use constant DELETABLE => 'deletable'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 28 | |||
| 29 | # extension of the temporary file used by the SortExternal sort pool | ||
| 30 | 40 | ▶ | use constant SORTFILE_EXTENSION => '.srt'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 31 | |||
| 32 | # Most, but not all of Lucene file extenstions. Missing are the ".f$num" | ||
| 33 | # extensions. Also note that 'segments' and 'deletable' don't have | ||
| 34 | # extensions. | ||
| 35 | our @INDEX_EXTENSIONS | ||
| 36 | 40 | = qw( cfs fnm fdx fdt tii tis frq prx del tvx tvd tvf tvp ); | |
| 37 | |||
| 38 | # extensions for files which are subsumed into the cfs compound file | ||
| 39 | 40 | our @COMPOUND_EXTENSIONS = qw( fnm frq prx fdx fdt tii tis ); | |
| 40 | |||
| 41 | # file extensions for term vectors | ||
| 42 | 40 | our @VECTOR_EXTENSIONS = qw( tvd tvx tvf ); | |
| 43 | |||
| 44 | 40 | our @SCRATCH_EXTENSIONS = qw( srt ); | |
| 45 | |||
| 46 | # names and constants for lockfiles | ||
| 47 | 40 | ▶ | use constant WRITE_LOCK_NAME => 'write.lock'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 48 | 40 | ▶ | use constant COMMIT_LOCK_NAME => 'commit.lock'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 49 | 40 | ▶ | use constant WRITE_LOCK_TIMEOUT => 1000; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 50 | 40 | ▶ | use constant COMMIT_LOCK_TIMEOUT => 10_000; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 51 | |||
| 52 | 40 | 1; | |
| 53 | |||
| 54 | __END__ | ||