Use usage callback to replace the need of intent receiver.
Test: atest TrafficStatsTest NetworkUsageStatsTest FrameworksNetTests
Bug: 204830222
Change-Id: I40967c2b6c86d25c7db93e6d3a4908b72ed76154
Ethernet service related files are going to be moved into Connectivity
module. NetdService won't be visible to EthernetService. Use asInterface
to get the Netd service instead.
Bug: 210586283
Test: m
Change-Id: I3bf504cd947f74bf5830659915483fe5331ac9eb
ethernet-service is going to be moved into Connectivity mainline module.
Notice that below sources are also only used in the ethernet framework
during compiling the filegroup: framework-connectivity-ethernet-sources.
Move them from f/b to f/b/packages/ConnectivityT as well.
Ethernet framework only related files:
- IInternalNetworkManagementListener.aidl
- InternalNetworkManagementException.java
- InternalNetworkManagementException.aidl
- InternalNetworkUpdateRequest.java
- InternalNetworkUpdateRequest.aidl
Ethernet service only related files:
- DelayedDiskWrite.java(IpConfigStore imports this class)
Bug: 210586283
Test: build pass
atest FrameworksNetTests
atest EthernetServiceTests
Change-Id: I1ec2d1d182c04f3f2acc9b757d5061ca749a4a3c
Two reason for renaming:
1. Avoid module name collision in sc-mainline-prod branch.
2. The libnetdbpf was misnamed before.
Bug: 202086915
Test: atest libnetworkstats_test FrameworksNetTests
ConnectivityCoverageTests FrameworksNetSmokeTests
CtsAppOpsTestCases
Change-Id: I87fcf4b1a9d58780a45743a9aa91b9b936e54266
This is a clean copy (that can't build). Modifications will be in
followed commits.
Bug: 202086915
Test: $ diff -r
packages/modules/Connectivity/service-t/native/libs/libnetdbpf/
system/netd/libnetdbpf/
(no different)
No-Typo-Check: Clean move
Change-Id: I23aad26d487b4d99e24ffecf79eeef3f8eea664b
Have BpfInterfaceMapUpdater to update bpf interface map: adding
the interface and index mapping to bpf interface map when interface
added.
Bug: 215095957
Test: atest FrameworkNetTests
Change-Id: I2189a50c4869cfc0c33fc6f0228f40ee9f3ac1d4
INetd#trafficSwapActiveStatsMap is deprecated and the implementaion is
moved into tethering (connectivity) mainline module. A new
ConnectivityManager API swapActiveStatsMap is temprary exposed for
NetworkStatsFactory. Once NetworkStatsFactory move into tethering
module, swapActiveStatsMap API would be removed and NetworkStatsFactory
should could call the implemeneted inside the module directly. This
should happen before T sdk finalization.
Bug: 209935649
Test: atest NetworkStatsFactoryTest
Change-Id: I6685fe513511e7af9fa6521601891c66d1297da0
Expose systemapi NetworkStats.getDetailedUidStats for use by
BatteryStats.
BatteryStatsImpl is using INetworkStatsService APIs, which
cannot be accessed after moving into the mainline module. So, replace
and remove those hidden API usages.
Bug: 210066922
Test: atest BatteryStatsImplTest WifiPowerCalculatorTest
MobileRadioPowerCalculatorTest NetworkStatsServiceTest
CTS-Coverage-Bug: 213437796
Change-Id: I40d713923278f4654d67bb4d12155cea85c10447
This includes:
1. Move PREFIX_* constants to NetworkStatsManager to expose
in later changes.
2. Rename networkId to wifiNetworkKey.
3. Rename subType to ratType.
4. Replace SUBTYPE_COMBINED with NETWORK_TYPE_ALL
5. Fix lint errors when exposing system api.
Test: TH
Bug: 204830222
Change-Id: I2b7c34958bc59c3225c96f12abba008b83101585
This CL includes:
1. Prepare for queryDetailsForDevice which allows callers
to query history of networks that matches the given template.
2. Prepare for queryDetailsForUidTagState, which allows
callers to query history uid stats with the given template,
uid and other conditions.
3. Enforce fine location permission if the caller is querying
data usage with a template which contains wifi network keys.
Test: atest NetworkStatsServiceTest NetworkStatsManagerTest
Bug: 204830222
Bug: 200768422
Change-Id: I6783d6bfd6e075e0b3ec8a3c91836377f1d71c7a
Replace android.provider.Settings.Global methods that return the default
value and hardcoding them inside the methods.
Bug: 213329727
Test: atest NetworkStatsServiceTest
Change-Id: I51d686222f983c8deb71d4b32f9e443e87a5e53e
This is not any better than the previous code though...
But it should behave the same.
Test: FrameworksNetTests
Change-Id: Ia3d379681cb0f17dd5f86062b7cfe84f1547fadb
- Split out nsd APIs and hidden APIs to Connectivity module.
- Keep the all files in f/b/packages/Connectivity-T and add
framework-connectivity-tiramisu library on p/m/Connectivity.
Then make framework to use this module library.
- Remove NsdService from SystemServer which will register from
ConnectivityServiceInitializer
Bug: 206893064
Test: m online-sdk-dev-docs
Test: atest FrameworksNetTests CtsNetTestCases
CTS-Coverage-Bug: 207804007
Merged-In: I72c7de124b9cc53f2263bd452ecd5f39e88e485b
Change-Id: I72c7de124b9cc53f2263bd452ecd5f39e88e485b
Expose system APIs for use by NetworkStatsService.
Bug: 211843446
Test: atest NetworkStatsServiceTest NetworkPolicyManagerTest
NetworkPolicyManagerServiceTest
Change-Id: I56a066b7f4b4c2c8fefdd185c2e50de63b1e2629
This is done by:
1. Add NetworkStatsManagerInternal APIs directly from
NetworkStatsManager, these APIs are needed by NPMS.
2. Replace all usages with these APIs.
3. Delete NetworkStatsManagerInternal implementation.
Test: atest FrameworksNetTests NetworkPolicyManagerServiceTest
Bug: 204830222
CTS-Coverage-Bug: 213124616
Change-Id: If51b6676915e3a0a8a9f95221d735306911442fc
NetworkStatsService is using NetworkPolicyManagerInternal APIs, which
cannot be accessed after moving into the mainline module. So, replace
and remove those hidden API usages.
Bug: 211843446
Test: atest NetworkStatsServiceTest NetworkPolicyManagerTest
NetworkPolicyManagerServiceTest
Change-Id: I0f3f02d1dc014967fab27ffcf37dd1918dbef5e0
If the ipClient is stopped before handling the events in
Handler thread, ethernet network factory might end up
creating a network agent for a network which is already
cleared.
This change fixes the issue by handling the events only
if ipClient is initialized.
Tests:
Builds, Boots, EthernetNetworkFactoryTest.
Ethernet related test scenarios
Bug: 207057937
Change-Id: If7ff7abf5f0dcdb0e94de0502bfdf981f9f20298
Query tagged UID summary is currently needed by
StatsPullAtomService to collect tagged traffic statistics.
Add an Api via NetworkStatsManager to support this
functionality.
Test: atest NetworkStatsManagerTest
Bug: 204830222
Change-Id: Iaa54482a8109b56e66e829c5bec5a8a8f466641a
BatteryStatsImpl is using INetworkStatsService APIs, which
cannot be accessed after moving into the mainline module. So, replace
and remove those hidden API usages.
Bug: 210066922
Test: atest BatteryStatsImplTest WifiPowerCalculatorTest
MobileRadioPowerCalculatorTest
CTS-Coverage-Bug: 213437796
(cherry-picked from ag/16548638)
Change-Id: I584897ff8ba303c717a9df3756c9f6778c1cfb10
Merged-In: I584897ff8ba303c717a9df3756c9f6778c1cfb10
EthernetServiceImpl#updateConfiguration API implementation to allow
for dynamically updating the network capability or ip configuration of
an ethernet based interface.
Bug: 210485380
Test: atest EthernetServiceTests
Change-Id: Idd3b7875a24643d245d0f4bb6f2f4c459898116e
Several methods and constants are hidden in PhoneStateListener
and ServiceState to track Radio Access Technology(RAT) types.
Replace them with public API instead.
Test: atest NetworkStatsSubscriptionsMonitorTest
Fix: 213021103
Change-Id: I588398da7f2b031910a8350a7d84405ff101232d
NetworkStatsService is using INetworkManagementService APIs, which
cannot be accessed after moving into the mainline module. So, replace
and remove those hidden API usages.
Bug: 209738761
Test: atest NetworkStatsServiceTest
Change-Id: I5740f6d8a54e9a06c6dbb93203cb4c954383c3c8
OnSubscriptionsChangedListenerHandler(Looper looper) is
hidden, there is no way to pass a looper to it in the test.
This change partially revert aosp/1340040 to fix hidden
API dependency. And will use a different approach to address
this problem in later stages.
Test: atest NetworkStatsSubscriptionMonitorTest
Bug: 204830222
Bug: 213280079
Change-Id: I429be3578d599de9a5a3f78b02387c20744b37d3
* changes:
[MS09] Expose NetworkTemplate APIs which are needed by NetworkPolicy
[MS34.1] Replace TelephonyManager#getSubscriberId(subId) with public API
[MS40.1] Remove Clock dependencies from NetworkStatsService
[MS27] Expose noteUntaggedSocket SystemApi
IpSec service is going to be a part of Connectivity mainline module
and ParcelFileDescriptor(FileDescriptor) is a hidden API that cannot
be used by mainline module.
Therefore, use ParcelFileDescriptor.dup(FileDescriptor) to get a
ParcelFileDescriptor instead.
Bug: 204153604
Test: FrameworksNetTests
Change-Id: I0ccabdfc5060f4b635e9a7009a67fbd5d32002fd
This includes:
1. Re-implement the BestClock in the static library.
2. Expose SystemClock#currentNetworkTimeClock as public Api
Test: TH
Bug: 204830222
CTS-Coverage-Bug: 213393821
Exempt-From-Owner-Approval: 1. Owner approved the change with
explicitly granted submission after adderessing the
straight-forward comment. 2. Owner is OOO for 3 months.
Change-Id: I08c0162a7101cc6184f3eca3d4a59211183fb843
Replacing IIpClient with IpClientManager to reduce code duplication,
increase readability and maintainability as well as making
EthernetNetworkFactory easier to unit test.
Bug: 210485380
Test: atest EthernetServiceTests
Change-Id: I283653171c0cc47ad94a67d6dbd65b924cdf1ada