gloda indexes while offline, if we startup without a network connection. Suppress indexing on startup without network to conserve battery

RESOLVED FIXED in Thunderbird 3.1b1

Status

MailNews Core
Database
RESOLVED FIXED
8 years ago
3 years ago

People

(Reporter: Bienvenu, Assigned: standard8)

Tracking

({fixed-seamonkey2.0.4, perf, power})

1.9.1 Branch
Thunderbird 3.1b1
x86
All
fixed-seamonkey2.0.4, perf, power

Firefox Tracking Flags

(blocking-thunderbird3.1 beta1+, thunderbird3.1 beta1-fixed, blocking-thunderbird3.0 -, thunderbird3.0 .4-fixed)

Details

(Whiteboard: [battery])

Attachments

(1 attachment)

(Reporter)

Description

8 years ago
gloda relies on getting an online state change notification to suppress indexing while offline (offline is used as a proxy for battery use). If I startup without a network connection, gloda seems to miss or not get the notification.
Keywords: perf
Version: unspecified → 1.9.1 Branch
blocking-thunderbird3.0: --- → ?
(Reporter)

Updated

8 years ago
status-thunderbird3.0: --- → wanted
is this all OS?  (don't have a handy test box ATM)
(Reporter)

Comment 2

8 years ago
probably it's all OS.
OS: Mac OS X → All

Updated

8 years ago
blocking-thunderbird3.0: ? → -
Flags: blocking-thunderbird3.1?
This is likely to be perceived as a regression of sorts by laptop users, so marking as blocking 3.1 and aiming at rc1.
blocking-thunderbird3.1: --- → rc1+
Flags: blocking-thunderbird3.1?
(Assignee)

Comment 4

7 years ago
Created attachment 427114 [details] [diff] [review]
The fix

This just checks the online/offline state when gloda is initialised and sets suppression of indexing if required.

Admittedly I've not done extensive testing to check that this works correctly, but from what I can tell whilst generating the unit test, this does what we expect for this case.
Assignee: nobody → bugzilla
Status: NEW → ASSIGNED
Attachment #427114 - Flags: review?(bugmail)
Comment on attachment 427114 [details] [diff] [review]
The fix

Yes, this is right, thank you.

The unit test didn't need to try and chain off of another set of unit tests; I fixed that and pushed it:
http://hg.mozilla.org/comm-central/rev/768179c0a19d
Attachment #427114 - Flags: review?(bugmail) → review+
Status: ASSIGNED → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → FIXED
I decree this low risk to take on 3.0.x if you want it there too.  (I actually tested this on a 1.9.1 build because everything else is exploding.)
Target Milestone: --- → Thunderbird 3.1b1
(Assignee)

Comment 7

7 years ago
Comment on attachment 427114 [details] [diff] [review]
The fix

Yeah, I thought it was low risk as well. Putting on the list to consider for approvals.
Attachment #427114 - Flags: approval-thunderbird3.0.3?
(Assignee)

Updated

7 years ago
Attachment #427114 - Flags: approval-thunderbird3.0.3? → approval-thunderbird3.0.4?
(Assignee)

Comment 8

7 years ago
Correcting 3.1 flags because this landed in time for beta 1.
blocking-thunderbird3.1: rc1+ → beta1+
status-thunderbird3.1: --- → beta1-fixed
(Assignee)

Comment 9

7 years ago
Comment on attachment 427114 [details] [diff] [review]
The fix

Two people agree this is low risk, so we'll take it on 3.0.4.
Attachment #427114 - Flags: approval-thunderbird3.0.4? → approval-thunderbird3.0.4+
(Assignee)

Comment 10

7 years ago
Checked into 1.9.1: http://hg.mozilla.org/releases/comm-1.9.1/rev/bc021a0272a8
status-thunderbird3.0: wanted → .4-fixed
(Assignee)

Comment 11

7 years ago
For some reason, the test was failing permanently on Windows (on just 3.0), therefore I've backed it out for now and will look again later:

http://hg.mozilla.org/releases/comm-1.9.1/rev/befe8ee0f4e7
status-thunderbird3.0: .4-fixed → ---
(Assignee)

Comment 12

7 years ago
After some testing, we added a change to the unit test to disable automatic management of offline mode (with r=asuth over irc):

http://hg.mozilla.org/comm-central/rev/79666fdca182

Hence now landed on branch as well:

http://hg.mozilla.org/releases/comm-1.9.1/rev/dd3eb945ce6e
http://hg.mozilla.org/releases/comm-1.9.1/rev/b8e06312e645
status-thunderbird3.0: --- → .4-fixed
on Mozilla/5.0 (Windows; U; Windows NT 5.1; gl; rv:1.9.1.9) Gecko/20100317 Thunderbird/3.0.4 I did the following :

 -> deleted the database
 -> Started thunderbird.

Activity manager still one item telling me that we are trying to determine which message to index.Shall I raise a new bug for that ?

Updated

7 years ago
Keywords: fixed-seamonkey2.0.4
Keywords: power
Summary: gloda indexes while offline, if we startup without a network connection → gloda indexes while offline, if we startup without a network connection. Suppress indexing on startup without network to conserve battery
Whiteboard: [battery]
You need to log in before you can comment on or make changes to this bug.