Merge commit '14812a50a8cacd1166cd2b0d0be0bf2bbeec662c' into froyo-plus-aosp
* commit '14812a50a8cacd1166cd2b0d0be0bf2bbeec662c':
Workaround for IllegalArgumentException in SyncManager
* There is a race condition in which the AccountManager listener
isn't properly unregistered when SyncManager is shut down
* In this case, SyncManager tries to register a new listener
(i.e. registering again), which causes an IllegalArgumentException
* The quick workaround is simply to catch and ignore this exception,
as it's really more of a warning than a true error
* A bug will be filed for the underlying issue
Bug: 2631561
Change-Id: I139d24ae045d402d4d8cb006406ef96ccc768566
Merge commit '468fe91dd8d3f7c35a2ecd4187dcc38c2e5ad1cc' into froyo-plus-aosp
* commit '468fe91dd8d3f7c35a2ecd4187dcc38c2e5ad1cc':
Prevent account reconcile from running when service is down
Merge commit '5ab7ec7123b5aa6bc9f8fd7e59d2cdf27d716ef5' into froyo-plus-aosp
* commit '5ab7ec7123b5aa6bc9f8fd7e59d2cdf27d716ef5':
Move a bare string to a resource.
* We were previously storing the user's attendee status in the
SYNC_ADAPTER_DATA column of the Event, but it turns out that
this data isn't available in the Entity we retrieve when
uploading changes to the server
* The result is that we often thought the user's status had
changed when in fact it had not; in these cases, we sent email
to the organizer, often with the wrong information.
* As of this CL, we store the user's attendee status in an
ExtendedProperties row (these values are already exposed in event
entities)
* The logic otherwise remains the same; we now get correct data,
however
Bug: 2638762
Change-Id: Ibe8db90c16b4ca06203f77fd010aa26dde89a556
Merge commit 'f2d43c39b4f46d560b5f9d331dd238be63abfcf2' into froyo-plus-aosp
* commit 'f2d43c39b4f46d560b5f9d331dd238be63abfcf2':
Update unit tests for invitation creation
Merge commit '8ba07285336c34a1fa454b23c9d4c95af020fa00' into froyo-plus-aosp
* commit '8ba07285336c34a1fa454b23c9d4c95af020fa00':
Use timezone in exception ics files
* Exchange seems to require time zone information in ics files containing
event exceptions, although this is NOT the case for iCalendar, and appears
not to conform to VCALENDAR specifications
* This causes exceptions to be placed on the wrong date or perhaps even
ignored, depending on the circumstance
* This CL simply adds time zone information to all exception ics files
Bug: 2640878
Change-Id: Ibc614eb7a2c45e9e782b10be979d9892bbfc0029
* The regression is caused by a check on whether the calendar is
syncable, as determined by the status of the Calendar (via
CalendarProvider2).
* Unfortunately, if there IS no calendar, we were disallowing sync,
which prevents the calendar from being created in the first place
Bug: 2619755
Change-Id: I1e94a129413bdbe9bc9bfb3608d3ca95f23d8dfb
Merge commit 'b5bf09a56d30885f985950faa1daa18e8899c32e' into froyo-plus-aosp
* commit 'b5bf09a56d30885f985950faa1daa18e8899c32e':
Allow more time for HttpPost watchdog timeout
Merge commit 'f7369ad51f0eb2c231715975de13e4af37c58eb4' into froyo-plus-aosp
* commit 'f7369ad51f0eb2c231715975de13e4af37c58eb4':
Shutdown all connections when sync service is hung
Merge commit 'b915c3c018c8c4ba063514c3bd9ce05d3f08aa93' into froyo-plus-aosp
* commit 'b915c3c018c8c4ba063514c3bd9ce05d3f08aa93':
Skip security check when account id is unknown.
* The current timeout is triggering more often than it should, which
causes delays and inefficiency. Increase it from 10 to 30 seconds.
Bug: 2615293
Change-Id: I54b74cc7ad9f1c8286af49b957584670c071640c
* When a sync thread receives an alarm due to a missed socket timeout
on an HttpPost, we try to abort the HttpPost.
* At times, however, the HttpPost cannot be aborted and the thread
hangs indefinitely.
* In this CL, we try to break this vicious cycle by shutting down our
ClientConnectionManager when this case is detected. This should, in
turn, close all of our socket connections, causing the sync threads
to generate IOExceptions and terminate.
* After appropriate IOException waits, new sync threads should then be
able to run normally.
Bug: 2615293
Change-Id: Idea6c3653cd60822d6260e0c5a7dad790ee25858
Doing the check caused:
IllegalArgumentException: Unknown URI content://com.android.email.provider/account/-1
at com.android.email.provider.EmailProvider.query(EmailProvider.java:1092)
at android.content.ContentProvider$Transport.query(ContentProvider.java:163)
at android.content.ContentResolver.query(ContentResolver.java:245)
at com.android.email.activity.MessageList.isSecurityHold(MessageList.java:1146)
Bug 2635060
Change-Id: I80e7c00ef2dd74ceae24a88daf43a0681124a9d4
* When SyncManager starts up, it reconciles the AccountManager sync settings
with its own
* This works for Contacts, but Calendar has a second setting that needs to be
checked - the sync_events column in the Calendar table (in CalendarProvider2)
* Before turning on Calendar sync, we now check this second setting; if
sync_events is 0, we won't re-enable Calendar sync
Bug: 2619755
Change-Id: Iea6c99dce228d2c111a529a6c9b865ed1577b19e
Merge commit 'b62cbc7e7b82739c307b5cb3175bbfff5f549295' into froyo-plus-aosp
* commit 'b62cbc7e7b82739c307b5cb3175bbfff5f549295':
Increase service call timeout to 45 seconds
Merge commit '0f68676828d1f66c7997a0457f1c6536e661658f' into froyo-plus-aosp
* commit '0f68676828d1f66c7997a0457f1c6536e661658f':
Fix upsync of DAILY rrule with UNTIL
* When a sync thread triggers an alarm by failing to return from
an HttpPost beyond the socket timeout, we call abort() on the
HttpPost to force it to stop
* It appears that there are cases in which this is insufficient,
and the thread remains hung in a blocked state
* The result of this failure is to prevent the syncing mailbox from
ever syncing again, and is typically seen by a failure to receive
new mail (as reported in the referenced bug)
* In this CL, we add code to wait for 10 seconds after calling the
abort() method. If the HttpPost is still hung, we interrupt() the
thread, and have SyncManager release the Mailbox, so that another
thread can be started.
Bug: 2615293
Change-Id: I6a48195fc68bb950126006326a5b30448d3bbb63
* Make sure we send UNTIL with FREQ=DAILY as appropriate
* Also to help debug this in the future...
Add logging capability to utilities via SyncManager
Add public log methods so that CalendarUtilities can log properly
Change Log.d's to SyncManager.log in CalendarUtilities
Bug: 2623787
Change-Id: I3d651f00a3f7522e25c8d6e389469770c733953f
* Change "broken pipe" behavior to simply run through the ping loop
again, rather than be treated as a NAT timeout
Bug: 2615293
Change-Id: I67c3200f148a8c2beda58f812c29af8a726a4b9c
Merge commit '2f1ce56fc85e8dc7052dc16f58d00bf19b2a9bee' into froyo-plus-aosp
* commit '2f1ce56fc85e8dc7052dc16f58d00bf19b2a9bee':
Fix upload/download of attendee status