Index: main/trunk/greenstone2/perllib/ClassifyTreeModel.pm
===================================================================
--- main/trunk/greenstone2/perllib/ClassifyTreeModel.pm	(revision 21560)
+++ main/trunk/greenstone2/perllib/ClassifyTreeModel.pm	(revision 21561)
@@ -120,5 +120,8 @@
     # Unfortunately I have to check that there is text to retrieve before I
     # create a new node.
-    if(&GDBMUtils::gdbmCachedCollectionGet($self->getCollection(), $clid) =~ /\w+/)
+
+    my $index_text_directory_path = &util::filename_cat($ENV{'GSDLHOME'}, "collect", $self->getCollection(), "index", "text");
+    my $infodb_file_path = &dbutil::get_infodb_file_path("gdbm", $self->getCollection(), $index_text_directory_path);
+    if (&dbutil::read_infodb_entry("gdbm", $infodb_file_path, $clid) =~ /\w+/)
       {
         # Since the CLID can directly reference the correct entry in the GDBM we
Index: main/trunk/greenstone2/perllib/ClassifyTreeNode.pm
===================================================================
--- main/trunk/greenstone2/perllib/ClassifyTreeNode.pm	(revision 21560)
+++ main/trunk/greenstone2/perllib/ClassifyTreeNode.pm	(revision 21561)
@@ -29,7 +29,10 @@
     my $collection = $model->getCollection();
 
+    my $index_text_directory_path = &util::filename_cat($ENV{'GSDLHOME'}, "collect", $collection, "index", "text");
+    $self->{'infodb_file_path'} = &dbutil::get_infodb_file_path("gdbm", $collection, $index_text_directory_path);
+
     # Check if this node already exists in the database, and if not insert it
     # now
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $clid);
+    my $text = &dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $clid);
     if($text !~ /\w+/ && $force_new)
       {
@@ -235,5 +238,5 @@
 
     # Now determine if this node exists.
-    if(&GDBMUtils::gdbmCachedCollectionGet($collection, $next_clid) =~ /\w+/)
+    if (&dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $next_clid) =~ /\w+/)
       {
         # And if so, create it.
@@ -625,5 +628,5 @@
 
     # Load the text of this node
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $clid);
+    my $text = &dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $clid);
 
     # Replace the contains
@@ -651,5 +654,5 @@
 
     # Load the text of this node
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $clid);
+    my $text = &dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $clid);
     # Replace the numleafdocs
     $text =~ s/<numleafdocs>\d*?\n+/<numleafdocs>$numleafdocs\n/;
@@ -676,5 +679,5 @@
 
     # Load the text of this node
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $clid);
+    my $text = &dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $clid);
     # Replace the title
     $text =~ s/<Title>.*?\n+/<Title>$title\n/;
@@ -697,5 +700,5 @@
     my $clid = $self->{'clid'};
 
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $clid);
+    my $text = &dbutil::read_infodb_entry("gdbm", $self->{'infodb_file_path'}, $clid);
     return $text;
   }
Index: main/trunk/greenstone2/perllib/IncrementalDocument.pm
===================================================================
--- main/trunk/greenstone2/perllib/IncrementalDocument.pm	(revision 21560)
+++ main/trunk/greenstone2/perllib/IncrementalDocument.pm	(revision 21561)
@@ -149,5 +149,7 @@
     # Load the raw text for the document object from GDBM
     my $collection = $self->{'collection'};
-    my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $self->{'oid'});
+    my $index_text_directory_path = &util::filename_cat($ENV{'GSDLHOME'}, "collect", $collection, "index", "text");
+    my $infodb_file_path = &dbutil::get_infodb_file_path("gdbm", $collection, $index_text_directory_path);
+    my $text = &dbutil::read_infodb_entry("gdbm", $infodb_file_path, $self->{'oid'});
     # For each line in the raw text, extract the key (enclosed in angle
     # brackets) and the value
@@ -193,5 +195,8 @@
     if($doc_num >= 0)
       {
-        my $text = &GDBMUtils::gdbmCachedCollectionGet($collection, $doc_num);
+	my $index_text_directory_path = &util::filename_cat($ENV{'GSDLHOME'}, "collect", $collection, "index", "text");
+	my $infodb_file_path = &dbutil::get_infodb_file_path("gdbm", $collection, $index_text_directory_path);
+	my $text = &dbutil::read_infodb_entry("gdbm", $infodb_file_path, $doc_num);
+
         # If there is no reverse lookup, then add one now
         if($text !~ /<section>/)
