tracker r3049 - in trunk: . data/db data/dbus data/services src/libtracker-common src/libtracker-data src/libtracker-db src/trackerd tests tests/libtracker-db tests/scripts tests/trackerd
- From: pvanhoof svn gnome org
- To: svn-commits-list gnome org
- Subject: tracker r3049 - in trunk: . data/db data/dbus data/services src/libtracker-common src/libtracker-data src/libtracker-db src/trackerd tests tests/libtracker-db tests/scripts tests/trackerd
- Date: Wed, 11 Mar 2009 11:35:16 +0000 (UTC)
Author: pvanhoof
Date: Wed Mar 11 11:35:16 2009
New Revision: 3049
URL: http://svn.gnome.org/viewvc/tracker?rev=3049&view=rev
Log:
2009-03-11 Philip Van Hoof <philip codeminded be>
* src/libtracker-data/tracker-data-schema.c:
* src/libtracker-data/tracker-data-live-search.c:
* src/libtracker-data/tracker-data-schema.h:
* src/libtracker-data/tracker-data-live-search.h:
* src/libtracker-data/tracker-xesam-query.c:
* src/libtracker-data/tracker-xesam-query.h:
* src/libtracker-data/tracker-data-update.h:
* src/libtracker-data/Makefile.am:
* src/trackerd/tracker-search.c:
* src/trackerd/tracker-main.c:
* src/trackerd/tracker-xesam-session.c:
* src/trackerd/tracker-xesam-session.h:
* src/trackerd/tracker-xesam.c:
* src/trackerd/tracker-xesam-live-search.c:
* src/trackerd/tracker-xesam.h:
* src/trackerd/tracker-xesam-live-search.h:
* src/trackerd/tracker-xesam-manager.c:
* src/trackerd/tracker-xesam-manager.h:
* src/trackerd/tracker-dbus.c:
* src/trackerd/Makefile.am:
* src/trackerd/tracker-utils.c:
* src/libtracker-db/tracker-db-manager.c:
* src/libtracker-db/tracker-db-index-manager.c:
* src/libtracker-db/tracker-db-manager.h:
* src/libtracker-common/tracker-service.h:
* src/libtracker-common/tracker-config.c:
* src/libtracker-common/tracker-ontology.c:
* src/libtracker-common/tracker-config.h:
* src/libtracker-common/tracker-service.c:
* tests/trackerd:
* tests/trackerd/tracker-xesam-test.c:
* tests/trackerd/tracker-xesam-session-test.c:
* tests/trackerd/tracker-xesam-hit-test.c:
* tests/trackerd/Makefile.am:
* tests/trackerd/tracker-xesam-hits-test.c:
* tests/trackerd/tracker-xesam-test.h:
* tests/trackerd/tracker-xesam-session-test.h:
* tests/trackerd/tracker-xesam-hit-test.h:
* tests/trackerd/xesam:
* tests/trackerd/xesam/xesam-g-globals-private.h:
* tests/trackerd/xesam/xesam-g-testsearcher.h:
* tests/trackerd/xesam/xesam-g-debug-private.h:
* tests/trackerd/xesam/xesam-g-utils.h:
* tests/trackerd/xesam/xesam-g-test-query-builder.c:
* tests/trackerd/xesam/gtestextensions.c:
* tests/trackerd/xesam/Makefile.am:
* tests/trackerd/xesam/xesam-g-test-query-builder.h:
* tests/trackerd/xesam/gtestextensions.h:
* tests/trackerd/xesam/xesam-g-testsearcher.c:
* tests/trackerd/xesam/README:
* tests/trackerd/README:
* tests/trackerd/tracker-xesam-hits-test.h:
* tests/libtracker-db/tracker-db-manager-test-attach.c:
* tests/libtracker-db/union-performance.c:
* tests/libtracker-db/Makefile.am:
* tests/libtracker-db/tracker-db-manager-test-unattach.c:
* tests/libtracker-db/tracker-db-manager-test-custom.c:
* tests/scripts/dummy_data_start.sh.in:
* tests/Makefile.am:
* configure.ac:
* data/services/xesam-virtual.metadata:
* data/services/xesam-convenience.metadata:
* data/services/xesam-service.smapping:
* data/services/xesam.metadata:
* data/services/xesam-metadata.mmapping:
* data/services/xesam-convenience.service:
* data/services/Makefile.am:
* data/services/xesam.service:
* data/db/sqlite-stored-procs.sql:
* data/db/Makefile.am:
* data/db/sqlite-xesam.sql:
* data/dbus/tracker-xesam.xml:
* data/dbus/Makefile.am:
Trivial mini commit that removes the Xesam support. We decided to remove
this because Xesam 1.0 was never fully supported, and Xesam 2.0 will most
like be a very different DBus API, will probably use SPARQL as query
language, and will probably use Nepomuk as ontology. Which means that none
of Xesam 1.0's support code will really be usable anymore.
Perhaps keep this revision number in mind so that we can bring the code
back to live later?
Removed:
trunk/data/db/sqlite-xesam.sql
trunk/data/dbus/tracker-xesam.xml
trunk/data/services/xesam-convenience.metadata
trunk/data/services/xesam-convenience.service
trunk/data/services/xesam-metadata.mmapping
trunk/data/services/xesam-service.smapping
trunk/data/services/xesam-virtual.metadata
trunk/data/services/xesam.metadata
trunk/data/services/xesam.service
trunk/src/libtracker-data/tracker-data-live-search.c
trunk/src/libtracker-data/tracker-data-live-search.h
trunk/src/libtracker-data/tracker-xesam-query.c
trunk/src/libtracker-data/tracker-xesam-query.h
trunk/src/trackerd/tracker-xesam-live-search.c
trunk/src/trackerd/tracker-xesam-live-search.h
trunk/src/trackerd/tracker-xesam-manager.c
trunk/src/trackerd/tracker-xesam-manager.h
trunk/src/trackerd/tracker-xesam-session.c
trunk/src/trackerd/tracker-xesam-session.h
trunk/src/trackerd/tracker-xesam.c
trunk/src/trackerd/tracker-xesam.h
trunk/tests/libtracker-db/union-performance.c
trunk/tests/trackerd/
Modified:
trunk/ChangeLog
trunk/configure.ac
trunk/data/db/Makefile.am
trunk/data/db/sqlite-stored-procs.sql
trunk/data/dbus/Makefile.am
trunk/data/services/Makefile.am
trunk/src/libtracker-common/tracker-config.c
trunk/src/libtracker-common/tracker-config.h
trunk/src/libtracker-common/tracker-ontology.c
trunk/src/libtracker-common/tracker-service.c
trunk/src/libtracker-common/tracker-service.h
trunk/src/libtracker-data/Makefile.am
trunk/src/libtracker-data/tracker-data-schema.c
trunk/src/libtracker-data/tracker-data-schema.h
trunk/src/libtracker-data/tracker-data-update.h
trunk/src/libtracker-db/tracker-db-index-manager.c
trunk/src/libtracker-db/tracker-db-manager.c
trunk/src/libtracker-db/tracker-db-manager.h
trunk/src/trackerd/Makefile.am
trunk/src/trackerd/tracker-dbus.c
trunk/src/trackerd/tracker-main.c
trunk/src/trackerd/tracker-search.c
trunk/src/trackerd/tracker-utils.c
trunk/tests/Makefile.am
trunk/tests/libtracker-db/Makefile.am
trunk/tests/libtracker-db/tracker-db-manager-test-attach.c
trunk/tests/libtracker-db/tracker-db-manager-test-custom.c
trunk/tests/libtracker-db/tracker-db-manager-test-unattach.c
trunk/tests/scripts/dummy_data_start.sh.in
Modified: trunk/configure.ac
==============================================================================
--- trunk/configure.ac (original)
+++ trunk/configure.ac Wed Mar 11 11:35:16 2009
@@ -259,7 +259,6 @@
if test "x$enable_unit_tests" != "xno" ; then
have_unit_tests=yes
- have_xesam_glib=no
AC_DEFINE(HAVE_UNIT_TEST, 1, [Define if we have GLib unit test framework])
@@ -271,19 +270,12 @@
AC_PATH_PROG(gtester, gtester)
if test -z $gtester; then
AC_MSG_ERROR([Could not find 'gtester'])
- else
- PKG_CHECK_MODULES(XESAM_GLIB,
- xesam-glib,
- [have_xesam_glib=yes],
- [have_xesam_glib=no])
fi
else
have_unit_tests=no
- have_xesam_glib=no
fi
AM_CONDITIONAL(HAVE_UNIT_TESTS, test "x$have_unit_tests" = "xyes")
-AM_CONDITIONAL(HAVE_XESAM_GLIB, test "x$have_xesam_glib" = "xyes")
####################################################################
# QDBM check
@@ -1355,8 +1347,6 @@
tests/scripts/dummy_data_start.sh
tests/scripts/dummy_data_stop.sh
tests/scripts/Makefile
- tests/trackerd/Makefile
- tests/trackerd/xesam/Makefile
tests/tracker-indexer/Makefile
tests/tracker-extract/Makefile
utils/Makefile
Modified: trunk/data/db/Makefile.am
==============================================================================
--- trunk/data/db/Makefile.am (original)
+++ trunk/data/db/Makefile.am Wed Mar 11 11:35:16 2009
@@ -14,7 +14,6 @@
sqlite-stored-procs.sql \
sqlite-tracker.sql \
sqlite-tracker-triggers.sql \
- sqlite-user-data.sql \
- sqlite-xesam.sql
+ sqlite-user-data.sql
EXTRA_DIST = $(config_DATA)
Modified: trunk/data/db/sqlite-stored-procs.sql
==============================================================================
--- trunk/data/db/sqlite-stored-procs.sql (original)
+++ trunk/data/db/sqlite-stored-procs.sql Wed Mar 11 11:35:16 2009
@@ -145,35 +145,6 @@
DisableVolume UPDATE Volumes SET Enabled = 0, DisabledDate = date ('now') WHERE UDI = ?;
DisableAllVolumes UPDATE Volumes SET Enabled = 0 WHERE VolumeID > 1;
-/*
- * XESAM queries
- */
-InsertXesamMetadataType INSERT INTO XesamMetaDataTypes (MetaName) VALUES (?);
-InsertXesamServiceType INSERT INTO XesamServiceTypes (TypeName) VALUES (?);
-InsertXesamMetaDataMapping INSERT INTO XesamMetaDataMapping (XesamMetaName, MetaName) VALUES (?, ?);
-InsertXesamServiceMapping INSERT INTO XesamServiceMapping (XesamTypeName, TypeName) VALUES (?, ?);
-InsertXesamServiceLookup REPLACE INTO XesamServiceLookup (XesamTypeName, TypeName) VALUES (?, ?);
-InsertXesamMetaDataLookup REPLACE INTO XesamMetaDataLookup (XesamMetaName, MetaName) VALUES (?, ?);
-
-GetXesamServiceParents SELECT TypeName, Parents FROM XesamServiceTypes;
-GetXesamServiceChildren SELECT Child FROM XesamServiceChildren WHERE Parent = ?;
-GetXesamServiceMappings SELECT TypeName FROM XesamServiceMapping WHERE XesamTypeName = ?;
-GetXesamServiceLookups SELECT DISTINCT TypeName FROM XesamServiceLookup WHERE XesamTypeName = ?;
-
-GetXesamMetaDataParents SELECT MetaName, Parents FROM XesamMetaDataTypes;
-GetXesamMetaDataChildren SELECT Child FROM XesamMetaDataChildren WHERE Parent = ?;
-GetXesamMetaDataMappings SELECT MetaName FROM XesamMetaDataMapping WHERE XesamMetaName = ?;
-GetXesamMetaDataLookups SELECT DISTINCT MetaName FROM XesamMetaDataLookup WHERE XesamMetaName = ?;
-GetXesamMetaDataTextLookups SELECT DISTINCT L.MetaName FROM XesamMetaDataLookup AS L INNER JOIN XesamMetaDataTypes AS T ON (T.MetaName = L.XesamMetaName) WHERE T.DataTypeID = 3;
-
-GetXesamMetaDataTypes SELECT ID, MetaName, DataTypeID, FieldName, Weight, Embedded, MultipleValues, Delimited, Filtered, Abstract FROM XesamMetaDataTypes;
-GetXesamServiceTypes SELECT TypeID, TypeName, Parents, PropertyPrefix, Enabled, Embedded, HasMetadata, HasFullText, HasThumbs, ContentMetadata, Database, ShowServiceFiles, ShowServiceDirectories, KeyMetadata1, KeyMetadata2, KeyMetadata3, KeyMetadata4, KeyMetadata5, KeyMetadata6, KeyMetadata7, KeyMetadata8, KeyMetadata9, KeyMetadata10, KeyMetadata11 FROM XesamServiceTypes;
-
-InsertXesamMimes REPLACE INTO XesamFileMimes (Mime) VALUES (?);
-InsertXesamMimePrefixes REPLACE INTO XesamFileMimePrefixes (MimePrefix) VALUES (?);
-
-GetXesamMimeForServiceId SELECT Mime FROM XesamFileMimes WHERE ServiceTypeId = ?;
-GetXesamMimePrefixForServiceId SELECT MimePrefix FROM XesamFileMimePrefixes WHERE ServiceTypeId = ?;
/*
* Turtle importing
@@ -187,4 +158,4 @@
UpdateNewID UPDATE Options SET OptionValue = ? WHERE OptionKey = 'Sequence';
GetNewEventID SELECT OptionValue FROM Options WHERE OptionKey = 'EventSequence';
-UpdateNewEventID UPDATE Options SET OptionValue = ? WHERE OptionKey = 'EventSequence';
\ No newline at end of file
+UpdateNewEventID UPDATE Options SET OptionValue = ? WHERE OptionKey = 'EventSequence';
Modified: trunk/data/dbus/Makefile.am
==============================================================================
--- trunk/data/dbus/Makefile.am (original)
+++ trunk/data/dbus/Makefile.am Wed Mar 11 11:35:16 2009
@@ -9,7 +9,6 @@
tracker-keywords.xml \
tracker-metadata.xml \
tracker-search.xml \
- tracker-xesam.xml \
tracker-indexer.xml \
tracker-extract.xml
Modified: trunk/data/services/Makefile.am
==============================================================================
--- trunk/data/services/Makefile.am (original)
+++ trunk/data/services/Makefile.am Wed Mar 11 11:35:16 2009
@@ -13,13 +13,6 @@
file.metadata \
image.metadata \
video.metadata \
- playlist.metadata \
- xesam-convenience.metadata \
- xesam-convenience.service \
- xesam.metadata \
- xesam.service \
- xesam-virtual.metadata \
- xesam-service.smapping \
- xesam-metadata.mmapping
+ playlist.metadata
EXTRA_DIST = $(config_DATA)
Modified: trunk/src/libtracker-common/tracker-config.c
==============================================================================
--- trunk/src/libtracker-common/tracker-config.c (original)
+++ trunk/src/libtracker-common/tracker-config.c Wed Mar 11 11:35:16 2009
@@ -71,9 +71,6 @@
#define KEY_MAX_BUCKET_COUNT "MaxBucketCount"
#define KEY_MIN_BUCKET_COUNT "MinBucketCount"
-#define GROUP_SERVICES "Services"
-#define KEY_ENABLE_XESAM "EnableXesam"
-
/* Default values */
#define DEFAULT_VERBOSITY 0
#define DEFAULT_INITIAL_SLEEP 45 /* 0->1000 */
@@ -82,7 +79,6 @@
#define DEFAULT_ENABLE_WATCHES TRUE
#define DEFAULT_THROTTLE 0 /* 0->20 */
#define DEFAULT_ENABLE_INDEXING TRUE
-#define DEFAULT_ENABLE_XESAM FALSE
#define DEFAULT_ENABLE_CONTENT_INDEXING TRUE
#define DEFAULT_ENABLE_THUMBNAILS TRUE
#define DEFAULT_FAST_MERGES FALSE
@@ -142,9 +138,6 @@
gint max_words_to_index;
gint max_bucket_count;
gint min_bucket_count;
-
- /* Services*/
- gboolean enable_xesam;
};
static void config_finalize (GObject *object);
@@ -199,9 +192,6 @@
PROP_MAX_WORDS_TO_INDEX,
PROP_MAX_BUCKET_COUNT,
PROP_MIN_BUCKET_COUNT,
-
- /* Services*/
- PROP_ENABLE_XESAM
};
G_DEFINE_TYPE (TrackerConfig, tracker_config, G_TYPE_OBJECT);
@@ -454,15 +444,6 @@
DEFAULT_MIN_BUCKET_COUNT,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
- /* Services */
- g_object_class_install_property (object_class,
- PROP_ENABLE_XESAM,
- g_param_spec_boolean ("enable-xesam",
- "Enable Xesam",
- "Xesam DBus service",
- DEFAULT_ENABLE_XESAM,
- G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
-
g_type_class_add_private (object_class, sizeof (TrackerConfigPrivate));
}
@@ -618,11 +599,6 @@
g_value_set_int (value, priv->min_bucket_count);
break;
- /* Services */
- case PROP_ENABLE_XESAM:
- g_value_set_boolean (value, priv->enable_xesam);
- break;
-
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
break;
@@ -750,12 +726,6 @@
g_value_get_int (value));
break;
- /* Services */
- case PROP_ENABLE_XESAM:
- tracker_config_set_enable_xesam (TRACKER_CONFIG (object),
- g_value_get_boolean (value));
- break;
-
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
break;
@@ -1040,15 +1010,6 @@
DEFAULT_MAX_BUCKET_COUNT);
}
- /* Services */
- if (overwrite || !g_key_file_has_key (key_file, GROUP_SERVICES, KEY_ENABLE_XESAM, NULL)) {
- g_key_file_set_boolean (key_file, GROUP_SERVICES, KEY_ENABLE_XESAM,
- DEFAULT_ENABLE_XESAM);
- g_key_file_set_comment (key_file, GROUP_SERVICES, KEY_ENABLE_XESAM,
- " Xesam DBus service.\n",
- NULL);
- }
-
g_free (language);
}
@@ -1441,9 +1402,6 @@
config_load_int (config, "max-bucket-count", priv->key_file, GROUP_PERFORMANCE, KEY_MAX_BUCKET_COUNT);
config_load_int (config, "min-bucket-count", priv->key_file, GROUP_PERFORMANCE, KEY_MIN_BUCKET_COUNT);
- /* Services */
- config_load_boolean (config, "enable-xesam", priv->key_file, GROUP_SERVICES, KEY_ENABLE_XESAM);
-
/*
* Legacy options no longer supported:
*/
@@ -1538,9 +1496,6 @@
config_save_int (config, "max-bucket-count", priv->key_file, GROUP_PERFORMANCE, KEY_MAX_BUCKET_COUNT);
config_save_int (config, "min-bucket-count", priv->key_file, GROUP_PERFORMANCE, KEY_MIN_BUCKET_COUNT);
- /* Services */
- config_save_boolean (config, "enable-xesam", priv->key_file, GROUP_SERVICES, KEY_ENABLE_XESAM);
-
g_message ("Saving config to disk...");
/* Do the actual saving to disk now */
@@ -1777,18 +1732,6 @@
}
gboolean
-tracker_config_get_enable_xesam (TrackerConfig *config)
-{
- TrackerConfigPrivate *priv;
-
- g_return_val_if_fail (TRACKER_IS_CONFIG (config), DEFAULT_ENABLE_XESAM);
-
- priv = TRACKER_CONFIG_GET_PRIVATE (config);
-
- return priv->enable_xesam;
-}
-
-gboolean
tracker_config_get_enable_content_indexing (TrackerConfig *config)
{
TrackerConfigPrivate *priv;
@@ -2116,20 +2059,6 @@
}
void
-tracker_config_set_enable_xesam (TrackerConfig *config,
- gboolean value)
-{
- TrackerConfigPrivate *priv;
-
- g_return_if_fail (TRACKER_IS_CONFIG (config));
-
- priv = TRACKER_CONFIG_GET_PRIVATE (config);
-
- priv->enable_xesam = value;
- g_object_notify (G_OBJECT (config), "enable-xesam");
-}
-
-void
tracker_config_set_enable_content_indexing (TrackerConfig *config,
gboolean value)
{
Modified: trunk/src/libtracker-common/tracker-config.h
==============================================================================
--- trunk/src/libtracker-common/tracker-config.h (original)
+++ trunk/src/libtracker-common/tracker-config.h Wed Mar 11 11:35:16 2009
@@ -64,7 +64,6 @@
gboolean tracker_config_get_enable_watches (TrackerConfig *config);
gint tracker_config_get_throttle (TrackerConfig *config);
gboolean tracker_config_get_enable_indexing (TrackerConfig *config);
-gboolean tracker_config_get_enable_xesam (TrackerConfig *config);
gboolean tracker_config_get_enable_content_indexing (TrackerConfig *config);
gboolean tracker_config_get_enable_thumbnails (TrackerConfig *config);
GSList * tracker_config_get_disabled_modules (TrackerConfig *config);
@@ -97,8 +96,6 @@
gint value);
void tracker_config_set_enable_indexing (TrackerConfig *config,
gboolean value);
-void tracker_config_set_enable_xesam (TrackerConfig *config,
- gboolean value);
void tracker_config_set_enable_content_indexing (TrackerConfig *config,
gboolean value);
void tracker_config_set_enable_thumbnails (TrackerConfig *config,
Modified: trunk/src/libtracker-common/tracker-ontology.c
==============================================================================
--- trunk/src/libtracker-common/tracker-ontology.c (original)
+++ trunk/src/libtracker-common/tracker-ontology.c Wed Mar 11 11:35:16 2009
@@ -383,8 +383,6 @@
type = TRACKER_DB_TYPE_EMAIL;
} else if (g_str_has_prefix (str, "files")) {
type = TRACKER_DB_TYPE_FILES;
- } else if (g_str_has_prefix (str, "xesam")) {
- type = TRACKER_DB_TYPE_XESAM;
} else {
type = TRACKER_DB_TYPE_FILES;
}
Modified: trunk/src/libtracker-common/tracker-service.c
==============================================================================
--- trunk/src/libtracker-common/tracker-service.c (original)
+++ trunk/src/libtracker-common/tracker-service.c Wed Mar 11 11:35:16 2009
@@ -109,9 +109,6 @@
{ TRACKER_DB_TYPE_FILES,
"TRACKER_DB_TYPE_FILES",
"files" },
- { TRACKER_DB_TYPE_XESAM,
- "TRACKER_DB_TYPE_XESAM",
- "xesam" },
{ TRACKER_DB_TYPE_CACHE,
"TRACKER_DB_TYPE_CACHE",
"cache" },
Modified: trunk/src/libtracker-common/tracker-service.h
==============================================================================
--- trunk/src/libtracker-common/tracker-service.h (original)
+++ trunk/src/libtracker-common/tracker-service.h Wed Mar 11 11:35:16 2009
@@ -40,7 +40,6 @@
TRACKER_DB_TYPE_CONTENT,
TRACKER_DB_TYPE_EMAIL,
TRACKER_DB_TYPE_FILES,
- TRACKER_DB_TYPE_XESAM,
TRACKER_DB_TYPE_CACHE,
TRACKER_DB_TYPE_USER
} TrackerDBType;
Modified: trunk/src/libtracker-data/Makefile.am
==============================================================================
--- trunk/src/libtracker-data/Makefile.am (original)
+++ trunk/src/libtracker-data/Makefile.am Wed Mar 11 11:35:16 2009
@@ -16,7 +16,6 @@
libtracker_data_la_SOURCES = \
tracker-data-backup.c \
- tracker-data-live-search.c \
tracker-data-manager.c \
tracker-data-metadata.c \
tracker-data-query.c \
@@ -26,12 +25,10 @@
tracker-field-data.c \
tracker-query-tree.c \
tracker-rdf-query.c \
- tracker-turtle.c \
- tracker-xesam-query.c
+ tracker-turtle.c
noinst_HEADERS = \
tracker-data-backup.h \
- tracker-data-live-search.h \
tracker-data-manager.h \
tracker-data-metadata.h \
tracker-data-query.h \
@@ -41,8 +38,7 @@
tracker-field-data.h \
tracker-query-tree.h \
tracker-rdf-query.h \
- tracker-turtle.h \
- tracker-xesam-query.h
+ tracker-turtle.h
libtracker_data_la_LDFLAGS = -version-info 0:0:0
libtracker_data_la_LIBADD = \
Modified: trunk/src/libtracker-data/tracker-data-schema.c
==============================================================================
--- trunk/src/libtracker-data/tracker-data-schema.c (original)
+++ trunk/src/libtracker-data/tracker-data-schema.c Wed Mar 11 11:35:16 2009
@@ -122,54 +122,6 @@
return NULL;
}
-TrackerDBResultSet *
-tracker_data_schema_xesam_get_metadata_names (TrackerDBInterface *iface,
- const gchar *name)
-{
- TrackerDBResultSet *result_set;
-
- g_return_val_if_fail (TRACKER_IS_DB_INTERFACE (iface), NULL);
- g_return_val_if_fail (name != NULL, NULL);
-
- result_set = tracker_data_manager_exec_proc (iface,
- "GetXesamMetaDataLookups",
- name,
- NULL);
-
- return result_set;
-}
-
-TrackerDBResultSet *
-tracker_data_schema_xesam_get_text_metadata_names (TrackerDBInterface *iface)
-{
- TrackerDBResultSet *result_set;
-
- g_return_val_if_fail (TRACKER_IS_DB_INTERFACE (iface), NULL);
-
- result_set = tracker_data_manager_exec_proc (iface,
- "GetXesamMetaDataTextLookups",
- NULL);
-
- return result_set;
-}
-
-TrackerDBResultSet *
-tracker_data_schema_xesam_get_service_names (TrackerDBInterface *iface,
- const gchar *name)
-{
- TrackerDBResultSet *result_set;
-
- g_return_val_if_fail (TRACKER_IS_DB_INTERFACE (iface), NULL);
- g_return_val_if_fail (name != NULL, NULL);
-
- result_set = tracker_data_manager_exec_proc (iface,
- "GetXesamServiceLookups",
- name,
- NULL);
-
- return result_set;
-}
-
const gchar *
tracker_data_schema_metadata_field_get_db_table (TrackerFieldType type)
{
Modified: trunk/src/libtracker-data/tracker-data-schema.h
==============================================================================
--- trunk/src/libtracker-data/tracker-data-schema.h (original)
+++ trunk/src/libtracker-data/tracker-data-schema.h Wed Mar 11 11:35:16 2009
@@ -57,13 +57,6 @@
gboolean is_select,
gboolean is_condition);
-/* XESAM API */
-TrackerDBResultSet *tracker_data_schema_xesam_get_metadata_names (TrackerDBInterface *iface,
- const char *name);
-TrackerDBResultSet *tracker_data_schema_xesam_get_text_metadata_names (TrackerDBInterface *iface);
-TrackerDBResultSet *tracker_data_schema_xesam_get_service_names (TrackerDBInterface *iface,
- const char *name);
-
G_END_DECLS
#endif /* __TRACKER_DATA_SCHEMA_H__ */
Modified: trunk/src/libtracker-data/tracker-data-update.h
==============================================================================
--- trunk/src/libtracker-data/tracker-data-update.h (original)
+++ trunk/src/libtracker-data/tracker-data-update.h Wed Mar 11 11:35:16 2009
@@ -84,7 +84,6 @@
guint32 service_id,
const gchar *type);
-/* XESAM API */
void tracker_data_update_delete_handled_events (TrackerDBInterface *iface);
/* Volume handling */
Modified: trunk/src/libtracker-db/tracker-db-index-manager.c
==============================================================================
--- trunk/src/libtracker-db/tracker-db-index-manager.c (original)
+++ trunk/src/libtracker-db/tracker-db-index-manager.c Wed Mar 11 11:35:16 2009
@@ -295,11 +295,9 @@
case TRACKER_DB_TYPE_INDEX:
case TRACKER_DB_TYPE_CONTENT:
case TRACKER_DB_TYPE_COMMON:
- case TRACKER_DB_TYPE_XESAM:
case TRACKER_DB_TYPE_CACHE:
case TRACKER_DB_TYPE_USER:
default:
- /* How do we handle XESAM? and others? default to files? */
index_type = TRACKER_DB_INDEX_UNKNOWN;
break;
}
@@ -335,11 +333,9 @@
case TRACKER_DB_TYPE_INDEX:
case TRACKER_DB_TYPE_CONTENT:
case TRACKER_DB_TYPE_COMMON:
- case TRACKER_DB_TYPE_XESAM:
case TRACKER_DB_TYPE_CACHE:
case TRACKER_DB_TYPE_USER:
default:
- /* How do we handle XESAM? and others? default to files? */
index_type = TRACKER_DB_INDEX_UNKNOWN;
break;
}
Modified: trunk/src/libtracker-db/tracker-db-manager.c
==============================================================================
--- trunk/src/libtracker-db/tracker-db-manager.c (original)
+++ trunk/src/libtracker-db/tracker-db-manager.c Wed Mar 11 11:35:16 2009
@@ -192,18 +192,6 @@
FALSE,
FALSE,
0 },
- { TRACKER_DB_XESAM,
- TRACKER_DB_LOCATION_DATA_DIR,
- NULL,
- "xesam.db",
- "xesam",
- NULL,
- 512,
- TRACKER_DB_PAGE_SIZE_DONT_SET,
- TRUE,
- FALSE,
- FALSE,
- 0 },
};
static gboolean db_exec_no_reply (TrackerDBInterface *iface,
@@ -221,7 +209,6 @@
static gpointer db_type_enum_class_pointer;
static TrackerDBInterface *file_iface;
static TrackerDBInterface *email_iface;
-static TrackerDBInterface *xesam_iface;
static const gchar *
location_to_directory (TrackerDBLocation location)
@@ -583,351 +570,6 @@
return TRUE;
}
-static void
-load_service_file_xesam_map (TrackerDBInterface *iface,
- const gchar *db_proc,
- const gchar *data_to_split,
- const gchar *data_to_insert)
-{
- gchar **mappings;
- gchar **mapping;
-
- mappings = g_strsplit_set (data_to_split, ";", -1);
-
- if (!mappings) {
- return;
- }
-
- for (mapping = mappings; *mapping; mapping++) {
- gchar *esc_value;
-
- esc_value = tracker_escape_string (*mapping);
- db_exec_proc (iface,
- db_proc,
- data_to_insert,
- esc_value,
- NULL);
- g_free (esc_value);
- }
-
- g_strfreev (mappings);
-}
-
-static void
-load_service_file_xesam_insert (TrackerDBInterface *iface,
- const gchar *sql_format,
- const gchar *data_to_split,
- const gchar *data_to_insert)
-{
- gchar **parents;
- gchar **parent;
-
- parents = g_strsplit_set (data_to_split, ";", -1);
-
- if (!parents) {
- return;
- }
-
- for (parent = parents; *parent; parent++) {
- gchar *sql;
-
- sql = g_strdup_printf (sql_format, *parent, data_to_insert);
- db_exec_no_reply (iface, sql);
- g_free (sql);
- }
-
- g_strfreev (parents);
-}
-
-static void
-load_service_file_xesam_update (TrackerDBInterface *iface,
- const gchar *sql_format,
- const gchar *data_to_update,
- const gchar *data_key,
- const gchar *data_value)
-{
- gchar *str;
- gchar *sql;
-
- str = tracker_escape_string (data_key);
- sql = g_strdup_printf (sql_format,
- data_to_update,
- str,
- data_value);
- db_exec_no_reply (iface, sql);
- g_free (sql);
- g_free (str);
-}
-
-static gboolean
-load_service_file_xesam (TrackerDBInterface *iface,
- const gchar *filename)
-{
- GKeyFile *key_file;
- GError *error = NULL;
- const gchar * const *language_names;
- gchar **groups;
- gchar *service_file;
- gchar *sql;
- gboolean is_metadata;
- gboolean is_service;
- gboolean is_metadata_mapping;
- gboolean is_service_mapping;
- gint i, j;
-
- const gchar *data_types[] = {
- "string",
- "float",
- "integer",
- "boolean",
- "dateTime",
- "List of strings",
- "List of Uris",
- "List of Urls",
- NULL
- };
-
- key_file = g_key_file_new ();
- service_file = g_build_filename (services_dir, filename, NULL);
-
- if (!g_key_file_load_from_file (key_file, service_file, G_KEY_FILE_NONE, &error)) {
- g_critical ("Couldn't load XESAM service file:'%s', %s",
- filename,
- error->message);
- g_clear_error (&error);
- g_free (service_file);
- g_key_file_free (key_file);
-
- return FALSE;
- }
-
- g_free (service_file);
-
- is_metadata = FALSE;
- is_service = FALSE;
- is_metadata_mapping = FALSE;
- is_service_mapping = FALSE;
-
- if (g_str_has_suffix (filename, ".metadata")) {
- is_metadata = TRUE;
- } else if (g_str_has_suffix (filename, ".service")) {
- is_service = TRUE;
- } else if (g_str_has_suffix (filename, ".mmapping")) {
- is_metadata_mapping = TRUE;
- } else if (g_str_has_suffix (filename, ".smapping")) {
- is_service_mapping = TRUE;
- } else {
- g_warning ("XESAM Service file:'%s' does not a recognised suffix "
- "('.service', '.metadata', '.mmapping' or '.smapping')",
- filename);
- g_key_file_free (key_file);
- return FALSE;
- }
-
- language_names = g_get_language_names ();
-
- groups = g_key_file_get_groups (key_file, NULL);
-
- for (i = 0; groups[i]; i++) {
- gchar *str_id;
- gchar **keys;
- gint id = -1;
-
- if (is_metadata) {
- db_exec_proc (iface,
- "InsertXesamMetadataType",
- groups[i],
- NULL);
- id = tracker_db_interface_sqlite_get_last_insert_id (TRACKER_DB_INTERFACE_SQLITE (iface));
- } else if (is_service) {
- db_exec_proc (iface,
- "InsertXesamServiceType",
- groups[i],
- NULL);
- id = tracker_db_interface_sqlite_get_last_insert_id (TRACKER_DB_INTERFACE_SQLITE (iface));
- }
-
- /* Get inserted ID */
- str_id = tracker_guint_to_string (id);
- keys = g_key_file_get_keys (key_file, groups[i], NULL, NULL);
-
- for (j = 0; keys[j]; j++) {
- gchar *value;
-
- value = g_key_file_get_locale_string (key_file,
- groups[i],
- keys[j],
- language_names[0],
- NULL);
-
- if (!value) {
- continue;
- }
-
- if (strcasecmp (value, "true") == 0) {
- g_free (value);
- value = g_strdup ("1");
- } else if (strcasecmp (value, "false") == 0) {
- g_free (value);
- value = g_strdup ("0");
- }
-
- if (is_metadata) {
- if (strcasecmp (keys[j], "Parents") == 0) {
- load_service_file_xesam_insert (iface,
- "INSERT INTO XesamMetadataChildren (Parent, Child) VALUES ('%s', '%s')",
- value,
- groups[i]);
- } else if (strcasecmp (keys[j], "ValueType") == 0) {
- gint data_id;
-
- data_id = tracker_string_in_string_list (value, (gchar **) data_types);
-
- if (data_id != -1) {
- gint mapped_data_id;
- gboolean list = FALSE;
-
- /* We map these values
- * to existing field
- * types. FIXME
- * Eventually we
- * should change the
- * config file
- * instead.
- */
-
- switch (data_id) {
- case 0:
- mapped_data_id = TRACKER_FIELD_TYPE_STRING;
- break;
- case 1:
- mapped_data_id = TRACKER_FIELD_TYPE_DOUBLE;
- break;
- case 2:
- mapped_data_id = TRACKER_FIELD_TYPE_INTEGER;
- break;
- case 3:
- mapped_data_id = TRACKER_FIELD_TYPE_INTEGER;
- break;
- case 4:
- mapped_data_id = TRACKER_FIELD_TYPE_DATE;
- break;
- case 5:
- case 6:
- case 7:
- list = TRUE;
- mapped_data_id = TRACKER_FIELD_TYPE_STRING;
- break;
- default:
- g_warning ("Couldn't map data id %d to TrackerFieldType",
- data_id);
- mapped_data_id = -1;
- }
-
- sql = g_strdup_printf ("update XesamMetadataTypes set DataTypeID = %d where ID = %s",
- mapped_data_id,
- str_id);
- db_exec_no_reply (iface, sql);
- g_free (sql);
-
- if (list) {
- sql = g_strdup_printf ("update XesamMetadataTypes set MultipleValues = 1 where ID = %s",
- str_id);
- db_exec_no_reply (iface, sql);
- g_free (sql);
- }
- }
- } else {
- load_service_file_xesam_update (iface,
- "update XesamMetadataTypes set %s = '%s' where ID = %s",
- keys[j],
- value,
- str_id);
- }
- } else if (is_service) {
- if (strcasecmp (keys[j], "Parents") == 0) {
- load_service_file_xesam_insert (iface,
- "INSERT INTO XesamServiceChildren (Parent, Child) VALUES ('%s', '%s')",
- value,
- groups[i]);
- } else if (strcasecmp (keys[j], "Mimes") == 0) {
- gchar **tab_array;
- gint k;
-
- tab_array = g_key_file_get_string_list (key_file,
- groups[i],
- keys[j],
- NULL,
- NULL);
-
- for (k = 0; tab_array[k]; k++) {
- tracker_db_interface_execute_procedure (iface, NULL,
- "InsertXesamMimes",
- tab_array[k],
- NULL);
- tracker_db_interface_execute_query (iface,
- NULL,
- "update XesamFileMimes set ServiceTypeID = %s where Mime = '%s'",
- str_id,
- tab_array[k]);
- }
-
- g_strfreev (tab_array);
- } else if (strcasecmp (keys[j], "MimePrefixes") == 0) {
- gchar **tab_array;
- gint k;
-
- tab_array = g_key_file_get_string_list (key_file,
- groups[i],
- keys[j],
- NULL,
- NULL);
-
- for (k = 0; tab_array[k]; k++) {
- tracker_db_interface_execute_procedure (iface,
- NULL,
- "InsertXesamMimePrefixes",
- tab_array[k],
- NULL);
- tracker_db_interface_execute_query (iface,
- NULL,
- "update XesamFileMimePrefixes set ServiceTypeID = %s where MimePrefix = '%s'",
- str_id,
- tab_array[k]);
- }
-
- g_strfreev (tab_array);
- } else {
- load_service_file_xesam_update (iface,
- "update XesamServiceTypes set %s = '%s' where typeID = %s",
- keys[j],
- value,
- str_id);
- }
- } else if (is_metadata_mapping) {
- load_service_file_xesam_map (iface,
- "InsertXesamMetaDataMapping",
- value,
- groups[i]);
- } else {
- load_service_file_xesam_map (iface,
- "InsertXesamServiceMapping",
- value,
- groups[i]);
- }
-
- g_free (value);
- }
-
- g_strfreev (keys);
- g_free (str_id);
- }
-
- g_strfreev (groups);
- g_key_file_free (key_file);
-
- return TRUE;
-}
static gboolean
load_prepared_queries (void)
@@ -1244,19 +886,6 @@
return db_mime_query (iface, "GetMimePrefixForServiceId", service_id);
}
-static GSList *
-db_get_xesam_mimes_for_service_id (TrackerDBInterface *iface,
- gint service_id)
-{
- return db_mime_query (iface, "GetXesamMimeForServiceId", service_id);
-}
-
-static GSList *
-db_get_xesam_mime_prefixes_for_service_id (TrackerDBInterface *iface,
- gint service_id)
-{
- return db_mime_query (iface, "GetXesamMimePrefixForServiceId", service_id);
-}
/* Converts date/time in UTC format to ISO 8160 standardised format for display */
static GValue
@@ -1835,90 +1464,6 @@
}
}
-static void
-db_get_static_xesam_data (TrackerDBInterface *iface)
-{
- TrackerDBResultSet *result_set;
-
- /* Get static xesam metadata info */
- result_set = tracker_db_interface_execute_procedure (iface,
- NULL,
- "GetXesamMetaDataTypes",
- NULL);
-
- if (result_set) {
- gboolean valid = TRUE;
-
- while (valid) {
- TrackerField *def;
-
- def = db_row_to_field_def (result_set);
- /*
- * The ids in xesam db overwritte the IDs in common db! It means that all the
- * files are assigned to a wrong category
- *
- * g_message ("Loading xesam metadata def:'%s' with type:%d",
- * tracker_field_get_name (def),
- * tracker_field_get_data_type (def));
- *
- * tracker_ontology_field_add (def);
- */
- valid = tracker_db_result_set_iter_next (result_set);
- g_object_unref (def);
- }
-
- g_object_unref (result_set);
- }
-
- /* Get static xesam service info */
- result_set = tracker_db_interface_execute_procedure (iface,
- NULL,
- "GetXesamServiceTypes",
- NULL);
-
- if (result_set) {
- gboolean valid = TRUE;
-
- while (valid) {
- TrackerService *service;
- GSList *mimes, *mime_prefixes;
- const gchar *name;
- gint id;
-
- service = db_row_to_service (result_set);
-
- if (!service) {
- continue;
- }
-
- id = tracker_service_get_id (service);
- name = tracker_service_get_name (service);
-
- mimes = db_get_xesam_mimes_for_service_id (iface, id);
- mime_prefixes = db_get_xesam_mime_prefixes_for_service_id (iface, id);
-
- /*
- * Same as above
- *
- * g_message ("Adding xesam service:'%s' with id:%d and mimes:%d",
- * name,
- * id,
- * g_slist_length (mimes));
- *
- * tracker_ontology_service_add (service,
- * mimes,
- * mime_prefixes);
- */
- g_slist_free (mimes);
- g_slist_free (mime_prefixes);
- g_object_unref (service);
-
- valid = tracker_db_result_set_iter_next (result_set);
- }
-
- g_object_unref (result_set);
- }
-}
static const gchar *
db_type_to_string (TrackerDB db)
@@ -1992,8 +1537,6 @@
/*
* Loading .service and .metadata files. "default." first because
* contain the parent categories.
- *
- * Skipping xesam files to keep the previous behaviour.
*/
load_service_file (iface, "default.service");
load_metadata_file (iface, "default.metadata");
@@ -2004,8 +1547,7 @@
while (conf_file) {
if (!strcmp (conf_file, "default.service") ||
- !strcmp (conf_file, "default.metadata") ||
- g_str_has_prefix (conf_file, "xesam")) {
+ !strcmp (conf_file, "default.metadata")) {
conf_file = g_dir_read_name (services);
continue;
}
@@ -2176,237 +1718,6 @@
return iface;
}
-static gboolean
-db_xesam_get_service_mapping (TrackerDBInterface *iface,
- const gchar *type,
- GList **list)
-{
- TrackerDBResultSet *result_set;
- gboolean valid = TRUE;
-
- result_set = db_exec_proc (iface,
- "GetXesamServiceMappings",
- type,
- NULL);
-
- if (result_set) {
- while (valid) {
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
- if (strcmp (st, " ") != 0) {
- *list = g_list_prepend (*list, g_strdup (st));
- }
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
-
- *list = g_list_reverse (*list);
- g_object_unref (result_set);
- }
-
- result_set = db_exec_proc (iface,
- "GetXesamServiceChildren",
- type,
- NULL);
- valid = TRUE;
-
- if (result_set) {
- while (valid) {
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
- db_xesam_get_service_mapping (iface, st, list);
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
-
- g_object_unref (result_set);
- }
-
- return TRUE;
-}
-
-static gboolean
-db_xesam_get_metadata_mapping (TrackerDBInterface *iface,
- const gchar *type,
- GList **list)
-{
- TrackerDBResultSet *result_set;
- gboolean valid = TRUE;
-
- result_set = db_exec_proc (iface,
- "GetXesamMetaDataMappings",
- type,
- NULL);
-
- if (result_set) {
- while (valid) {
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
-
- if (strcmp(st, " ") != 0) {
- *list = g_list_prepend (*list, g_strdup (st));
- }
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
-
- *list = g_list_reverse (*list);
- g_object_unref (result_set);
- }
-
- result_set = db_exec_proc (iface,
- "GetXesamMetaDataChildren",
- type,
- NULL);
- valid = TRUE;
-
- if (result_set) {
- while (valid) {
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
- db_xesam_get_service_mapping (iface, st ,list);
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
-
- g_object_unref (result_set);
- }
-
- return TRUE;
-}
-
-static gboolean
-db_xesam_create_lookup (TrackerDBInterface *iface)
-{
- TrackerDBResultSet *result_set;
- gboolean valid;
-
- valid = TRUE;
-
- result_set = db_exec_proc (iface,
- "GetXesamServiceParents",
- NULL);
-
- if (result_set) {
- while (valid) {
- GList *list = NULL;
- GList *iter = NULL;
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
- db_xesam_get_service_mapping (iface, st, &list);
-
- iter = g_list_first (list);
-
- while (iter) {
- db_exec_proc (iface,
- "InsertXesamServiceLookup",
- st,
- iter->data,
- NULL);
- g_free (iter->data);
- iter = g_list_next (iter);
- }
-
- g_list_free (list);
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
- }
-
- g_object_unref (result_set);
-
- valid = TRUE;
- result_set = db_exec_proc (iface,
- "GetXesamMetaDataParents",
- NULL);
-
- if (result_set) {
- while (valid) {
- GList *list = NULL;
- GList *iter = NULL;
- gchar *st;
-
- tracker_db_result_set_get (result_set, 0, &st, -1);
- db_xesam_get_metadata_mapping (iface, st, &list);
-
- iter = g_list_first (list);
- while (iter) {
- db_exec_proc (iface,
- "InsertXesamMetaDataLookup",
- st,
- iter->data,
- NULL);
- g_free (iter->data);
- iter = g_list_next (iter);
- }
-
- g_list_free (list);
-
- valid = tracker_db_result_set_iter_next (result_set);
- g_free (st);
- }
- }
-
- g_object_unref (result_set);
-
- return TRUE;
-}
-
-static TrackerDBInterface *
-db_interface_get_xesam (void)
-{
- TrackerDBInterface *iface;
- gboolean create;
-
- iface = db_interface_get (TRACKER_DB_XESAM, &create);
-
- if (create) {
-
- GDir *services;
- const gchar *conf_file;
-
- tracker_db_interface_start_transaction (iface);
- load_sql_file (iface, "sqlite-xesam.sql", NULL);
-
-
- services = g_dir_open (services_dir, 0, NULL);
-
- conf_file = g_dir_read_name (services);
-
- while (conf_file) {
-
- if (!g_str_has_prefix (conf_file, "xesam")) {
- conf_file = g_dir_read_name (services);
- continue;
- }
-
- g_debug ("Loading xesam configuration file %s", conf_file);
- load_service_file_xesam (iface, conf_file);
-
- conf_file = g_dir_read_name (services);
- }
-
- g_dir_close (services);
-
- db_xesam_create_lookup (iface);
- tracker_db_interface_end_transaction (iface);
- }
-
- /* Load static xesam data */
- db_get_static_xesam_data (iface);
-
- return iface;
-}
static TrackerDBInterface *
db_interface_create (TrackerDB db)
@@ -2439,9 +1750,6 @@
case TRACKER_DB_EMAIL_CONTENTS:
return db_interface_get_email_contents ();
- case TRACKER_DB_XESAM:
- return db_interface_get_xesam ();
-
default:
g_critical ("This TrackerDB type:%d->'%s' has no interface set up yet!!",
db,
@@ -2570,9 +1878,6 @@
{ TRACKER_DB_EMAIL_CONTENTS,
"TRACKER_DB_EMAIL_CONTENTS",
"email contents" },
- { TRACKER_DB_XESAM,
- "TRACKER_DB_XESAM",
- "xesam" },
{ 0, NULL, NULL }
};
@@ -2849,11 +2154,6 @@
email_iface = NULL;
}
- if (xesam_iface) {
- g_object_unref (xesam_iface);
- xesam_iface = NULL;
- }
-
/* Since we don't reference this enum anywhere, we do
* it here to make sure it exists when we call
@@ -3028,7 +2328,7 @@
* @service: the server for which you'll use the database connection
*
* Request a database connection that can be used for @service. At this moment
- * service can either be "Files", "Emails", "Attachments" or "Xesam".
+ * service can either be "Files", "Emails", "Attachments".
*
* The caller must NOT g_object_unref the result
*
@@ -3057,21 +2357,6 @@
iface = email_iface;
break;
- case TRACKER_DB_TYPE_XESAM:
- if (!xesam_iface) {
- xesam_iface = tracker_db_manager_get_db_interfaces (7,
- TRACKER_DB_CACHE,
- TRACKER_DB_COMMON,
- TRACKER_DB_FILE_CONTENTS,
- TRACKER_DB_FILE_METADATA,
- TRACKER_DB_EMAIL_CONTENTS,
- TRACKER_DB_EMAIL_METADATA,
- TRACKER_DB_XESAM);
- }
-
- iface = xesam_iface;
- break;
-
case TRACKER_DB_TYPE_UNKNOWN:
case TRACKER_DB_TYPE_DATA:
case TRACKER_DB_TYPE_INDEX:
@@ -3135,7 +2420,6 @@
case TRACKER_DB_TYPE_CONTENT:
case TRACKER_DB_TYPE_CACHE:
case TRACKER_DB_TYPE_USER:
- case TRACKER_DB_TYPE_XESAM:
default:
g_warning ("Database type not supported");
return NULL;
Modified: trunk/src/libtracker-db/tracker-db-manager.h
==============================================================================
--- trunk/src/libtracker-db/tracker-db-manager.h (original)
+++ trunk/src/libtracker-db/tracker-db-manager.h Wed Mar 11 11:35:16 2009
@@ -39,7 +39,6 @@
TRACKER_DB_EMAIL_METADATA,
TRACKER_DB_EMAIL_CONTENTS,
TRACKER_DB_EMAIL_FULLTEXT,
- TRACKER_DB_XESAM,
} TrackerDB;
typedef enum {
@@ -57,7 +56,6 @@
#define TRACKER_DB_FOR_FILE_SERVICE "Files"
#define TRACKER_DB_FOR_EMAIL_SERVICE "Emails"
#define TRACKER_DB_FOR_VIRTUAL_SERVICE "Virtual"
-#define TRACKER_DB_FOR_XESAM_SERVICE "Xesam"
GType tracker_db_get_type (void) G_GNUC_CONST;
Modified: trunk/src/trackerd/Makefile.am
==============================================================================
--- trunk/src/trackerd/Makefile.am (original)
+++ trunk/src/trackerd/Makefile.am Wed Mar 11 11:35:16 2009
@@ -60,14 +60,6 @@
tracker-status.h \
tracker-utils.c \
tracker-utils.h \
- tracker-xesam.c \
- tracker-xesam.h \
- tracker-xesam-manager.c \
- tracker-xesam-manager.h \
- tracker-xesam-session.c \
- tracker-xesam-session.h \
- tracker-xesam-live-search.c \
- tracker-xesam-live-search.h \
tracker-cleanup.c \
tracker-cleanup.h \
tracker-push.c \
@@ -121,7 +113,6 @@
tracker-keywords-glue.h \
tracker-metadata-glue.h \
tracker-search-glue.h \
- tracker-xesam-glue.h \
tracker-indexer-client.h
%-glue.h: $(top_srcdir)/data/dbus/%.xml
Modified: trunk/src/trackerd/tracker-dbus.c
==============================================================================
--- trunk/src/trackerd/tracker-dbus.c (original)
+++ trunk/src/trackerd/tracker-dbus.c Wed Mar 11 11:35:16 2009
@@ -43,8 +43,6 @@
#include "tracker-search-glue.h"
#include "tracker-backup.h"
#include "tracker-backup-glue.h"
-#include "tracker-xesam.h"
-#include "tracker-xesam-glue.h"
#include "tracker-indexer-client.h"
#include "tracker-utils.h"
#include "tracker-marshal.h"
@@ -117,7 +115,7 @@
const char *name,
const char *prev_owner,
const char *new_owner,
- TrackerXesam *self)
+ gpointer *user_data)
{
if (strcmp (name, TRACKER_INDEXER_SERVICE) == 0) {
if (!new_owner || !*new_owner) {
@@ -191,13 +189,6 @@
return FALSE;
}
- /* Register the service name for org.freedesktop.xesam if XESAM is enabled */
- if (tracker_config_get_enable_xesam (config)) {
- if (!dbus_register_service (gproxy, TRACKER_XESAM_SERVICE)) {
- return FALSE;
- }
- }
-
return TRUE;
}
@@ -429,30 +420,6 @@
TRACKER_BACKUP_PATH);
objects = g_slist_prepend (objects, object);
- /* Register the XESAM object if enabled */
- if (tracker_config_get_enable_xesam (config)) {
- object = tracker_xesam_new ();
- if (!object) {
- g_critical ("Could not create TrackerXesam object to register");
- return FALSE;
- }
-
- dbus_register_object (connection,
- gproxy,
- G_OBJECT (object),
- &dbus_glib_tracker_xesam_object_info,
- TRACKER_XESAM_PATH);
- objects = g_slist_prepend (objects, object);
-
- dbus_g_proxy_add_signal (gproxy, "NameOwnerChanged",
- G_TYPE_STRING, G_TYPE_STRING,
- G_TYPE_STRING, G_TYPE_INVALID);
-
- dbus_g_proxy_connect_signal (gproxy, "NameOwnerChanged",
- G_CALLBACK (tracker_xesam_name_owner_changed),
- g_object_ref (G_OBJECT (object)),
- (GClosureNotify) g_object_unref);
- }
/* Reverse list since we added objects at the top each time */
objects = g_slist_reverse (objects);
Modified: trunk/src/trackerd/tracker-main.c
==============================================================================
--- trunk/src/trackerd/tracker-main.c (original)
+++ trunk/src/trackerd/tracker-main.c Wed Mar 11 11:35:16 2009
@@ -68,7 +68,6 @@
#include "tracker-monitor.h"
#include "tracker-processor.h"
#include "tracker-status.h"
-#include "tracker-xesam-manager.h"
#include "tracker-cleanup.h"
#include "tracker-backup.h"
@@ -1068,7 +1067,6 @@
}
tracker_data_manager_init (config, language, file_index, email_index);
- tracker_xesam_manager_init ();
tracker_cleanup_init ();
#ifdef HAVE_HAL
@@ -1157,7 +1155,6 @@
tracker_push_shutdown ();
tracker_cleanup_shutdown ();
- tracker_xesam_manager_shutdown ();
tracker_dbus_shutdown ();
tracker_db_manager_shutdown ();
tracker_db_index_manager_shutdown ();
Modified: trunk/src/trackerd/tracker-search.c
==============================================================================
--- trunk/src/trackerd/tracker-search.c (original)
+++ trunk/src/trackerd/tracker-search.c Wed Mar 11 11:35:16 2009
@@ -1333,14 +1333,13 @@
if (priv->sql_query_iface == NULL) {
priv->sql_query_iface =
- tracker_db_manager_get_db_interfaces_ro (7,
+ tracker_db_manager_get_db_interfaces_ro (6,
TRACKER_DB_CACHE,
TRACKER_DB_COMMON,
TRACKER_DB_FILE_CONTENTS,
TRACKER_DB_FILE_METADATA,
TRACKER_DB_EMAIL_CONTENTS,
- TRACKER_DB_EMAIL_METADATA,
- TRACKER_DB_XESAM);
+ TRACKER_DB_EMAIL_METADATA);
}
result_set = tracker_db_interface_execute_query (priv->sql_query_iface,
Modified: trunk/src/trackerd/tracker-utils.c
==============================================================================
--- trunk/src/trackerd/tracker-utils.c (original)
+++ trunk/src/trackerd/tracker-utils.c Wed Mar 11 11:35:16 2009
@@ -28,7 +28,6 @@
#include "tracker-utils.h"
#include "tracker-main.h"
-#include "tracker-xesam-manager.h"
gchar *
tracker_get_radix_by_suffix (const gchar *str,
Modified: trunk/tests/Makefile.am
==============================================================================
--- trunk/tests/Makefile.am (original)
+++ trunk/tests/Makefile.am Wed Mar 11 11:35:16 2009
@@ -4,7 +4,6 @@
common \
libtracker-common \
libtracker-db \
- trackerd \
scripts \
tracker-indexer \
- tracker-extract
\ No newline at end of file
+ tracker-extract
Modified: trunk/tests/libtracker-db/Makefile.am
==============================================================================
--- trunk/tests/libtracker-db/Makefile.am (original)
+++ trunk/tests/libtracker-db/Makefile.am Wed Mar 11 11:35:16 2009
@@ -10,7 +10,6 @@
#
# These tests include:
#
-# union-performance
# tracker-db-dbus
# tracker-db-manager-unattach
# tracker-db-manager-attach
@@ -35,29 +34,12 @@
$(QDBM_CFLAGS)
# TEST_PROGS += \
-# union-performance \
# tracker-index-reader \
# tracker-db-dbus \
# tracker-db-manager-unattach \
# tracker-db-manager-attach \
# tracker-db-manager-custom \
#
-# union_performance_SOURCES = \
-# tracker-db-manager-common.h \
-# tracker-db-manager-common.c \
-# union-performance.c
-#
-# union_performance_LDADD = \
-# $(top_builddir)/src/libtracker-common/libtracker-common.la \
-# $(top_builddir)/src/libtracker-db/libtracker-db.la \
-# $(top_builddir)/tests/common/libtracker-testcommon.la \
-# $(SQLITE3_LIBS) \
-# $(QDBM_LIBS) \
-# $(GMODULE_LIBS) \
-# $(GTHREAD_LIBS) \
-# $(GLIB2_LIBS) \
-# -lz
-#
# tracker_db_manager_attach_SOURCES = \
# tracker-db-manager-test-attach.c \
# tracker-db-manager-common.c \
Modified: trunk/tests/libtracker-db/tracker-db-manager-test-attach.c
==============================================================================
--- trunk/tests/libtracker-db/tracker-db-manager-test-attach.c (original)
+++ trunk/tests/libtracker-db/tracker-db-manager-test-attach.c Wed Mar 11 11:35:16 2009
@@ -87,27 +87,6 @@
}
-static void
-test_creation_xesam_db_no_reindex_multiple_interfaces ()
-{
- TrackerDBInterface *iface;
-
- ensure_db_manager_is_reindex (FALSE);
-
- iface = tracker_db_manager_get_db_interfaces (2,
- TRACKER_DB_XESAM,
- TRACKER_DB_COMMON);
-
- test_assert_query_run_on_iface (iface, "SELECT * FROM XesamServiceTypes");
-}
-
-
-static void
-test_creation_xesam_db_no_reindex ()
-{
- ensure_db_manager_is_reindex (FALSE);
- test_assert_tables_in_db (TRACKER_DB_XESAM, "SELECT * FROM XesamServiceTypes");
-}
static void
test_creation_file_meta_db_no_reindex ()
@@ -138,12 +117,6 @@
g_test_add_func ("/libtracker-db/tracker-db-manager/attach/no-reindex/common_db_tables",
test_creation_common_db_no_reindex);
- g_test_add_func ("/libtracker-db/tracker-db-manager/attach/no-reindex/xesam_db_tables",
- test_creation_xesam_db_no_reindex);
-
- g_test_add_func ("/libtracker-db/tracker-db-manager/attach/no-reindex/xesam_db_tables/multiple_interfaces",
- test_creation_xesam_db_no_reindex_multiple_interfaces);
-
g_test_add_func ("/libtracker-db/tracker-db-manager/attach/no-reindex/file_meta_db_tables",
test_creation_file_meta_db_no_reindex);
Modified: trunk/tests/libtracker-db/tracker-db-manager-test-custom.c
==============================================================================
--- trunk/tests/libtracker-db/tracker-db-manager-test-custom.c (original)
+++ trunk/tests/libtracker-db/tracker-db-manager-test-custom.c Wed Mar 11 11:35:16 2009
@@ -44,18 +44,6 @@
}
-static void
-test_custom_xesam_no_common ()
-{
- TrackerDBInterface *iface;
-
- iface = tracker_db_manager_get_db_interfaces (1,
- TRACKER_DB_XESAM);
-
- test_assert_tables_in_db (iface, "SELECT * FROM XesamMetaDataTypes");
-}
-
-
int
main (int argc, char **argv) {
@@ -74,9 +62,6 @@
g_test_add_func ("/libtracker-db/tracker-db-manager/custom/common_filemeta_filecontents",
test_custom_common_filemeta_filecontents);
- g_test_add_func ("/libtracker-db/tracker-db-manager/custom/xesam_no_common",
- test_custom_xesam_no_common);
-
result = g_test_run ();
/* End */
Modified: trunk/tests/libtracker-db/tracker-db-manager-test-unattach.c
==============================================================================
--- trunk/tests/libtracker-db/tracker-db-manager-test-unattach.c (original)
+++ trunk/tests/libtracker-db/tracker-db-manager-test-unattach.c Wed Mar 11 11:35:16 2009
@@ -82,7 +82,6 @@
g_test_add_func ("/libtracker-db/tracker-db-manager/unattach/common_db_tables",
test_creation_common_db);
- // XESAM is not available
g_test_add_func ("/libtracker-db/tracker-db-manager/unattach/cache_db_tables",
test_creation_cache_db);
Modified: trunk/tests/scripts/dummy_data_start.sh.in
==============================================================================
--- trunk/tests/scripts/dummy_data_start.sh.in (original)
+++ trunk/tests/scripts/dummy_data_start.sh.in Wed Mar 11 11:35:16 2009
@@ -41,14 +41,6 @@
$SQLITE_EXEC $XDG_CACHE_HOME/tracker/email-contents.db < $SCRIPTS_DIR/data/email-contents.sql
-#
-## xesam.db
-#
-
-echo -n xesam.db,
-
-$SQLITE_EXEC $XDG_CACHE_HOME/tracker/xesam.db < $SCRIPTS_DIR/data/xesam.sql
-
mkdir -p $XDG_DATA_HOME/tracker/data
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]