2008/4/24 Jerry Tan <[EMAIL PROTECTED]>: > also, there is one tool called xesam-glib, > > worth to take a look. >
Infact I also wrote that :-) Also I am going to put in some generic server code in xesam-glib (there is already some, see [1]) anyway. And I am wondering how much I can share with Tracker.I don't think that it is mission critical for any of us to have collaboration between xesam-glib and Tracker, but I think we can make it work. But as we all know the devil is in the details and Tracker might just not fit nicely into a generic framework (considering live searchers and performance/scalability things tend to get complex). Here are my thoughts: The core of xesam-glib is the XesamGSearcher[2] interface which maps 1-1 to the Xesam API except that it is GLib based (it is async with callbacks and GErrors). If you implement a XesamGSearcher you can pass it to a stub class (provided by xesam-glib) and have it magically exported over the bus. On the client side of tings my XesamGSession object takes a XesamGSearcher to talk to in the constructor. Xesam-glib then provides a proxy searcher XesamGDBusSearcher that will be the default searcher for Session objects. This is an incredibly powerful setup if I should flatter myself a bit :-) I can pass in custom (in-process, networked, avahi, bluetooth, wotnot XesamGSearchers) to my Sessions. To top this I am going to provide an aggregated XesamGSearcher that talks to a collection of XesamGSearchers and exposes it as a single XesamGSearcher. Say hello deskbar-on-crack. Xesam-GLib will provide a set of helper classes and interfaces for implementing XesamGSearchers. * Session/Search management This is completely generic. The catch is that we have to monitor for clients dropping of the bus (to close their sessions). Functionality like this is also easily encapsulated and shared in a lib. * Query construction and parsing This can also be made generic. My plan is to have a QueryParser class and a QueryBuilder interface. The parser saxes through the query xml and invokes methods on the builder. Depending on the implementation, the builder could emit a SQL-, Lucene- or Xapian query, or a GObject-domlike-tree modeling the query. Same approach will work on the user search language. * Ontology handling Parsing and querying of the ontology. It is not rocket science, but it is not exactly thrilling to write either. Any thoughts? Cheers, Mikkel [1]: http://www.grillbar.org/wordpress/?p=265 [2]: http://xesam.org/people/kamstrup/xesam-glib/docs-0.2/reference/html/xesam-glib-xesam-g-searcher.html > > > Hackers! Ping > > > > A group of people, including myself, have started a branch called > > "xesam-support" where we are doing an attempt at adding support for > > Xesam in the trackerd service. > > > > We branched from the indexer-split branch where all the cool new DBus > > things are being done by people like frade, martyn and garnacho. > > > > http://svn.gnome.org/svn/tracker/branches/xesam-support > > > > http://svn.gnome.org/svn/tracker/branches/indexer-split > > > > Interesting new files: > > > > Types that represent a Xesam Session and a Xesam Search: > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-session.c > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-session.h > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-live-search.h > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-live-search.c > > > > The glib-dbus DBus proxy type (sorry for the confusion between "Search" > > and "LiveSearch" (above), we decided on this name because of consistency > > with the existing TrackerDBusSearch for /org/freedesktop/Tracker/Search. > > This one serves as object for /org/freedesktop/xesam/Search (which is > > consistent in naming within the existing infrastructure of trackerd's > > code) > > > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-search.c > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam-search.h > > > > Some global API: > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam.c > > > http://svn.gnome.org/svn/tracker/branches/xesam-support/src/trackerd/tracker-xesam.h > > > > > > In the code, you'll notice that we aligned the Xesam specification > > documentation for http://xesam.org/main/XesamSearchAPI to the types > > TrackerXesamSearch 's and TrackerXesamSession 's gtk-doc comments. This > > will make it more easy to get their implementations right and according > > to spec. > > > > There are "todo" markers and "not-sure" markers in the current code. > > > > SO ... if you feel a sudden urge to just go for it, and help us with the > > effort of getting it done: you are absolutely more than welcome. Meet us > > (otella, pvanhoof, martyn, garnacho, frade, konttori) on #tracker at > > irc.gimpnet.org. > > > > Just svn co http://svn.gnome.org/svn/tracker/branches/xesam-support or > > svn co svn+ssh://svn.gnome.org/svn/tracker/branches/xesam-support > > > > ... and start coding! > > > > > > > > _______________________________________________ > tracker-list mailing list > [email protected] > http://mail.gnome.org/mailman/listinfo/tracker-list > _______________________________________________ tracker-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/tracker-list
