From 0a667d16ee52f85592f6cb73ce9a3915409f1c7b Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Mon, 27 Nov 2006 10:09:48 +0000 Subject: [PATCH] Fixed bug #736: Updates gets slower. The problem was that duplicate name tags (with database name in it) was generated for attributeDetails. This caused indexes to grow and grow for each update iteration. --- index/zinfo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/index/zinfo.c b/index/zinfo.c index f98b2b4..8971d89 100644 --- a/index/zinfo.c +++ b/index/zinfo.c @@ -1,4 +1,4 @@ -/* $Id: zinfo.c,v 1.73 2006-11-22 11:13:17 adam Exp $ +/* $Id: zinfo.c,v 1.74 2006-11-27 10:09:48 adam Exp $ Copyright (C) 1995-2006 Index Data ApS @@ -963,6 +963,8 @@ int zebraExplain_newDatabase (ZebraExplainInfo zei, const char *database, zebraExplain_initCommonInfo (zei, node_adinfo); + data1_mk_tag_data_text(zei->dh, node_adinfo, "name", database, zei->nmem); + return 0; } @@ -1048,6 +1050,7 @@ static void zebraExplain_writeAttributeDetails (ZebraExplainInfo zei, zad->dirty = 0; #if ZINFO_DEBUG yaz_log(YLOG_LOG, "zebraExplain_writeAttributeDetails"); + data1_pr_tree(zei->dh, zad->data1_tree, stderr); #endif drec = createRecord (zei->records, &zad->sysno); @@ -1059,9 +1062,6 @@ static void zebraExplain_writeAttributeDetails (ZebraExplainInfo zei, "/attributeDetails"); zebraExplain_updateCommonInfo (zei, node_adinfo); - data1_mk_tag_data_text (zei->dh, node_adinfo, "name", - databaseName, zei->nmem); - /* extract *searchable* keys from it. We do this here, because record count, etc. is affected */ if (key_flush) -- 1.7.10.4