Commit Graph

17 Commits

Author SHA1 Message Date
Remi NGUYEN VAN
b6cde3d2dc Rename "service-nearby" to "service-nearby-pre-jarjar"
Change-Id: I99ef6ee39e89f99b0878909e2d1f2962df513d1a
Test: unit test
Bug: 217115866
Merged-In: I80c8538372659a04145178fcc8e1af98e78e3681
2022-03-10 04:32:19 +00:00
Remi NGUYEN VAN
46d7ddb725 Add try/catch, shim in Nearby initialization
The try/catch allows using a stub NearbyService on branches that do not
support it yet.

Also update Context.NEARBY_SERVICE to ConstantsShim to be compatible
with all branches.

Bug: 189355156
Test: boots
Change-Id: I7db0035b0d9ada79f00d6ef1ac5b54b2e98489d0
2022-03-08 10:33:32 +00:00
Remi NGUYEN VAN
5906c8b290 Start Nearby from Connectivity ServiceInitializer
On T+, start and register Nearby services from the initializer, and send
proper callbacks.

Bug: 189355156
Test: Booted, service started
Merged-In: I7e280495f1eefada0939dad2ce7f47f45885ad66
Change-Id: Ieca032c80cb37e424d07c500257a844c8418fe3e
2022-03-04 15:34:41 -08:00
paulhu
537f72061a Rename framework-connectivity-tiramisu to framework-connectivity-t
Bug: 215434166
Test: build, flash, device boot to home.
Merged-In: I9ebedf8813cbfa30d979bc35a3b2306715be682b
Change-Id: I9ebedf8813cbfa30d979bc35a3b2306715be682b
2022-03-01 09:44:21 +08:00
Remi NGUYEN VAN
d95048929c Add JNI stats libraries to connectivity
Add new symbols to libservice-connectivity loaded on T only, and the
framework libraries to apex and tests.

Bug: 197717846
Test: atest FrameworksNetTests
  (cherry-picked and splitting apex Android.bp to aosp/1994130)
Change-Id: Iae44344701a3267110e5cbf271120201134d59e5
Merged-In: Iae44344701a3267110e5cbf271120201134d59e5
2022-02-28 04:16:17 +00:00
Junyu Lai
e764686003 [MS62.2] Add NetworkStatsService into service initializer
NetworkStatsService is going to be moved into Connectivity mainlne
module and it will be not visible to SystemServiceResistry after
migration done. Thus, register service in
NetworkStatsServiceInitialalizer and register manager in
ConnectivityFrameworkInitializerTiramisu instead.

Ignore-AOSP-First: Avoiding conflicts; cherry-pick will follow
Test: FrameworksNetTests
      CtsNetTestCases
Bug: 204830222
  (cherry-picked from ag/16727131)
Change-Id: I03d947cc54dd995f6b5b4544ee3bf03cf029d143
Merged-In: I03d947cc54dd995f6b5b4544ee3bf03cf029d143
2022-02-28 04:16:07 +00:00
Junyu Lai
eb6f4bef96 [MS54.3] Move NetworkStats to updatable sources
This CL builds NetworkStats related codes with the
connectivity module instead of platform.

Test: TH
Bug: 197717846
Change-Id: I4eeb7ea9cfc3139991caf0fc22474e0052a0391c
Merged-In: I4eeb7ea9cfc3139991caf0fc22474e0052a0391c
2022-02-28 03:24:19 +00:00
Aaron Huang
2e778ee46b Move IpSec APIs to Connectivity module
(cherry picked from commit 68ca373929)
Bug: 204153604
Test: TH
Change-Id: If4afabdc65ed2ac3e918af1d4a03c4c9173c4a3c
Merged-In: If4afabdc65ed2ac3e918af1d4a03c4c9173c4a3c
2022-02-10 14:25:04 +08:00
Treehugger Robot
0ad3becd60 Merge changes from topic "split-pre-jarjar"
* changes:
  Enable framework-connectivity-t-pre-jarjar for service-t
  Split out connectivity-t-pre-jarjar and tests
2022-02-09 12:54:46 +00:00
Remi NGUYEN VAN
2ba9dbe163 Split out connectivity-t-pre-jarjar and tests
The pre-jarjar variant is necessary so that service-t can depend on
hidden symbols in framework-t that reference (for example as parameter)
classes that are jarjared.
Without this, when depending on framework-connectivity-tiramisu.impl,
service-connectivity-t would see post-jarjar symbols that do not match
the classnames it uses in its code.

Also split FrameworksNetTestsLib so that the same jarjar rules can be
applied between the tests and the module, avoiding different errors
between FrameworksNetTests and ConnectivityCoverageTests.

Ignore-AOSP-First: Avoiding conflicts; cherry-pick will follow
Bug: 204830222
Test: m
Change-Id: I3d0c081c4a7422e128beee11c0156f01b0377c96
Merged-In: I3d0c081c4a7422e128beee11c0156f01b0377c96
2022-02-09 18:29:30 +08:00
Aaron Huang
720ad7c026 Have connectivity targets be visible to Frameworks[Vcn|Ike]Tests
(cherry picked from commit 7174ac3d86)
Bug: 204153604
Ignore-AOSP-First: part of large topic that only builds internally
Test: build, FrameworksVcnTests, FrameworksIkeTests
Change-Id: I40740200fe4a7476a21bb5330429a11c97e38fb8
Merged-In: I40740200fe4a7476a21bb5330429a11c97e38fb8
2022-02-08 14:31:27 +00:00
Lorenzo Colitti
0db496ef39 Fix libnetworkstats_test.
If libraries are moved from the platform to a module, the test
will fail with:

CANNOT LINK EXECUTABLE "/data/local/tmp/libnetworkstats_test/arm64/libnetworkstats_test": library "libnetworkstats.so" not found: needed by main executable

This may be because it can't find libnetworkstats.so because that
is in platform.

In any case, since this is the test for libnetworkstats,
dynamically linking libnetworkstats is incorrect, because it
means if the same CL modifies both libnetworkstats and its test,
that CL will run the modified test against the unmodified
libnetworkstats.so on the device, when running updating tests
without reflashing the device.

Also remove libutils because it does not seem to be needed.

Test: atest libnetworkstats_test passes with libraries moved
Change-Id: Id49641c0a919129e2c54531c3995ec7421161002
2022-02-07 02:16:34 +00:00
Remi NGUYEN VAN
6a20eeda42 Reorganize connectivity framework dependencies
Allow framework-connectivity to depend on framework-connectivity-t
stubs, and framework-connectivity-t to depend on prebuilt (to avoid
circular dependencies) framework-connectivity stubs to compile its own
stubs, and framework-connectivity.impl to compile its implementation.

Also reorganize jarjar rules so that service and framework jar can use
static libraries in framework-connectivity without packaging their own,
reducing duplicate code.

Bug: 204830222
Test: m
Change-Id: I75c34986e7c479de23cdb2e9b360fa1fede018c9
2022-02-01 13:33:48 +09:00
Ken Chen
cc764a13fa Correct typos in libnetworkstats
Fix Typo-Lints in I23aad26d487b4d99e24ffecf79eeef3f8eea664b

Bug: N/A
Test: m
Change-Id: Id9df0a279e7aad048f2c0d7be66dec40e5a8ae8a
2022-01-24 11:54:04 +08:00
Ken Chen
f426b2b287 Rename libnetdbpf to libnetworkstats
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
2022-01-24 11:53:59 +08:00
Ken Chen
f2bb7b1ae8 Copy libnetdbpf from system/net to tethering module
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
2022-01-24 06:14:38 +08:00
paulhu
802ab9760f Build framework-connectivity-tiramisu library
- Move nsd APIs and build framework-connectivity-tiramisu library
- Add nsd associated hidden apis
- Build service-connectivity-tiramisu-pre-jarjar library for
  T+ services.
- Move ConnectivityServiceInitialiizer to service-t directory
  to create S+ service instances which can avoid dependency on
  lower sdk library.

Bug: 206893064
Test: atest FrameworksNetTests CtsNetTestCases
CTS-Coverage-Bug: 207804007
Merged-In: I9628716f5c38047ff4ea2346b27589077259c436
Change-Id: I9628716f5c38047ff4ea2346b27589077259c436
2021-12-17 00:04:24 +08:00