GNOME Bugzilla – Bug 667410
A second instance of the aggregator only fetch a small subset of my contacts
Last modified: 2012-01-09 11:32:05 UTC
Created attachment 204743 [details] test app I get this when running the attached test app: TOTAL 737 individuals CREATE aggregator 0x7e26e0 TOTAL 175 individuals CREATE aggregator 0x879160 TOTAL 175 individuals CREATE aggregator 0x7e20c0 TOTAL 175 individuals CREATE aggregator 0x7e26e0 TOTAL 175 individuals CREATE aggregator 0x879160 TOTAL 175 individuals CREATE aggregator 0x7e20c0 TOTAL 175 individuals CREATE aggregator 0x7e26e0 As you can see only the first instance of the aggregator manages to fetch all my individuals.
Created attachment 204789 [details] [review] Fix multiple aggregator instances sharing a BackendStore This should fix the problem (it does for me). Can you give it a test and see if it fixes the problem for you too? Thanks.
(Branch is here: https://www.gitorious.org/folks/folks/commits/667410-multiple-aggregators)
Yep, seems to work just fine now, thanks!
Comment on attachment 204789 [details] [review] Fix multiple aggregator instances sharing a BackendStore Merged! commit bf8dfa934b1e6fa31818d51a3eba5cbb04a1632b Author: Philip Withnall <philip@tecnocode.co.uk> Date: Fri Jan 6 23:08:10 2012 +0000 telepathy: Keep Tpf.PersonaStore.personas up to date for cached stores When loading a Tpf.PersonaStore from its cache, ensure Personas are inserted into both the set of personas _and_ the map of IIDs to personas. This fixes Tpf.PersonaStore.personas being empty for cached stores. Helps: https://bugzilla.gnome.org/show_bug.cgi?id=667410 backends/telepathy/lib/tpf-persona-store.vala | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) commit d258c86814c0dd4405a8a2b7a45f3d2a036fa1eb Author: Philip Withnall <philip@tecnocode.co.uk> Date: Fri Jan 6 23:05:05 2012 +0000 Bug 667410 — A second aggregator instance only fetches a subset of contacts This was happening because the initial BackendStore was hanging around across multiple IndividualAggregator instances, keeping all the Backends, PersonaStores and Personas alive. The IndividualAggregator didn’t have code to deal with pre-prepared Backends and PersonaStores, meaning it never realised the Personas existed (because they weren’t announced via personas-changed signals), and thus never created Individuals out of them. This commit fixes the problem by having IndividualAggregator check for existing Backends, PersonaStores and Personas when prepare() is called. It also adds a test case to the folks test suite, based on the one written by Guillaume in bgo#667410. Closes: https://bugzilla.gnome.org/show_bug.cgi?id=667410 NEWS | 2 + folks/backend.vala | 10 ++++ folks/individual-aggregator.vala | 50 ++++++++++++++++++++- folks/persona-store.vala | 10 ++++ tests/folks/init.vala | 91 ++++++++++++++++++++++++++++++++++++++ 5 files changed, 161 insertions(+), 2 deletions(-)
*** Bug 657357 has been marked as a duplicate of this bug. ***