Commit graph

106 commits

Author SHA1 Message Date
Ben Gotow 11f19ae648 Fix file attachments / FileUploadStore 2017-06-28 13:37:33 -07:00
Ben Gotow f74fd8324d Remove concept of “account.organizationUnit” since Gmail has folders also 2017-06-27 11:39:43 -07:00
Ben Gotow efbea58e1e Overhaul TaskFactory.tasksForApplyingCategories, fix many specs 2017-06-27 11:31:22 -07:00
Ben Gotow 6cbbd0a3dd Shorten JSON keys to save like…100mb of sqlite space 2017-06-26 23:48:55 -07:00
Ben Gotow ade70d32bd Contact ranking now built into sync, remove separate cache 2017-06-25 17:52:29 -07:00
Ben Gotow 38c6ecea00 Limit number of results shown in search dropdown 2017-06-25 16:38:16 -07:00
Ben Gotow 29e7afce51 FTS5 search indexing is moving to c++ 2017-06-25 10:45:13 -07:00
Ben Gotow ddb7d8d793 react-addons-test-utils => react-dom/test-utils 2017-06-25 01:24:25 -07:00
Ben Gotow bd9983005c Remove deprecations still supported by client 2017-06-25 01:06:54 -07:00
Ben Gotow 555681546d Fix remaining references to draftId => headerMessageId 2017-06-25 00:59:16 -07:00
Ben Gotow 4966ae3650 Draft creation, saving, deletion moved to c++ 2017-06-25 00:46:01 -07:00
Ben Gotow 3c56e2fbfd Remove isomorphic-core and related packages 2017-06-24 20:34:01 -07:00
Ben Gotow f038c97144 Move thread counts logic to c++ 2017-06-24 18:40:41 -07:00
Ben Gotow 0bec5719fd Fetch messages on demand 2017-06-24 02:28:13 -07:00
Ben Gotow 07428a1060 Remove keybase plugin 2017-06-23 18:23:12 -07:00
Ben Gotow 9977c566df Add fonts and sounds for now 2017-06-23 18:22:51 -07:00
Ben Gotow 2d1ce345c3 Get rid of more code no longer needed 2017-06-23 18:08:46 -07:00
Ben Gotow 6aa666837e Break apart category picker into labels vs folders 2017-06-23 18:01:14 -07:00
Ben Gotow a9a57de215 Remove more perf and timing stuff 2017-06-23 16:30:28 -07:00
Ben Gotow 799ccce640 Revert "[client-app] Measure and report inline composer open times + consolidate timers"
This reverts commit f467664bde.

# Conflicts:
#	packages/client-app/src/flux/stores/draft-store.es6
2017-06-23 16:21:28 -07:00
Ben Gotow 2d423eeac3 Revert "[client-app] Measure and report search perf metrics"
This reverts commit aeddc92e8e.

# Conflicts:
#	packages/client-app/internal_packages/thread-search/lib/search-query-subscription.es6
2017-06-23 16:19:55 -07:00
Ben Gotow e5a310ab3e Revert "[client-app] Measure and report app boot time"
This reverts commit 7cd5128db4.

# Conflicts:
#	packages/client-app/internal_packages/onboarding/lib/onboarding-root.jsx
#	packages/client-app/internal_packages/thread-list/lib/thread-list.cjsx
#	packages/client-app/src/browser/application.es6
2017-06-23 16:18:01 -07:00
Ben Gotow 63abbd582c Revert "[client-app] Measure and record times for opening account windows"
This reverts commit feda238d9c.

# Conflicts:
#	packages/client-app/internal_packages/onboarding/lib/onboarding-root.jsx
#	packages/client-app/src/browser/application.es6
2017-06-23 16:17:09 -07:00
Ben Gotow 8288461302 Revert "[client-app] Measure and report time to select and load a thread"
This reverts commit 4c57fcfab4.

# Conflicts:
#	packages/client-app/internal_packages/message-list/lib/message-list.cjsx
2017-06-23 16:12:20 -07:00
Ben Gotow e2f27c3287 Revert "[client-app] Measure and report times for trashing and marking as spam"
This reverts commit 19195e9686.

# Conflicts:
#	packages/client-app/src/flux/actions.es6
#	packages/client-app/src/flux/stores/thread-list-actions-store.es6
2017-06-23 16:11:53 -07:00
Ben Gotow 4540ae1cc6 Revert "[client-app] Measure and report times for removing labels from threads"
This reverts commit 6dbbf1e094.

# Conflicts:
#	packages/client-app/src/flux/actions.es6
#	packages/client-app/src/flux/stores/thread-list-actions-store.es6
2017-06-23 16:11:42 -07:00
Ben Gotow 1642b53c98 Revert "[client-app]: Measure and report time when dragging threads to sidebar"
This reverts commit fb85db0964.

# Conflicts:
#	packages/client-app/internal_packages/account-sidebar/lib/sidebar-item.coffee
#	packages/client-app/internal_packages/thread-list/lib/thread-list-quick-actions.cjsx
#	packages/client-app/src/flux/actions.es6
#	packages/client-app/src/flux/stores/thread-list-actions-store.es6
2017-06-23 16:11:17 -07:00
Ben Gotow 8348bb210c Revert "[client-app] Measure and report times for removing from inbox"
This reverts commit 90e49d31aa.

# Conflicts:
#	packages/client-app/src/flux/actions.es6
#	packages/client-app/src/flux/stores/thread-list-actions-store.es6
2017-06-23 16:10:15 -07:00
Ben Gotow ef9a1b1164 Revert "[client-app] Measure and report archiving times"
This reverts commit a8fbcb0c93.

# Conflicts:
#	packages/client-app/internal_packages/thread-list/lib/thread-list-quick-actions.cjsx
#	packages/client-app/internal_packages/thread-list/lib/thread-list.cjsx
#	packages/client-app/src/flux/actions.es6
#	packages/client-app/src/flux/stores/thread-list-actions-store.es6
#	packages/client-app/src/global/nylas-exports.es6
#	packages/isomorphic-core/src/metrics-reporter.es6
2017-06-23 16:09:29 -07:00
Ben Gotow 0f6fdb4256 Fuck it - tasks don’t performLocal either 2017-06-23 14:57:52 -07:00
Ben Gotow b01f8c485e Remove performRemotes, rip apart TaskQueue 2017-06-22 15:07:04 -07:00
Ben Gotow af1de37b36 Remote worker-ui 2017-06-22 13:38:44 -07:00
Ben Gotow 8076fa5c36 Finish Category => Folder Label, still use single relation table 2017-06-22 02:37:10 -07:00
Ben Gotow 1219182b0a Remove clientId, serverId concept 2017-06-21 13:12:49 -07:00
Halla Moore c6db6c3ae2 [client-app] Re-add imap to the onboarding accounts page
Summary:
Put the IMAP option back on the provider selection page within
onboarding. Also remove the 'hidden' property on account types since I
don't think we'll be using it for any other providers, and remove the
'Add Custom IMAP Account' from the application menu.

Addresses T8097

Test Plan: Manual

Reviewers: spang, mark, juan

Reviewed By: mark, juan

Differential Revision: https://phab.nylas.com/D4402
2017-04-10 15:44:26 -07:00
Christine Spang cfe2971c2e [*] Revamp SSL options (including user-facing)
Summary:
Previously, the generic IMAP auth screen presented one security option to
users: "Require SSL". This was ambiguous and difficult to translate into
the correct security options behind the scenes, causing confusion and problems
connecting some accounts.

This patch does the following:
* Separates security settings for IMAP and SMTP, as these different protocols
  may also require different SSL/TLS settings

* Reworks the generic IMAP auth page to allow specifying security settings
  with higher fidelity. We looked at various different email apps and decided
  that the best solution to this problem was to allow more detailed
  specification of security settings and to ease the burden of more options
  by having sane defaults that work correctly in the majority of cases.
  This new screen allows users to pick from "SSL / TLS", "STARTTLS", or "none"
  for the security settings for a protocol, and also to instruct us that
  they're OK with us using known insecure SSL settings to connect to their
  server by checking a checkbox.

  We default to port 993 / SSL/TLS for IMAP and port 587 / STARTTLS for SMTP.
  These are the most common settings for providers these days and will work
  for most folks.

* Significantly tightens our default security. Now that we can allow folks to
  opt-in to bad security, by default we should protect folks as best we can.

* Removes some now-unnecessary jank like specifying the SSLv3 "cipher"
  in some custom SMTP configs. I don't think this was actually necessary
  as SSLv3 is a protocol and not a valid cipher, but these custom
  configs may have been necessary because of how the ssl_required flag was
  linked between IMAP and SMTP before (and thus to specify different
  settings for SMTP you'd have to override the SMTP config).

* Removes hard-coding of Gmail & Office365 settings in several
  locations. (This was a major headache while working on the patch.)

This depends on version 2.0.1 of imap-provider-settings, which has major
breaking changes from version 1.0. See commit for more info:
9851054f91

Among other things, I did a serious audit of the settings in this file and
"upgraded" a few servers which weren't using the SSL-enabled ports for their
provider to the secure ones. Hurray for nmap and openssl.

Test Plan: manual

Reviewers: evan, mark, juan, halla

Reviewed By: juan, halla

Differential Revision: https://phab.nylas.com/D4316
2017-04-05 17:49:43 -07:00
Evan Morikawa 4904a9ae85 [client-app] Updates to feature limiting
This is a squash of a bunch of commits releated to feature limiting.
Includes making the upgrade path seamless by accessing billing through a
WebView and making sure that the feature is enabled after upgrading, or
canceled if the upgrade path is stopped by the user in any way.

Included diffs
---------------
Differential Revision: https://phab.nylas.com/D4078
Differential Revision: https://phab.nylas.com/D4136
Differential Revision: https://phab.nylas.com/D4137
Differential Revision: https://phab.nylas.com/D4143
Differential Revision: https://phab.nylas.com/D4147
Differential Revision: https://phab.nylas.com/D4171
Differential Revision: https://phab.nylas.com/D4173
2017-04-05 16:02:53 -07:00
Juan Tejada d1b81b6afe [client-app] Prevent from making any requests when NylasID isn't present
Summary:
Sometimes, when logging out of your NylasID and restarting the app, we
would continue making some requests from the worker window that required a
NylasID. This would make the app enter a restart loop and become
completely unresponsive because when we made a request without a
NylasID, we would force the user to log out and restart the app, and
then we would again make the requests without the id, ad infinitum.

To fix this, we make sure we have a NylasID before making any requests
that require it

Test Plan: manual

Reviewers: halla, evan

Reviewed By: halla, evan

Differential Revision: https://phab.nylas.com/D4344
2017-04-04 16:26:32 -07:00
Mark Hahnenberg e06f729275 [client-app] Limit search to focused perspective
Summary:
Previously we would always search all mail. Now, if the user has focused
a particular folder we will limit our search to that folder. The inbox
is an exception--it will always search all mail unless the user
explicitly uses an "in:" clause.

Test Plan: Run locally, verify that searching folders returns the correct results.

Reviewers: evan, spang, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4328
2017-04-04 12:48:04 -07:00
Evan Morikawa 368201f334 [client-app] add feature limits to reminders and send later
Summary:
This adds feature limit modals (graphics pending) for reminders and send
later

Test Plan: manual

Reviewers: juan, halla

Reviewed By: halla

Differential Revision: https://phab.nylas.com/D4322
2017-04-03 15:38:47 -07:00
Evan Morikawa 96685bed01 [client-app] don't override existing bodies on K2
Summary:
Bodies that already exist on K2 shouldn't be overridden.
See the comment for how this caused open/link tracking to fail in certain
cases when a lot of messages were being sent

Test Plan: manual

Reviewers: halla, mark, spang, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4319
2017-03-31 16:13:52 -07:00
Mark Hahnenberg f6a0ead259 [client-app] Remove getUnindexedAccounts
Summary: It was really slow, and we no longer need it.

Test Plan: Run locally, verify that we no longer do that super slow query

Reviewers: evan, spang, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4312
2017-03-31 14:49:31 -07:00
Juan Tejada 58cf02a824 [client-app] Don't hit contact rankings endpoint until account is ready
Summary:
This prevents us from hitting the endpoint before the database for that
account is initialized and it's actually syncing.

Before this commit, we would throw errors upon adding an account

Test Plan: manually add, remove accounts, run benchmark script

Reviewers: mark, halla, evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D4305
2017-03-31 11:21:56 -07:00
Evan Morikawa b72e0829f2 [client-app] Add silent flag to DB persists for thread indexing
Summary:
Every persistModel would trigger a large number of downstream updates.
These weren't necessary for thread indexing and causing a lot of
unnecessary DB thrashing. This adds a `silent` flag to `persistModel` and
its ilk that just does the write.

significantly improve performance, and also contribute to T8046

Test Plan: manual

Reviewers: spang, mark, halla, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4295
2017-03-30 09:36:07 -07:00
Mark Hahnenberg df1acb84b1 [client-app] Fix thread reindexing loop
Summary:
We would mark modified threads for reindexing, the thread search indexer
would reindex them, which would trigger a notification that the thread
had been modified, so we would mark the thread for reindexing, ...

Now we keep track in memory of which threads we've marked for reindexing
so we avoid re-marking them when the update notification arrives later.

Test Plan:
Run locally, verify same threads aren't getting continuously
reindexed and that the in-memory set doesn't grow unboundedly

Reviewers: spang, juan, evan

Reviewed By: juan, evan

Differential Revision: https://phab.nylas.com/D4289
2017-03-29 17:00:40 -07:00
Mark Hahnenberg 69aa71e575 [client-app] Reindex threads when they're updated
This commit is the same as 7d409f5.

This commit was accidentally reverted in 95ec679, because I (juan) was being
dumb. So I'm re-committing here.

Summary:
We weren't doing that, so we would have accurate search index info for
threads when they were, e.g., moved to another folder.

Test Plan: Run locally

Reviewers: spang, evan, juan

Reviewed By: evan, juan

Differential Revision: https://phab.nylas.com/D4260
2017-03-29 11:55:28 -07:00
Juan Tejada ca50e6cf52 [client-sync] Make sure to attach route files ending in .es6 to local-api
Summary:
This prevented the /health endpoint from being available in the
local-api

Test Plan: manual

Reviewers: mark, halla

Reviewed By: halla

Differential Revision: https://phab.nylas.com/D4280
2017-03-28 17:50:59 -07:00
Mark Hahnenberg 60e6113f87 [client-sync] Implement the /contacts/rankings endpoint
Summary:
Prior to Nylas Mail, the Nylas Cloud API provided an endpoint that
returned rankings for contacts which it computed based on how frequently
and how recently a user sent mail to a recipient. This diff reimplements
that functionality in Nylas Mail. This should improve contact
auto-complete when composing emails to frequently contacted recipients.

Test Plan: Run locally, verify that frequent contacts are suggested earlier

Reviewers: spang, evan, juan

Reviewed By: evan, juan

Maniphest Tasks: T7948

Differential Revision: https://phab.nylas.com/D4253
2017-03-28 10:51:24 -07:00
Halla Moore 4ad4596e2f [client-app, client-sync] Add specs for detecting stuck sync/worker window
Summary: See title. Part of T7681.

Test Plan: ran the specs

Reviewers: evan, mark, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4264
2017-03-27 15:45:33 -07:00
Halla Moore 73f0f3eeda [client-app] Detect when the worker window is unavailable
Summary:
Periodically ping client-sync's /health endpoint and store the latest
sync activity. If we get an ECONNREFUSED error, the worker window is
unavailable. Report the last known activity and restart the worker
window. Part of T7681.

Test Plan: manual, specs

Reviewers: evan, mark, juan

Reviewed By: juan

Differential Revision: https://phab.nylas.com/D4263
2017-03-27 15:42:18 -07:00