Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 30965fed authored by Kweku Adams's avatar Kweku Adams
Browse files

Update time window message.

Update the short time window exception message to explain why the window
is a problem so developers can make changes more appropriately than just
setting the value to the minimum.

Bug: 311402873
Test: N/A
Change-Id: Ia01f4da1454566457196fff496ad9aa0a763d06f
parent 08d765d4
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -2354,9 +2354,9 @@ public class JobInfo implements Parcelable {
                if (maxExecutionDelayMillis - windowStart < MIN_ALLOWED_TIME_WINDOW_MILLIS) {
                    if (enforceMinimumTimeWindows
                            && Flags.enforceMinimumTimeWindows()) {
                        throw new IllegalArgumentException("Jobs with a deadline and"
                                + " functional constraints cannot have a time window less than "
                                + MIN_ALLOWED_TIME_WINDOW_MILLIS + " ms."
                        throw new IllegalArgumentException("Time window too short. Constraints"
                                + " unlikely to be satisfied. Increase deadline to a reasonable"
                                + " duration."
                                + " Job '" + service.flattenToShortString() + "#" + jobId + "'"
                                + " has delay=" + windowStart
                                + ", deadline=" + maxExecutionDelayMillis);