AudioSystem: Reduce service timeout from 10s to 5s
This improves the ANR prevention.
Flag: EXEMPT bugfix
Test: Treehugger
Bug: 375691003
Change-Id: I09a5d6f775fe6486a9b6bd737c9d91e9280f4931
diff --git a/media/libaudioclient/AudioSystem.cpp b/media/libaudioclient/AudioSystem.cpp
index bb0deb1..47d5dd5 100644
--- a/media/libaudioclient/AudioSystem.cpp
+++ b/media/libaudioclient/AudioSystem.cpp
@@ -127,10 +127,10 @@
// Such an audioserver failure is considered benign as the ground truth is stored in
// the Java AudioService and can be restored once audioserver has finished initialization.
//
-// TODO(b/375691003) We use 10s as a conservative timeout value, and will tune closer to 3s.
+// TODO(b/375691003) We use 5s as a conservative timeout value, and will tune closer to 3s.
// Too small a value (i.e. less than 1s would churn repeated calls to get the service).
// The value can be tuned by the property audio.service.client_wait_ms.
-static constexpr int32_t kServiceClientWaitMs = 10'000;
+static constexpr int32_t kServiceClientWaitMs = 5'000;
static constexpr const char kServiceWaitProperty[] = "audio.service.client_wait_ms";