Changeset 2218


Ignore:
Timestamp:
2001-03-21T11:13:12+12:00 (23 years ago)
Author:
sjboddie
Message:

Fixed a couple of little bugs in the collector - bugs only showed up
when using a persistent version of the library (i.e. the local library
or fastcgi)

Location:
trunk/gsdl/src/recpt
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/src/recpt/collectoraction.cpp

    r2208 r2218  
    14901490  ofile_out.close();
    14911491
     1492  // if we're altering an existing collection we need to kill off
     1493  // the existing collection server - we do this for the local library
     1494  // (and any other persistent version of the library) as the existing
     1495  // gdbm file can't be deleted while the collection server holds it open
     1496  if ((args["bc1econf"] == 1) || (args["bc1esrce"] == 1)) {
     1497    remove_colservr (collection, logout);
     1498  }   
     1499
    14921500  // set up the build command - build.bat has some issues with quoting
    14931501  // on win2k when gsdlhome contains spaces so we'll avoid using
     
    16011609void collectoraction::remove_colservr (const text_t &collection, ostream &logout) {
    16021610
     1611  recpt->uncache_collection (collection);
     1612
    16031613  recptprotolistclass *protos = recpt->get_recptprotolist_ptr();
    16041614  recptprotolistclass::iterator rprotolist_here = protos->begin();
  • trunk/gsdl/src/recpt/receptionist.cpp

    r2212 r2218  
    12961296}
    12971297
     1298// removes a collection from the cache so that the next
     1299// call to get_collectinfo_ptr() for that collection will
     1300// retrieve the collection info from the collection server
     1301void receptionist::uncache_collection (const text_t &collection) {
     1302
     1303  colinfo_tmap::iterator it = configinfo.collectinfo.find (collection);
     1304  if ((it != configinfo.collectinfo.end()) && ((*it).second.info_loaded)) {
     1305
     1306    (*it).second.info_loaded = false;
     1307
     1308  }
     1309}
     1310
    12981311// Handles an "Encoding" line from a configuration file - note that the
    12991312// configinfo.encodings map is a bit of a hack (to be fixed when the
  • trunk/gsdl/src/recpt/receptionist.h

    r1870 r2218  
    249249                      ostream &logout);
    250250
     251  void uncache_collection (const text_t &collection);
    251252 
    252253protected:
Note: See TracChangeset for help on using the changeset viewer.