Commit graph

23 commits

Author SHA1 Message Date
Juan Tejada
dce872fac8 Adds bunyan for json logging on every package!
- Bunyan logs json output, and added a stream to send our logs to
cloudwatch
- Replaces /all/ instances of console.log. Turned eslint rule back on,
so we don't use console.log ever again.
- Added npm scripts to view pretty logs
2016-07-08 17:30:24 -07:00
Ben Gotow
14b5bef0a7 Fix error handling on connection close 2016-07-08 16:59:00 -07:00
Juan Tejada
8b1f012a3c Fix error serialization
- Remove cumbersome NylasError
- Add helper to serialize error when saving to account
2016-07-01 15:49:47 -07:00
Juan Tejada
05091a4447 Update thrown errors to use serializable NylasError 2016-07-01 10:24:39 -07:00
Halla Moore
d0666540b9 Added syncback tasks for folders 2016-06-30 11:54:12 -07:00
Ben Gotow
a1419a65a5 Update folderId => folderImapUID, rename messageI to uid 2016-06-30 09:33:04 -07:00
Ben Gotow
b033b94091 Break Category into Folder, Label, populate Gmail lables for messages 2016-06-30 09:29:21 -07:00
Jackie Luo
b3b5a5106c Add endpoint for file downloads 2016-06-29 19:14:04 -07:00
Halla Moore
d3fd671ff6 Update MarkThreadAsRead task 2016-06-29 17:01:30 -07:00
Evan Morikawa
6cb67e417c Fix to use Imap BOX and simplify move helper 2016-06-29 16:25:51 -07:00
Halla Moore
825ce2eba3 Use categoryUID instead of categoryId, change default value to match node-imap 2016-06-29 16:12:29 -07:00
Evan Morikawa
d26824771d Clean up loggin 2016-06-29 12:08:31 -07:00
Halla Moore
bdfee404e5 Add move imap wrapper, make sure wrapper methods are called 2016-06-29 12:07:28 -07:00
Evan Morikawa
7cf59c3c11 Fix retrun value in MoveToFolderIMAP task 2016-06-29 12:04:46 -07:00
Halla Moore
f5af9c0cb5 Added a syncback task to mark a thread as read, untested 2016-06-28 18:13:49 -07:00
Ben Gotow
91887a6e11 Speed up sync by fetching preferred body block only 2016-06-27 16:11:36 -07:00
Juan Tejada
ed749e0f51 Add sync worker error handling
- Handles sync errors in a single place. For now, if error is not a
socket error, will treat as a permanent error, save the error to the
account object, and prevent any other syncing until the error is cleared
from the account object
- Adds a NylasError class that can be extended and serialized. Adds it
to global namespace on all packages and replaces all uses of regular
Error
2016-06-27 16:03:38 -07:00
Juan Tejada
1fe7fdf4b1 More sync error handling WIP 2016-06-27 10:27:38 -07:00
Juan Tejada
63b929e59b Fix missing promise based error handling in sync-worker 2016-06-26 09:52:03 -07:00
Juan Tejada
dd350a5081 Update IMAPConnection api + error handling fixes + misc
- `IMAPConnection::openBox` now returns a Promise that resolves to an
IMAPBox, and IMAPBox contains all of the `fetch` operations. This makes
the dependency between fetch operations and the currently open mailbox
explicit rather than implicit and by forcing the operations to be called on
a box instance and hopefully prevent errors. It will also throw an error
if the constraint is no longer satisfied.

- `fetch` operations now return an observable stream of messages (or Promise for single value),
while preserving the same logic of the original implementation. You can use `.toPromise()` on
the observable to get a Promise that resolves when the observable stream has
completely drained.

- Fixes error handling in a few places and renames some variables
2016-06-26 01:57:33 -07:00
Ben Gotow
69e87cbf49 Gmail auth at http://localhost:5100/auth/gmail 2016-06-24 16:46:41 -07:00
Ben Gotow
09bb7874f8 Dashboard with a sweet background. Also realtime assignment / policy view. 2016-06-23 15:52:53 -07:00
Ben Gotow
f5f435236f /auth + remove hardcoded stub in favor of curl request 2016-06-22 17:19:48 -07:00
Renamed from packages/nylas-sync/imap/connection.js (Browse further)