Commit Graph

19 Commits

Author SHA1 Message Date
Marc Blank
4b59cfc8ed Fix problem with timeouts and sending attachments (#2178288)
* Standard Exchange command timeouts are 20 seconds
* For sending, however, these need to be significantly longer to
  handle the case of sending large attachments, as sending (of any
  length) happens in a single HTTP Post command
* Having an infinite timeout leads to the (small) possibility of the
  Outbox hanging for a long time, holding up the sending of other
  mail, so we set a long, but not infinite timeout for this case
* Timeout now set for 15 minutes
* Prevent sync of Outbox and Drafts (the UI triggers these by changing
  the contents of these boxes, but we need to ignore the pings that
  are generated this way)

Change-Id: I5b830d6b4e94525d95138b2112be12898a37882e
2009-10-09 11:20:52 -07:00
Marc Blank
3e1c871f04 Fix EAS sending, which was inadvertently broken by a change in EmailProvider
* syncServerId in the Message table can now be NULL; this broke a test
  used by EasOutboxService and SyncManager to determine whether there
  were sendable messages in the Outbox
* Changed test to allow for NULL in syncServerId

Change-Id: Id76c7a45bc306abe7a927ab2395700f54a01a298
2009-09-23 10:52:00 -07:00
Marc Blank
7e89834cfd Fix problem w/ SmartReply & SmartForward in Exchange 2003
* It doesn't like URLEncoded commands; go figure!
* Fixes #2127892

Change-Id: Ibae8cad990ed45accb6699716fda56f45c850939
2009-09-17 15:50:52 -07:00
Marc Blank
0d1f7add7d Add logging to EasOutboxService to help find sending issues
Change-Id: I8188fd2977724ae4ee6a8703098b7068c14b92fd
2009-09-17 15:20:00 -07:00
Marc Blank
2d5691cac1 Support bcc in Exchange (Fixes #2117849)
* Must send the bcc header for EAS

Change-Id: I38d119beed334c6bb23a09b87375804f8c03ea76
2009-09-15 15:18:46 -07:00
Marc Blank
1d98989222 Implement SmartReply/SmartForward for EAS; fixes #2098779
* SmartForward and SmartReply are EAS commands that automatically
  include the original message and, if a forward, all original
  attachments, regardless of whether they've been downloaded to
  the device
* Both commands improve battery life by sending less data; greatly
  so for SmartForward if there are attachments

Change-Id: I12432cd5275a3b54e9a80d5cd59da437c4a086cc
2009-09-14 15:47:38 -07:00
Marc Blank
9178dcc9e9 Fix bugs re: sending via EAS
* Make sure each call to sendMessage returns a proper result code
* Exit outbox sync on irrecoverable errors
2009-08-20 12:05:57 -07:00
Marc Blank
d366346a64 Implement sendMessageStatus callback in EAS
* Change API for callback to include message subject (when msg is isn't valid)
* Update users of callback to add the new argument
* Use API in EasOutboxService to send status messages back to the UI

Still TODO:  Add relevant error codes for sending problems that are not related
to connection or login issues
2009-08-20 09:08:12 -07:00
Marc Blank
f4d7ddb0c2 Fix message sending from EAS (the service wasn't properly set up)
* Cleanup of EasSyncService
2009-08-19 16:09:26 -07:00
Marc Blank
6b52af214c Implement adaptive ping timeout; release wake lock waiting for connectivity
* Remove unused/duplicated classes (e.g. Base64, WbxmlSerializer, etc.)
* Code cleanup in AbstractSyncService, EasSyncService
* Remove last references to HttpURLConnection (using HttpClient now)
2009-08-16 16:40:42 -07:00
Marc Blank
1ba0fd37a1 Cleanup; delete unused files, change log statements
* Two files were unused and therefore deleted
* userLog was changed to avoid using string concatentation until the logging
  decision is made
2009-08-13 11:30:39 -07:00
Andrew Stadler
c640cbbaf3 Update SMTP to send from provider messages, and attachments
* Change Sender definition (remove old Message from API) and update
    any existing calls through that API
* Rewrite SMTPSender to use provider messages
* Add attachments to RFC822Output
* Minor bugfixes in RFC822Output
* Unit tests
2009-08-13 09:31:57 -07:00
Marc Blank
b37b1b4bfe Stream rfc822 messages to a temporary file, and send using an InputStreamEntity
* Removes the need to store the entire outgoing message in memory
2009-08-12 15:35:44 -07:00
Marc Blank
4f195e716c Use new Rfc822Output class for sending mail; fix bug in Rfc822Output
* Change EasOutboxService to use the new Rfc822Output class for sending
* Fix small bug in Rfc822Output (was writing both in Base64 and plain text)
* Fix bug in SyncManager related to auto-starting EAS outbox
2009-08-11 20:07:42 -07:00
Marc Blank
1e7829fb65 Switch from HttpURLConnection to HttpClient 2009-08-08 13:33:41 -07:00
Marc Blank
f00dccd321 Massive reworking of EAS serialization; much smaller and faster now
* Remove all use of Strings in favor of the parser's static final int's
* Strings remain in Tags for debugging output only
* Renamed lots of classes to be more consistent
* Centralized logging behavior in Eas class
* Found and fixed some bugs in the process:
  - Account deletion wasn't removing HostAuth's correctly in the trigger
  - Adding a second EAS account was trashing the first one
  - Fixed looping sync behavior caused by Exchange 2003 bug
2009-08-01 17:55:15 -07:00
Marc Blank
b6493a07ef Major refactor and cleanup of EAS code
* Rewrote push logic to encompass multiple folders (i.e. calendar/contacts)
    * Change inbox from push frequency to ping frequency after initial sync
    * Implement upsync logic for email (i.e. sending changes to the server)
    * Did cleanup of some files (there's still some to do) re: format, style
    * Initial one-way sync of Contacts data - add and delete are implemented
    * Created adapter package for all parts of the EAS adapter
    * Created utility package for utility code that will eventually be merged
      with code in the Email application (Base64, QuotedPrintable, etc.)
    * SyncManager/AbstractSyncService can be used in the future for other
      protocols, especially IMAP push
2009-07-07 00:30:24 -07:00
Marc Blank
09d13e6295 Clean up Exchange code
Clean up imports to point to the com.android.exchange version of EmailContent
Clean up some line wrapping
Update EmailContent with latest version from Email project
2009-06-23 17:59:27 -07:00
Marc Blank
2c67f1f8b8 Initial submission for EAS support (email)
* There is some temporary code ensuring that SyncManager runs (this will be removed when Exchange
is entirely independent)
* The service interface (aidl) is in place for most user-facing actions (load more, start sync, etc.)
* EAS account validation is done via aidl
* Folder and message sync appear to be functional in this early submission
* Provider now does cascading deletes (Account -> HostAuth and Mailbox, Mailbox -> Message,
  Message -> Attachment and Body)
2009-06-23 13:13:42 -07:00