Changeset 27234
- Timestamp:
- 2013-04-19T09:56:17+12:00 (11 years ago)
- Location:
- gs2-extensions/parallel-building/trunk/src/perllib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
gs2-extensions/parallel-building/trunk/src/perllib/parallelbasebuilder.pm
r27229 r27234 49 49 # /** new() **/ 50 50 51 # /** @function prepareBuildRecipe() 51 # /** @function prepareIndexRecipe() 52 # * @param $self 53 # * @author jmt12 52 54 # */ 53 sub prepare BuildRecipe55 sub prepareIndexRecipe 54 56 { 55 57 my ($self) = @_; 56 58 my $outhandle = $self->{'outhandle'}; 57 print $outhandle "WARNING: prepare _build_recipe() should be implemented in subclass!!";59 print $outhandle "WARNING: prepareIndexRecipe() should be implemented in subclass!!"; 58 60 } 59 # /** prepare BuildRecipe() **/61 # /** prepareIndexRecipe() **/ 60 62 61 63 1; -
gs2-extensions/parallel-building/trunk/src/perllib/parallellucenebuilder.pm
r27228 r27234 28 28 ########################################################################### 29 29 30 # @author John Thompson, Waikato DL Research group 30 # @author David Bainbridge and Katherine Don, Waikato DL Research group 31 # @author John Rowe, DL Consulting Ltd. 32 # @author John Thompson, DL Consulting Ltd. 33 # @author John Thompson [jmt12], Waikato DL Research group 34 31 35 package parallellucenebuilder; 32 36 … … 40 44 } 41 45 46 # /** @function new() 47 # */ 42 48 sub new 43 49 { … … 46 52 return bless($self, $class); 47 53 } 54 # /** new() **/ 48 55 49 # The three main 'modes' in Lucene builds are completely independent, while 50 # index building can be further split by level [jmt12] 51 sub prepare_build_recipe 56 # /** @function prepareIndexRecipe() 57 # * The three main 'modes' in Lucene builds are completely independent, while 58 # * index building can be further split by level 59 # * @param $self 60 # * @param $collection 61 # * @param $recipe a reference to an array of recipe 'steps' 62 # * @author jmt12 63 # */ 64 sub prepareIndexRecipe 52 65 { 53 my ($self, $collection, $recipe _ref) = @_;66 my ($self, $collection, $recipe) = @_; 54 67 my $outhandle = $self->{'outhandle'}; 55 68 my $verbosity = $self->{'verbosity'}; 56 69 # 1. Compressing the text 57 push(@{$recipe _ref}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode compress_text ' . $collection});70 push(@{$recipe}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode compress_text ' . $collection}); 58 71 # 2. Info database building 59 push(@{$recipe _ref}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode infodb ' . $collection});72 push(@{$recipe}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode infodb ' . $collection}); 60 73 # 3. Now one command each for each level of index required 61 74 foreach my $level (keys %{$self->{'levels'}}) 62 75 { 63 push(@{$recipe _ref}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode build_index -indexlevel ' . $level . ' ' . $collection});76 push(@{$recipe}, {'command'=>'buildcol.pl -keepold -verbosity ' . $verbosity . ' -mode build_index -indexlevel ' . $level . ' ' . $collection}); 64 77 } 65 78 # Complete! 66 79 } 67 # /** prepare _build_recipe() **/80 # /** prepareIndexRecipe() **/ 68 81 69 82 1;
Note:
See TracChangeset
for help on using the changeset viewer.