Last Comment Bug 740637 - Better handling of unexpected failures during info/collections fetch
: Better handling of unexpected failures during info/collections fetch
Status: RESOLVED FIXED
:
Product: Android Background Services
Classification: Client Software
Component: Android Sync (show other bugs)
: unspecified
: ARM Android
: P2 normal
: mozilla14
Assigned To: Richard Newman [:rnewman]
:
Mentors:
Depends on: 740326
Blocks:
  Show dependency treegraph
 
Reported: 2012-03-29 15:51 PDT by Richard Newman [:rnewman]
Modified: 2013-04-04 13:48 PDT (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
fixed
fixed


Attachments

Description Richard Newman [:rnewman] 2012-03-29 15:51:10 PDT
Two things that we didn't do in Bug 740326:

* Kill the cleanup thread when the sync is done.
* Catch exceptions in the background fetch thread.
Comment 1 Nick Alexander :nalexander 2012-03-29 16:22:56 PDT
Tested on top of m-c:

changeset:   90610:ff3521bc6559
tag:         tip
parent:      90526:563ea372f000
parent:      90609:d3cc19901240
user:        Marco Bonardo <mbonardo@mozilla.com>
date:        Thu Mar 29 17:37:31 2012 +0200
summary:     Merge last green PGO from inbound to central

Success:

I SyncAdapter(28016)          Stage completed: ensureClusterURL
I GlobalSession(28016)        Running next stage fetchInfoCollections (org.mozilla.gecko.sync.stage.FetchInfoCollectionsStage@410a2b90)...
D BaseResource(28016)         HTTP GET https://phx-sync433.services.mozilla.com/1.1/lvjppaa3q7cqjbfwmhdvivsekvtfwr3s/info/collections
V BaseResource(28016)         Adding Basic Auth header.
D dalvikvm(28016)             GC_CONCURRENT freed 345K, 6% free 8087K/8583K, paused 3ms+3ms
D BaseResource(28016)         Response: HTTP/1.1 200 OK
W GlobalSession(28016)        Aborting sync: Failure fetching info/collections.
W GlobalSession(28016)        java.lang.IllegalArgumentException: Log tag "SyncStorageResourceDelegate" exceeds limit of 23 characters
W GlobalSession(28016)        
W GlobalSession(28016)        	at android.util.Log.isLoggable(Native Method)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.Logger.shouldLogDebug(Logger.java:84)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.Logger.debug(Logger.java:148)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.Logger.debug(Logger.java:143)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.net.SyncStorageRequest$SyncStorageResourceDelegate.handleHttpResponse(SyncStorageRequest.java:100)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.net.BaseResource.execute(BaseResource.java:253)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.net.BaseResource.go(BaseResource.java:275)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.net.BaseResource.get(BaseResource.java:281)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.net.SyncStorageRequest.get(SyncStorageRequest.java:162)
W GlobalSession(28016)        	at org.mozilla.gecko.sync.InfoCollections$1.run(InfoCollections.java:111)
W GlobalSession(28016)        	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:442)
W GlobalSession(28016)        	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)
W GlobalSession(28016)        	at java.util.concurrent.FutureTask.run(FutureTask.java:137)
W GlobalSession(28016)        	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076)
W GlobalSession(28016)        	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)
W GlobalSession(28016)        	at java.lang.Thread.run(Thread.java:856)
D GlobalSession(28016)        Uninstalling org.mozilla.gecko.sync.GlobalSession@41213340 as BaseResource HttpResponseObserver.
I SyncAdapter(28016)          GlobalSession indicated error. Flagging auth token as invalid, just in case.
I SyncAdapter(28016)          Notifying sync monitor.
I SyncAdapter(28016)          Setting minimum next sync time to 1333063548780
D ConnectionMonitorThread(28016) ConnectionMonitorThread told to shut down.
V BaseResource(28016)         Closing expired connections.
D class ch.boye.httpclientandroidlib.impl.conn.tsccm.ThreadSafeClientConnManager(28016) Closing expired connections
D class ch.boye.httpclientandroidlib.impl.conn.tsccm.ConnPoolByRoute(28016) Closing expired connections
V BaseResource(28016)         Closing idle connections.
D BaseResource(28016)         Shutting down connection manager.
D class ch.boye.httpclientandroidlib.impl.conn.tsccm.ThreadSafeClientConnManager(28016) Shutting down
D class ch.boye.httpclientandroidlib.impl.conn.DefaultClientConnection(28016) Connection closed
D class ch.boye.httpclientandroidlib.impl.conn.DefaultClientConnection(28016) Connection closed
D class ch.boye.httpclientandroidlib.impl.conn.DefaultClientConnection(28016) Connection closed
Comment 2 Richard Newman [:rnewman] 2012-03-29 16:45:18 PDT
Wonderful. Thanks for testing.
Comment 3 Richard Newman [:rnewman] 2012-03-29 16:50:01 PDT
https://hg.mozilla.org/integration/mozilla-inbound/rev/38b752214eaa
Comment 4 Ed Morley [:emorley] 2012-03-30 13:01:29 PDT
https://hg.mozilla.org/mozilla-central/rev/38b752214eaa
Comment 5 Mark Finkle (:mfinkle) (use needinfo?) 2012-04-04 10:10:45 PDT
https://hg.mozilla.org/releases/mozilla-aurora/rev/94bac65543e7

Note You need to log in before you can comment on or make changes to this bug.