[Kde-pim] Akonadi Nepomuk Email Searching
Andras Mantia
amantia at kde.org
Sat Dec 8 22:13:48 GMT 2012
Hi,
Vishesh Handa wrote:
> Hey Laurent
>
> Over the last couple of weeks, I've slowly started learning more about
> Akonadi, and I've started using it. The good/bad news is that I have
> started experiencing all the issues people complain about, so hopefully I
> can fix them.
>
> I tried to search for an email using kmail, and it worked out fine.
> However, I notice that kmail remembers some of the searches that were
> performed. I know it uses the QueryServiceClient for this, I however
> cannot find the relevant code. Could you perhaps point me towards it?
>
> The way the QueryServiceClient is used is bad, cause we (Nepomuk) land up
> re-running the query each time an email is indexed. That makes virtuoso
> consume more cpu.
I'm not that familiar with the searches, but by looking at the code:
- when a search performed a virtual collection is created with the search
query
- this is done using Akonadi::SearchCreateJob
(kdepimlibs/akonadi/searchcreatejon.cpp)
- the above triggers the virtual collection creation in the Akonadi server.
See akonadi/server/src/handler/searchpersistent.cpp
- when a search is performed inside Akonadi, it goes through the
akonadi/server/src/handler/search.cpp. That uses a class called
NepomukSearch that uses the QueryServiceClient you mentioned.
What I don't know is how/when the virtual collection's content is updated.
I hope this gives you some clue where to look for the code your searching
for.
Andras
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/
More information about the kde-pim
mailing list