aboutsummaryrefslogtreecommitdiff
path: root/service/src/com/android/car/VmsPublisherService.java
AgeCommit message (Collapse)Author
2018-05-29Delay binding to vms publisher service clientsPavel Maltsev
Also, refactor VmsPublisherService to reduce memory footprint, flatten class hierarchy, get rid of lock Test: bat_land Bug: 79697265 Change-Id: Ia53c43a97f960ffa8e78617612ff9fac378e7fb4
2018-05-04Create delay rebind on publisher disconnect.Asaf Rosenfeld
Change-Id: Id7e8634e0c64e3b3c5010d442907c0e81c07ec32 Test: pass Bug: b/78359126
2018-04-06Quick path to failure on starting VMS publishers.Asaf Rosenfeld
Currently failing to bind() to a component name will result in several logged messages which are very noisy and don't make it clear that the publisher is simply not installed. Missing publishers don't crash the CarService and that is the right behavior as we want to allow multiple car configuration with a single config file. This is why we have the availability mechanism. This change checks if the package installed in the package manager before trying to grant it permissions and start it. the message in the logs is clear: 02-22 00:49:58.747 4118 4118 E VmsPublisherService: VMS publisher not installed: com.google.android.apps.geo.autograph.vms.client.localframe/.LocalFrameClientService 02-22 00:49:58.747 4118 4118 E VmsPublisherService: VMS publisher not installed: com.google.android.apps.geo.autograph.vms.client.location/.LocationClientService 02-22 00:49:58.748 4118 4118 E VmsPublisherService: VMS publisher not installed: com.google.android.apps.geo.autograph.vms.client.mapdata/.MapDataClientService 02-22 00:49:58.748 4118 4118 E VmsPublisherService: VMS publisher not installed: com.google.android.apps.geo.asafstuff/.NoSuchApp Test: pass Bug: b/77705535 Change-Id: Ib17f28dba77ff632f8e5b9029e09d7ae3780aac6
2017-09-19Making VMS a @SystemAPIAsaf Rosenfeld
This CL should go in the Pi/Master and O.Car.MR1 branches. Test: I built an image w/o @FutureFeature enabled and verified all the tests pass. Also fixed a test flakiness. Change-Id: I50495d6264c7932b670a4fae456d7f89ab5c1e55
2017-09-05Fix VMS public API based on API review (ag/2593725).Asaf Rosenfeld
Test: All tests were adjusted and pass. Bug: 65115457 Change-Id: Id271170d2d67706d243817c556e294faad672631
2017-07-21Routing logic to use publisher IDAsaf Rosenfeld
When publisher P is sending message for layer L, the routing logic will send the message to all listeners that subscribed to either layer L or Layer L + publisher P. Test: all tests pass + added tests for new use cases Bug: 63933446 Change-Id: I2f674149e7982ffede1f6426737ac1aef033b2c6
2017-05-25Merge "Adding Publisher ID support to non-hal clients. Publishers send a ↵Asaf Rosenfeld
serialized proto message with their description and get ID integer. Everytime the same serialized message is sent they will get the same ID so it is persistent within client crashes. Other clients can ask for a map all the IDs with their serialized descriptions."
2017-05-25Adding Publisher ID support to non-hal clients.Asaf Rosenfeld
Publishers send a serialized proto message with their description and get ID integer. Everytime the same serialized message is sent they will get the same ID so it is persistent within client crashes. Other clients can ask for a map all the IDs with their serialized descriptions. Test: All of VMS tests pass + added unit tests and integration tests. Change-Id: I025dd9943427ee8631a6a00adb0f9a17334a821e Bugs: 38185290, 38185731, 38185927
2017-05-16Giving permissions to VMS publishers.Antonio Cortes
Test: VmsPublisherPermissionsTest.java Bug: 37792580 Change-Id: I1a65c9ffb4d726f890db5f17abee4c11936e974b Fixes: 37792580
2017-04-05Adding availability HAL supportAsaf Rosenfeld
Test: Added tests that inject offering and check change in availability. Also verified the following pass: runtest -x ../tests/carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java runtest -x ../tests/carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java runtest -x ../tests/carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java runtest -x ../tests/carservice_unit_test/src/com/android/car/VmsRoutingTest.java runtest -x ../tests/carservice_unit_test/src/com/android/car/VmsLayersAvailabilityTest.java Change-Id: Ia641499a60e79a2c8665257d94e1050a070da18d
2017-03-24Guarantee an increasing sequence in the onVmsSubscriptionChange messageAntonio Cortes
First, instead of passing a sequence number and a list of layers, wrap them in a parcelable object. Then, generate the sequence number when updating the set of subscriptions. In this way, we guarantee that different snapshots of the subscription data have different sequence numbers. Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java Test: runtest -x packages/services/Car/tests/carservice_unit_test/src/com/android/car/VmsRoutingTest.java Bug: 36585514 Change-Id: I65cfd2aa1b0c1085bac13a3b77d472ff479da357
2017-03-23Updating VMS interfaces to use VmsLayer.Antonio Cortes
Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java Test: runtest -x packages/services/Car/tests/carservice_unit_test/src/com/android/car/VmsRoutingTest.java Bug: 36214569 Change-Id: Iee5a0595ba5bb175d9b1b6189d15902fd222a967
2017-03-21Adding availability support to VMS subscribersAsaf Rosenfeld
Test: runtest -v -x carservice_unit_test/src/com/android/car/VmsRoutingTest.java runtest -v -x carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java runtest -v -x carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java runtest -v -x carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java Change-Id: I3570dc902a020463f1041f04fa31267fbdab39c0
2017-03-16Adding a class to describe a single VMS dependency.Asaf Rosenfeld
Adding a class to describe a publisher layers offering. Adding a way to publishers to declare their offering. Adding a token to publishers so that the service can track offering and potentially have more access control on publishing Test: Verified tests run Bug: TBD Change-Id: Ibad7309608e983169deecf371360d3594a4e2dba
2017-03-14Return all the layers when reporting subscription dataAntonio Cortes
This helps publishers to make better decisions about what publish. Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java Test: runtest -x packages/services/Car/tests/carservice_unit_test/src/com/android/car/VmsRoutingTest.java Bug: 36137379 Change-Id: I8e94414ad74550b4029f06638c09d4ef5be3ed32
2017-03-13Making VmsLayer parcelable.Antonio Cortes
It is going to be used in the aidl interfaces. Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherClientServiceTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsPublisherSubscriberTest.java Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/VmsSubscriberManagerTest.java Test: runtest -x packages/services/Car/tests/carservice_unit_test/src/com/android/car/VmsRoutingTest.java Bug: 36137379 Change-Id: Ib03b2e2412028f08d8dae6e5d98eceeee9c48f22
2017-03-13Propagate onVmsSubscriptionChange event to publishers.Antonio Cortes
Test: VmsPublisherSubscriberTest Bug: 36055908 Change-Id: If7a80050cdfc2aa9bd57d07b96f102d22f57f300
2017-03-03Integrate routing manager:asafro
* subscriptions request from the HAL and Subscribers Manager reach publishers. * data from Publishers Manager and HAL reach subscribers. Test: Fixed all the current test to subscribe on target layers Bug: 34977500 Change-Id: If4345ed6c9890d703bd635fed35ef120ffd25ab5
2017-02-16Update how the car service binds to services.Antonio Cortes
Due to recent changes in the background service handling, car service tests (none-foreground) were not able to bind to services, they were failing with: java.lang.IllegalStateException: Not allowed to start service Intent {...}: app is in background This change updates how the car service binds to services in InstrumentClusterService and VmsPublisherService. Test: runtest -x packages/services/Car/tests/carservice_test/src/com/android/car/test/CarInfoManagerTest.java Bug: 35360913 Change-Id: If813d39bf1b8a7e4fc41aea2198e1591d807c711
2017-02-15VmsHalService to use the new fields in the VMS property.asafro
Will changes indexes enum in a different CL. Test: Fixed tests to parse fields from VMS messages. Bug: 35313272 Change-Id: Id718e2d1ed904daca0e13b93da20257c959ef23a
2017-02-13VMS skeleton code: VmsPublisherServiceAntonio Cortes
Implementing VMS publisher interfaces and service. The service (VmsPublisherService) starts/binds to clients (IVmsPublisherClient) and provides them with an interface (IVmsPublisherService) to publish data. The next change will include the VmsPublisherClientService which is the main interface for clients and the test. This is a post-O feature. Bug: b/34976096 Test: Flashed a Mojave board and verified there was no Car service crashes. Change-Id: I360e78e4849b4e9d36855153a808ca5aef2630c5