Commit 42585e89 authored by Sam Thursfield's avatar Sam Thursfield

Revert "miners: Fix tracker-store DBus name watch along miners"

This reverts commit ab29a9cd.

The name watch was correct in the first place. This also
reverts the two cleanup attempts f9e7de0f and 8b6bc5b7.
parent f9e7de0f
Pipeline #33212 passed with stage
in 1 minute and 48 seconds
......@@ -186,7 +186,7 @@ main (gint argc, gchar *argv[])
GDBusConnection *connection;
TrackerMinerProxy *proxy;
TrackerDomainOntology *domain_ontology;
gchar *dbus_name;
gchar *domain_name, *dbus_name;
main_loop = NULL;
......@@ -249,10 +249,17 @@ main (gint argc, gchar *argv[])
main_loop = g_main_loop_new (NULL, FALSE);
if (domain_ontology && domain_ontology_name) {
g_bus_watch_name_on_connection (connection, domain_ontology_name,
/* If we are running for a specific domain, we tie the lifetime of this
* process to the domain. For example, if the domain name is
* org.example.MyApp then this tracker-miner-apps process will exit as
* soon as org.example.MyApp exits.
*/
domain_name = tracker_domain_ontology_get_domain (domain_ontology, NULL);
g_bus_watch_name_on_connection (connection, domain_name,
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL, on_domain_vanished,
main_loop, NULL);
g_free (domain_name);
}
g_message ("Checking if we're running as a daemon:");
......
......@@ -667,7 +667,7 @@ main (gint argc, gchar *argv[])
TrackerMinerProxy *proxy;
GDBusConnection *connection;
TrackerDomainOntology *domain_ontology;
gchar *dbus_name;
gchar *domain_name, *dbus_name;
main_loop = NULL;
......@@ -750,10 +750,17 @@ main (gint argc, gchar *argv[])
main_loop = g_main_loop_new (NULL, FALSE);
if (domain_ontology && domain_ontology_name) {
g_bus_watch_name_on_connection (connection, domain_ontology_name,
/* If we are running for a specific domain, we tie the lifetime of this
* process to the domain. For example, if the domain name is
* org.example.MyApp then this tracker-miner-fs process will exit as
* soon as org.example.MyApp exits.
*/
domain_name = tracker_domain_ontology_get_domain (domain_ontology, NULL);
g_bus_watch_name_on_connection (connection, domain_name,
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL, on_domain_vanished,
main_loop, NULL);
g_free (domain_name);
}
g_message ("Checking if we're running as a daemon:");
......
......@@ -79,7 +79,7 @@ main (int argc, char **argv)
GDBusConnection *connection;
TrackerMinerProxy *proxy;
TrackerDomainOntology *domain_ontology;
gchar *dbus_name;
gchar *domain_name, *dbus_name;
setlocale (LC_ALL, "");
......@@ -218,10 +218,17 @@ main (int argc, char **argv)
loop = g_main_loop_new (NULL, FALSE);
if (domain_ontology && domain_ontology_name) {
/* If we are running for a specific domain, we tie the lifetime of this
* process to the domain. For example, if the domain name is
* org.example.MyApp then this tracker-miner-rss process will exit as
* soon as org.example.MyApp exits.
*/
domain_name = tracker_domain_ontology_get_domain (domain_ontology, NULL);
g_bus_watch_name_on_connection (connection, domain_ontology_name,
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL, on_domain_vanished,
loop, NULL);
g_free (domain_name);
}
g_main_loop_run (loop);
......
......@@ -351,7 +351,7 @@ main (int argc, char *argv[])
GDBusConnection *connection;
TrackerMinerProxy *proxy;
TrackerDomainOntology *domain_ontology;
gchar *dbus_name;
gchar *domain_name, *dbus_name;
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
......@@ -495,10 +495,17 @@ main (int argc, char *argv[])
main_loop = g_main_loop_new (NULL, FALSE);
if (domain_ontology && domain_ontology_name) {
g_bus_watch_name_on_connection (connection, domain_ontology_name,
/* If we are running for a specific domain, we tie the lifetime of this
* process to the domain. For example, if the domain name is
* org.example.MyApp then this tracker-extract process will exit as
* soon as org.example.MyApp exits.
*/
domain_name = tracker_domain_ontology_get_domain (domain_ontology, NULL);
g_bus_watch_name_on_connection (connection, domain_name,
G_BUS_NAME_WATCHER_FLAGS_NONE,
NULL, on_domain_vanished,
main_loop, NULL);
g_free (domain_name);
}
g_signal_connect (decorator, "finished",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment