Changeset 31190 for main/trunk/greenstone2
- Timestamp:
- 2016-12-09T21:37:52+13:00 (7 years ago)
- Location:
- main/trunk/greenstone2
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/bin/script/activate.pl
r30596 r31190 92 92 # Greenstone modules 93 93 use colcfg; 94 use oaiinfo; 94 95 use scriptutil; 95 96 use servercontrol; … … 354 355 } 355 356 } 357 358 359 # now we've moved building to index, move tmp oaidb to live oaidb in parallel 360 my $oai_info = new oaiinfo($collect_cfg_filename, $collectcfg->{'infodbtype'}); 361 $oai_info->activate_collection(); 362 356 363 357 364 if ($buildtype eq "solr") { -
main/trunk/greenstone2/perllib/basebuilder.pm
r30517 r31190 29 29 no strict 'refs'; # allow filehandles to be variables and viceversa 30 30 31 use arcinfo; 31 32 use classify; 32 33 use cfgread; 33 34 use colcfg; 34 35 use dbutil; 36 use oaiinfo; 35 37 use plugin; 36 38 use util; … … 92 94 93 95 my $colcfgname = &colcfg::get_collect_cfg_name($outhandle, $gs_mode); 96 $self->{'colcfgname'} = $colcfgname; 94 97 $self->{'collect_cfg'} = &colcfg::read_collection_cfg ($colcfgname, $gs_mode); 95 98 … … 169 172 } 170 173 174 175 # Prepare to work with the <collection>/etc/oai-inf.<db> that keeps track 176 # of the OAI identifiers with their time stamps and deleted status. 177 # 178 # At this stage of working with the oai info db, we don't care whether we have a 179 # manifest or are otherwise incremental, or whether we're doing removeold (full rebuild). 180 # Because we've already dealt with that during the import stage. From here on, we pretend 181 # we're incremental, since the oai info db should just do what archiveinfo contains. 182 # This is because "building is always incremental" where oai info db is concerned. 183 184 my $archivedir = $self->{'source_dir'}; 185 my $oai_info = new oaiinfo($self->{'colcfgname'}, $self->{'collect_cfg'}->{'infodbtype'}); 186 $oai_info->building_stage_before_indexing($archivedir); 187 188 171 189 # check incremental against whether builder can cope or not. 172 190 if ($self->{'incremental'} && !$self->is_incremental_capable()) { -
main/trunk/greenstone2/perllib/inexport.pm
r31189 r31190 35 35 use dbutil; 36 36 use doc; 37 use oaiinfo; 37 38 use plugin; 38 39 use plugout; … … 354 355 my $gs_mode = "gs".$self->{'gs_version'}; #gs2 or gs3 355 356 my $config_filename = &colcfg::get_collect_cfg_name($out, $gs_mode); 357 358 # store the config file's name, so oaiinfo object constructor can be instantiated with it 359 $self->{'config_filename'} = $config_filename; 360 356 361 my $collectcfg = &colcfg::read_collection_cfg ($config_filename, $gs_mode); 357 362 … … 725 730 print STDERR "Skipping global file scan due to manifest and complexmeta configuration\n"; 726 731 } 732 733 734 # Prepare to work with the <collection>/etc/oai-inf.<db> that keeps track 735 # of the OAI identifiers with their time stamps and deleted status. 736 my $oai_info = new oaiinfo(&util::get_parent_folder($self->{'importdir'}), $collectcfg->{'infodbtype'}); 737 my $have_manifest = ($manifest eq '') ? 0 : 1; 738 $oai_info->import_stage($removeold, $have_manifest); 739 727 740 728 741 if ($manifest ne "") {
Note:
See TracChangeset
for help on using the changeset viewer.