Commit graph

89 commits

Author SHA1 Message Date
Alex Hart
ca36eaacce Add support for separate story view receipt control.
This reverts commit 1046265d23.
2022-10-20 21:52:54 -04:00
Nicholas Tinsley
b9f4dc3fe9 Specify exported status and PendingIntent mutability.
Also reduce shake sampling frequency, add coarse location permission.
Random things for targetSdk 32.
2022-09-28 11:33:35 -04:00
Cody Henthorne
3252871ed5 Replace prekey jobs with one overall sync job. 2022-08-18 16:01:05 -04:00
Greyson Parrelli
c6be427883 Add support for resending badly-encrypted stories. 2022-08-18 09:27:20 -03:00
Greyson Parrelli
df3399bde5 Remove processing of inbound GV1 messages. 2022-08-02 14:36:29 -04:00
Greyson Parrelli
04cf8676cc Remove concept of 'highTrust' that is no longer necessary. 2022-07-11 13:35:53 -03:00
Alex Hart
ebc556801e Ensure story media is only uploaded once. 2022-06-29 15:32:25 -04:00
Greyson Parrelli
1446af97a2 Use newer CellService observer when possible. 2022-04-26 12:15:50 -04:00
Cody Henthorne
ac9257ec1c Revert "Track inconsistencies between new and old network availability for internal users."
This reverts commit 007975e7da.
2022-03-28 19:07:20 -04:00
Cody Henthorne
403958fed3 Handle 1:1 call reconnecting events. 2022-03-28 19:07:20 -04:00
Greyson Parrelli
142979ce93 Add job to clean up early message receipts. 2022-03-28 19:07:20 -04:00
Cody Henthorne
007975e7da
Track inconsistencies between new and old network availability for internal users. 2022-03-21 17:21:42 -04:00
Cody Henthorne
7e6fcb80a3
Revert all new network detection API usage and refactorings. 2022-03-21 12:21:46 -04:00
Cody Henthorne
f91494f813 Remove newer network detection APIs. 2022-03-17 16:02:43 -04:00
Greyson Parrelli
8bb27b60fa Revert "Fix data race preventing some story sends."
This reverts commit cde70269817464880ddb8e2c67e59ca8b571073b.
2022-03-17 16:02:42 -04:00
Alex Hart
8c7b6293fb Fix data race preventing some story sends. 2022-03-17 12:12:56 -04:00
Greyson Parrelli
057231b9c3 Update libsignal-client to 0.14.0 2022-03-17 12:12:56 -04:00
Greyson Parrelli
c7016aa462 Fallback to legacy network detection. 2022-03-15 11:28:31 -04:00
Greyson Parrelli
a484d48377
Update network connectivity observer to be more optimistic. 2022-03-10 11:21:21 -05:00
Cody Henthorne
92978b0e3f Fix permission crash with new networking check on API<23. 2022-02-02 19:40:22 -05:00
Cody Henthorne
f091502949 Use newer APIs for detecting network changes. 2022-02-02 16:50:58 -05:00
Rashad Sookram
35d0f1fc8c Revert "Fix dynamic language override for app context."
This reverts commit 75a19ada23f4fc0d5111fb74d234c7c6f48ba503.
2022-01-24 12:05:29 -05:00
Rashad Sookram
fd6a2c6b10 Fix dynamic language override for app context.
Fixes #11889
2022-01-24 12:04:48 -05:00
Cody Henthorne
bfdedd57d1
Update jumbomoji processing and downloading. 2022-01-21 10:31:43 -05:00
Brian Moyer
79d73c9e74 Fix WiFi SMS setting.
Fixes #11898
2022-01-18 10:43:38 -05:00
Greyson Parrelli
5c27842a01 Include queue in job logs. 2022-01-03 11:28:10 -05:00
Greyson Parrelli
843ed24bbb
Introduce SignalDatabase as the main database entrypoint. 2021-11-18 12:36:52 -05:00
Greyson Parrelli
51c86cab10 Add the ability to get the current state of a job. 2021-11-12 10:57:01 -04:00
Alex Hart
ca24682366
Fix a bunch UX bugs for donor badges. 2021-11-11 13:46:38 -04:00
Greyson Parrelli
049ba6a706 Remove WorkManager migration that is no longer necessary.
We migrated away from WorkManager over 2 years ago. We needed it at the
time because we wanted to migrate jobs that were scheduled on
WorkManager into the new system. However, at this point, the user's
client would have been expired for 2 years at the point of upgrade, and
there wouldn't be any jobs that need migrating.
2021-11-04 17:00:04 -04:00
Greyson Parrelli
c06fb81490 Render better crash stack traces for executors. 2021-11-04 17:00:04 -04:00
Greyson Parrelli
665d9e31f6 Separate thread updates into a job and other perf improvements. 2021-08-24 16:59:09 -03:00
Cody Henthorne
2830132b24 Reduce time to start PushTextSendJob. 2021-08-03 13:45:30 -03:00
Greyson Parrelli
58b070e6e3 Fix job info log formatting. 2021-06-25 17:25:59 -04:00
Greyson Parrelli
f19033a7a2 Implement the message send log for sender key retries. 2021-06-24 16:36:13 -04:00
Alex Hart
08a3bc457e Fix autodownload constraint. 2021-05-13 12:00:24 -04:00
Greyson Parrelli
31e1c6f7aa Handle 428 rate limiting. 2021-05-05 16:47:13 -04:00
Alex Hart
85e0e74bc6 Add support for OTA emoji download. 2021-05-03 14:02:58 -04:00
Greyson Parrelli
b053fbc4a7 Use Log.tag where appropriate. 2021-03-31 16:02:32 -03:00
Alan Evans
d83c3d35eb Ensure Job factories pass the parameters to their created Jobs. 2021-03-16 10:07:21 -03:00
Cody Henthorne
dc9b8169c0 Make thread related utility methods available for use in all modules. 2021-03-02 11:07:04 -05:00
Greyson Parrelli
8950100bd7
Decrypt and process messages all in one transaction.
Giddy up
2021-02-23 18:34:18 -05:00
Greyson Parrelli
69a1fa0d3c Remove database transaction protections for job manager interactions.
Now that the JobDatabase is a separate physical database, we no longer
have to worry about people enqueuing jobs while in a transaction.
2021-02-20 14:45:36 -05:00
Greyson Parrelli
dda0e0393e Ensure a job has a context before we fail it. 2021-02-11 11:43:21 -05:00
Greyson Parrelli
158f3d898f Fail an enqueued job if its dependencies already failed.
This was a bug that was most notable during the attachment pre-upload
process: if an attachment failed to upload, the subsequently-enqueued
PushMediaSendJob would still send. This is because the attachment jobs
were enqueued first and failed *before* we enqueued the PushMediaSendJob
as a dependency.

This will use the JobTracker to determine if a dependency already failed
at the time of enqueueing a job like this. This isn't perfect, because
the JobTracker is memory-only and has a limited buffer (currently 1000),
but in practice this should be sufficient for our use cases. I imagine
it'd only fall apart if we somehow  enqueued a dependent job *much*
later, or somehow enqueued it based on a job ID that we persisted on
disk through an app restart. We don't do any of these things, currently,
and probably never should.

Also took the opportunity to patch a case where we weren't failing
dependent jobs when canceling a job, since I was giving the failure
stuff a look-over.
2021-02-10 15:21:03 -05:00
AsamK
8f51bdcb78 Adapt maxInstancesForQueue to only consider instances of the same job.
Currently the maxInstancesForQueue limit checks the count of all jobs in a
given queue. If there are already too many jobs, the new job is discarded.

However this is not the expected behavior for the two jobs where it's used:
GroupCallPeekWorkerJob and AutomaticSessionResetJob
For both the expected behavior is that there aren't too many jobs of them
started, but that there will be at least one instance of them started.
Both of them use the same queue as the PushProcessMessageJob and the MarkerJob.
Those two jobs are often in the queue at the same time, effectively preventing
the GroupCallPeekWorkerJob and AutomaticSessionResetJob from being enqueued.
2021-02-08 14:26:59 -05:00
Greyson Parrelli
1d83729e6c Move backoff calculation into jobs. 2021-01-28 18:44:04 -05:00
Alan Evans
b077c9b4f3
Only schedule one job per constraint set. 2021-01-19 17:07:32 -04:00
Greyson Parrelli
8f7fe5c3ee Add jitter to job exponential backoff. 2021-01-16 03:41:29 -05:00
Greyson Parrelli
93e9dd6425 Feature flag the default max backoff interval. 2021-01-16 03:06:54 -05:00