summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorJeff Sharkey <jsharkey@android.com>2018-01-19 18:02:47 +0900
committerJeff Sharkey <jsharkey@android.com>2018-01-19 18:18:51 +0900
commit2e4714575ff7aac65a0e107cbf2dd03fa3affe95 (patch)
tree91f96552a4d5769dfe0208bf325db43e47762939 /tools/aapt2/java/JavaClassGenerator_test.cpp
parent9252b34065809731ea2f6d3ffad91f678f809c93 (diff)
Alert user on rapid/heavy data usage.
Now that we have accurate information about a user's carrier data plan, we can alert them if the current usage patterns would end up with a nasty surprise towards the end of the current billing cycle. For example, a single abusive app could use 90% of the user's budget within the first few days of a billing cycle, leaving the user to limp along for the remainder of the month. The simple algorithm here extrapolates to see if the average usage over the last 4 days would be more than 150% of the data limit for the full billing cycle. This period is short enough to catch rapid recent usage, but long enough to smooth over short-term habit changes, such as a weekend getaway. This was chosen after backtesting the proposed algorithm against real-world data usage from a handful of internal users. Fix NPMS unit tests, and write new ones, but leave the existing @Ignored annotation intact for now. Test: bit FrameworksServicesTests:com.android.server.NetworkPolicyManagerServiceTest Bug: 64133169 Change-Id: I0d394b133257e8569a9aa2631b57638839d870ce
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions