tracker r1157 - trunk/src/trackerd
- From: jamiemcc svn gnome org
- To: svn-commits-list gnome org
- Subject: tracker r1157 - trunk/src/trackerd
- Date: Tue, 26 Feb 2008 02:05:53 +0000 (GMT)
Author: jamiemcc
Date: Tue Feb 26 02:05:53 2008
New Revision: 1157
URL: http://svn.gnome.org/viewvc/tracker?rev=1157&view=rev
Log:
added more ignore files and removed cpu heavy corruption check and replaced with bigger sqlite transactions with fsync instead of corruption prone no fsync
Modified:
trunk/src/trackerd/tracker-db-sqlite.c
trunk/src/trackerd/tracker-db.h
trunk/src/trackerd/tracker-email-evolution.c
trunk/src/trackerd/tracker-utils.c
trunk/src/trackerd/trackerd.c
Modified: trunk/src/trackerd/tracker-db-sqlite.c
==============================================================================
--- trunk/src/trackerd/tracker-db-sqlite.c (original)
+++ trunk/src/trackerd/tracker-db-sqlite.c Tue Feb 26 02:05:53 2008
@@ -762,7 +762,7 @@
db_con->db = open_user_db ("common.db", &create);
- set_params (db_con, 16, FALSE);
+ set_params (db_con, 32, FALSE);
}
@@ -871,7 +871,7 @@
emails_db_con->word_index = email_word_index_db_con;
emails_db_con->index = emails_db_con;
emails_db_con->cache = db_con->cache;
-
+
return db_con;
}
@@ -989,7 +989,7 @@
void
tracker_db_set_default_pragmas (DBConnection *db_con)
{
- tracker_db_exec_no_reply (db_con, "PRAGMA synchronous = OFF;");
+ tracker_db_exec_no_reply (db_con, "PRAGMA synchronous = NORMAL;");
tracker_db_exec_no_reply (db_con, "PRAGMA count_changes = 0;");
@@ -1115,7 +1115,7 @@
db_con->db = open_db ("file-meta.db", &create);
- set_params (db_con, 128, TRUE);
+ set_params (db_con, 512, TRUE);
}
DBConnection *
@@ -1144,7 +1144,7 @@
db_con->db = open_db ("email-meta.db", &create);
- set_params (db_con, 128, TRUE);
+ set_params (db_con, 512, TRUE);
}
DBConnection *
@@ -1175,7 +1175,7 @@
db_con->db = open_db ("file-contents.db", &create);
- set_params (db_con, 256, FALSE);
+ set_params (db_con, 1024, FALSE);
if (create) {
tracker_db_exec_no_reply (db_con, "CREATE TABLE ServiceContents (ServiceID Int not null, MetadataID Int not null, Content Text, primary key (ServiceID, MetadataID))");
@@ -1214,7 +1214,7 @@
db_con->db = open_db ("email-contents.db", &create);
- set_params (db_con, 256, FALSE);
+ set_params (db_con, 512, FALSE);
if (create) {
tracker_db_exec_no_reply (db_con, "CREATE TABLE ServiceContents (ServiceID Int not null, MetadataID Int not null, Content Text, primary key (ServiceID, MetadataID))");
Modified: trunk/src/trackerd/tracker-db.h
==============================================================================
--- trunk/src/trackerd/tracker-db.h (original)
+++ trunk/src/trackerd/tracker-db.h Tue Feb 26 02:05:53 2008
@@ -50,5 +50,6 @@
void tracker_db_index_file (DBConnection *db_con, FileInfo *info, const char *attachment_uri, const char *attachment_service);
void tracker_db_index_conversation (DBConnection *db_con, FileInfo *info);
void tracker_db_index_application (DBConnection *db_con, FileInfo *info);
+void tracker_db_index_webhistory (DBConnection *db_con, FileInfo *info);
#endif
Modified: trunk/src/trackerd/tracker-email-evolution.c
==============================================================================
--- trunk/src/trackerd/tracker-email-evolution.c (original)
+++ trunk/src/trackerd/tracker-email-evolution.c Tue Feb 26 02:05:53 2008
@@ -1398,7 +1398,7 @@
return;
}
- if (tracker_db_regulate_transactions (db_con->data, 100)) {
+ if (tracker_db_regulate_transactions (db_con->data, 500)) {
if (tracker->verbosity == 1) {
tracker_log ("indexing #%d - Emails in %s", tracker->index_count, dir);
}
Modified: trunk/src/trackerd/tracker-utils.c
==============================================================================
--- trunk/src/trackerd/tracker-utils.c (original)
+++ trunk/src/trackerd/tracker-utils.c Tue Feb 26 02:05:53 2008
@@ -65,7 +65,7 @@
"TRACKER_ACTION_DIRECTORY_REFRESH", "TRACKER_ACTION_EXTRACT_METADATA",
NULL};
-char *ignore_suffix[] = {"~", ".o", ".la", ".lo", ".loT", ".in", ".csproj", ".m4", ".rej", ".gmo", ".orig", ".pc", ".omf", ".aux", ".tmp", ".po", NULL};
+char *ignore_suffix[] = {"~", ".o", ".la", ".lo", ".loT", ".in", ".csproj", ".m4", ".rej", ".gmo", ".orig", ".pc", ".omf", ".aux", ".tmp", ".po", ".vmdk",".vmx",".vmxf",".vmsd",".nvram", ".part", NULL};
char *ignore_prefix[] = {"autom4te", "conftest.", "confstat", "config.", NULL};
char *ignore_name[] = {"po", "CVS", "aclocal", "Makefile", "CVS", "SCCS", "ltmain.sh","libtool", "config.status", "conftest", "confdefs.h", NULL};
@@ -1789,6 +1789,13 @@
return g_strdup ("symlink");
}
+
+ /* handle iso files as they can be mistaken for video files */
+
+ if (g_str_has_suffix (uri, ".iso")) {
+ return g_strdup ("application/x-cd-image");
+ }
+
result = xdg_mime_get_mime_type_for_file (uri, NULL);
if (!result || (result == XDG_MIME_TYPE_UNKNOWN)) {
Modified: trunk/src/trackerd/trackerd.c
==============================================================================
--- trunk/src/trackerd/trackerd.c (original)
+++ trunk/src/trackerd/trackerd.c Tue Feb 26 02:05:53 2008
@@ -1642,7 +1642,7 @@
if (need_index) {
- if (tracker_db_regulate_transactions (db_con, 100)) {
+ if (tracker_db_regulate_transactions (db_con, 250)) {
if (tracker->verbosity == 1) {
tracker_log ("indexing #%d - %s", tracker->index_count, info->uri);
}
@@ -2795,6 +2795,9 @@
tracker_log ("performing integrity check as trackerd was not shutdown cleanly");
+
+/* turn off corruption check as it can hog cpu for long time
+
if (!tracker_db_integrity_check (db_con) || !tracker_indexer_repair ("file-index.db") || !tracker_indexer_repair ("email-index.db")) {
tracker_error ("db or index corruption detected - prepare for reindex...");
tracker_db_close (db_con);
@@ -2806,8 +2809,9 @@
db_con->thread = "main";
}
-
+*/
}
+
if (!tracker->readonly) {
tracker_db_set_option_int (db_con, "IntegrityCheck", 1);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]