Commit graph

284 commits

Author SHA1 Message Date
Tyna William
c63899834a Tw token users missing events (#13919)
* added missing operations

GitOrigin-RevId: 1492369b7fe290a7953ac8a8f002039fb6a75f10
2023-07-25 08:04:18 +00:00
Miguel Serrano
780e5fdca5 Merge pull request #13522 from overleaf/msm-real-time-remove-token-change
[real-time] Delete 'project:tokens:changed' references

GitOrigin-RevId: b6e5c859ea79ffb41204c53e98726e19f91528d1
2023-07-17 11:09:03 +00:00
Jakob Ackermann
7d836493a0 Merge pull request #13491 from overleaf/jpa-real-time-query-access
[real-time] gracefully access query parameters

GitOrigin-RevId: b29237a6fb20d51bbe5db7ebb429d460b1da29a6
2023-07-17 10:35:10 +00:00
Jakob Ackermann
55c5330108 Merge pull request #13463 from overleaf/jpa-bootstrap-ws
[misc] automatically call joinProject as part of connecting to real-time

GitOrigin-RevId: 2466168e9cebb62dec07481273050efcd0478114
2023-07-17 10:34:25 +00:00
Jakob Ackermann
6d4d643fd9 Merge pull request #13325 from overleaf/jpa-real-time-check
[real-time] add check for project admin

GitOrigin-RevId: 1677b78cf7f263fc98ca539e26e21553d0ea55bd
2023-07-17 10:23:24 +00:00
June Kelly
d68ed0efdf Merge pull request #13140 from overleaf/jk-real-time-disconnect-link-sharing
[real-time] Disconnect relevant users when link-sharing is turned off

GitOrigin-RevId: cf44a30a235717b658a759e8a74ae4d0e5abae47
2023-05-31 08:05:07 +00:00
June Kelly
5d0ce8c4cd Merge pull request #13052 from overleaf/jk-realtime-disconnect-users
[real-time] Disconnect client when user is removed from project

GitOrigin-RevId: e3d31b9192c639b2988e488e34e19050e7caeb4a
2023-05-17 12:04:48 +00:00
Eric Mc Sween
d9e0215aee Merge pull request #12211 from overleaf/em-camel-case-real-time
Camel case variables in real-time

GitOrigin-RevId: 0a35d2e39d54c258bed017ea4dcdbf9a19a2a9b1
2023-03-21 09:05:37 +00:00
Jakob Ackermann
f0bd6dda23 Merge pull request #7986 from overleaf/jpa-eslint-8
[misc] upgrade eslint packages to the latest version everywhere

GitOrigin-RevId: f1480d4a171acef82fb26c4aa54be3a6088b0ab3
2022-05-17 08:05:59 +00:00
June Kelly
e01fbb243b Merge pull request #7081 from overleaf/jk-restricted-user-accept-changes
[real-time] Pass 'accept-changes' messages to restricted clients

GitOrigin-RevId: 66766f08349501d5a63ee45c4d82e1fe72df852f
2022-03-24 14:58:50 +00:00
Brian Gough
f73d5abcf0 Merge pull request #6242 from overleaf/bg-remove-basic-auth-connect
[real-time] remove basic auth connect and default credentials

GitOrigin-RevId: 8dfa9f0859c7d3538f80587a99cffd9c4aea48d1
2022-01-07 09:03:04 +00:00
Eric Mc Sween
f7275a6c4b Merge pull request #6079 from overleaf/em-upgrade-logger
Upgrade logger and metrics in all services

GitOrigin-RevId: 2baf63eeeab77fb3559cf763ddacfbf4b745cd0b
2021-12-15 09:04:25 +00:00
Brian Gough
534cb1c5ab Merge pull request #5661 from overleaf/bg-fix-status-on-restart
[real-time] skip 60s closing delay on start up

GitOrigin-RevId: 5fbb3b4f2940505c2ab6e5cfe6a757ee2501bf2d
2021-11-09 09:03:34 +00:00
Jakob Ackermann
7f9fd00bda Merge pull request #5367 from overleaf/jpa-node-handle-callback-err
[misc] fix eslint violations for node/handle-callback-err

GitOrigin-RevId: 83a4900e8861010df1917bff49382bd9c93375bd
2021-10-28 08:03:26 +00:00
Jakob Ackermann
a6f05109a3 Merge pull request #5352 from overleaf/jpa-no-var
[misc] fix eslint violations for `no-var`

GitOrigin-RevId: c52e82f3a8a993b8662cc5aa56e7b95ca3c55832
2021-10-27 08:03:00 +00:00
Brian Gough
6cece12369 Merge pull request #5109 from overleaf/bg-fix-handshake-exception
fix handshake exception

GitOrigin-RevId: 917518ccac3f5fddf4029f1b1ec3e3806dde9a29
2021-09-16 08:03:08 +00:00
Brian Gough
618cf99548 Merge pull request #4950 from overleaf/bg-realtime-log-relevelling
realtime log re-levelling

GitOrigin-RevId: 81d86ba648e7fc1436b638b67371b35fd831a62f
2021-09-15 08:03:25 +00:00
June Kelly
7b1044b8a8 Merge pull request #4870 from overleaf/jk-bg-validate-ids
RealTime: Validate IDs
GitOrigin-RevId: 884600125d362c5632faa75dc22d957cdddc101b
2021-09-02 08:03:14 +00:00
Jakob Ackermann
b8fcb265b2 [misc] EventLogger: drop explicit metrics.inc amount
The module has a hard-coded increment of 1, which is the only value the
 prometheus backend supports.
2021-07-13 12:40:46 +01:00
Jakob Ackermann
7e8e231059 [misc] run format_fix and lint:fix 2021-07-13 12:04:45 +01:00
Jakob Ackermann
a26ae73597 [misc] switch from settings-sharelatex to @overleaf/settings 2021-07-12 17:47:18 +01:00
Brian Gough
3044bc4cf5 add transport to get-connected-users metric 2021-05-13 14:51:26 +01:00
Brian Gough
9622b341b7 add transport type to metrics 2021-05-10 10:16:50 +01:00
Brian Gough
a3009d2ef2 Merge pull request #210 from overleaf/bg-real-time-status-file
add blue-green deployment support with load-balancer health-checks
2021-04-01 09:09:57 +01:00
Thomas Mees
e63b9ec5ea Lower log level of 'no project_id found on client' messages 2021-03-30 12:40:26 +02:00
Brian Gough
a55aa61d71 use .includes instead of .indexOf 2021-03-29 11:13:59 +01:00
Brian Gough
32184330d9 delay closing by 1 minute for deployment flip 2021-03-22 11:26:02 +00:00
Brian Gough
17e3068499 close real-time via a status file 2021-03-22 10:46:25 +00:00
Henry Oswald
49bed6595d added queueKey to error info when trying to push to redis 2021-02-09 12:42:58 +00:00
Henry Oswald
46b389e8b3 fix off by 1 error in key sharding 2021-02-09 10:48:40 +00:00
Henry Oswald
31e1808dd8 shard the pending-updates-list queue 2021-02-08 16:02:41 +00:00
Jakob Ackermann
746c5aeb80 [misc] bump metrics module to 3.4.1
- renamed package from `metrics-sharelatex` to `@overleaf/metrics`
- drop support for statsd backend
- decaffeinate
- compress `/metrics` response using gzip
- bump debugging agents to latest versions
- expose prometheus interfaces for custom metrics (custom tags)
- cleanup of open sockets metrics
- fix deprecation warnings for header access
2020-11-25 11:57:22 +00:00
Jakob Ackermann
15af5c7977 [misc] bump @overleaf/redis-wrapper to version 2.0.0 2020-11-11 16:24:22 +00:00
Jakob Ackermann
d6ac8c14e7 [RoomManager] drop duplicate joining of entities
REF: 0437e1d03f89a058f97a8884e3532a9a58b68b9d
REF: 62be5e29e5232150e7063bc189c5ad8a1189f972
Signed-off-by: Jakob Ackermann <das7pad@outlook.com>
2020-10-19 15:54:37 +01:00
Jakob Ackermann
c6f2a3b387 Merge pull request #189 from overleaf/jpa-relevel-log
[misc] re-level expected error log messages
2020-09-02 10:46:08 +02:00
Jakob Ackermann
4960bdd6fe [misc] re-level log: 404 from web -> WARN and emit 'project not found'
A stale browser tab tried to join a deleted project.
Emitting 'project not found'/'ProjectNotFound' will trigger a page
 reload in the frontend, upon web can render a 404.
See frontend: ConnectionManager.joinProject callback
2020-08-27 11:51:57 +01:00
Jakob Ackermann
884b340c75 [misc] re-level log: 403 from web goes to WARN and emit 'not authorized'
Users will get redirected to the login page and will see a 'restricted'
 page after logging in again.
See frontend: ConnectionManager.reportConnectionError
2020-08-27 11:51:56 +01:00
Jakob Ackermann
1ff9c1e71b [misc] add the rpc-method into the log context in Router._handleError 2020-08-27 11:51:55 +01:00
Jakob Ackermann
0647abf433 [misc] drop info-log in WebApiManager for joinProject being rate-limited
The CodedError is logged at warn-level in Router._handleError.
2020-08-27 11:51:09 +01:00
Jakob Ackermann
2ce7b36c95 [misc] drop duplicate log line for unauthorized applyOtUpdate calls
The violation is logged in Router._handleError.
2020-08-27 10:22:31 +01:00
Jakob Ackermann
dee4749e6d [misc] re-level log: properly silence unauthorized updateClientPosition 2020-08-27 10:11:40 +01:00
Jakob Ackermann
425052ff91 Merge pull request #187 from overleaf/jpa-o-error-tagging
[misc] migrate to OError tagging/wrapping
2020-08-25 11:46:28 +02:00
Jakob Ackermann
64e659bf43 Merge pull request #186 from overleaf/jpa-fix-join-project-error-context
[misc] fix join project error context
2020-08-25 11:46:18 +02:00
Jakob Ackermann
849a1cf416 Merge pull request #185 from overleaf/jpa-doc-id-in-error-context
[misc] add/bring back doc_id in error context
2020-08-25 11:42:41 +02:00
Jakob Ackermann
ee3d3b09ed [misc] wrap redis errors as tagging does not work with them
ioredis may reuse the error instance for multiple callbacks. E.g. when
 the connection to redis fails, the queue is flushed with the same
 MaxRetriesPerRequestError instance.
2020-08-24 10:12:20 +01:00
Jakob Ackermann
537e97be73 [misc] OError.tag all the errors in async contexts
See the docs of OError.tag:
https://github.com/overleaf/o-error#long-stack-traces-with-oerrortag
(currently at 221dd902e7bfa0ee92de1ea5a3cbf3152c3ceeb4)

I am tagging all errors at each async hop. Most of the controller code
 will only ever see already tagged errors -- or new errors created in
 our app code. They should have enough info that we do not need to tag
 them again.
2020-08-24 10:12:06 +01:00
Jakob Ackermann
8e31cc5c23 [Router] _handleError: joinProject error-context may not have project_id
The ol_context patch changed the priority of client context and rpc
 context.
This lead to the (possibly missing) project_id of the client context
 overwriting the project_id of the rpc context.
REF: f1d55c0a5437a518e9f4617473caed9ba928e648
2020-08-21 13:29:28 +01:00
Jakob Ackermann
f935b1881a [Router] leaveDoc: pass the doc_id into the error-context 2020-08-21 12:47:42 +01:00
Jakob Ackermann
fd88819eec [Router] _handleError: ol_context.doc_id does not exist, drop overwrite 2020-08-21 12:47:42 +01:00
Jakob Ackermann
880056d397 [Router] use a new UnexpectedArgumentsError 2020-08-21 12:47:08 +01:00