summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Lorenzo Colitti <lorenzo@google.com> 2016-10-27 13:05:25 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2016-10-27 13:05:26 +0000
commitd19524f4f2cc3c0dc34559254b537db37fc3376b (patch)
treee9729c0b5412473c4b3134b3117c5ee10071b9e5
parentef0cc6205872fc77da84df3420bca65824c1ad96 (diff)
parent265494a0f89fc6724ff09c60f072fdeba6285643 (diff)
Merge changes from topic 'netd_aosp'
* changes: Add connect event reporting Extending DNS event reporting
-rw-r--r--services/core/java/com/android/server/connectivity/NetdEventListenerService.java12
1 files changed, 11 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/connectivity/NetdEventListenerService.java b/services/core/java/com/android/server/connectivity/NetdEventListenerService.java
index 98f34ca11f71..f21d9b725f9f 100644
--- a/services/core/java/com/android/server/connectivity/NetdEventListenerService.java
+++ b/services/core/java/com/android/server/connectivity/NetdEventListenerService.java
@@ -126,7 +126,9 @@ public class NetdEventListenerService extends INetdEventListener.Stub {
@Override
// Called concurrently by multiple binder threads.
- public synchronized void onDnsEvent(int netId, int eventType, int returnCode, int latencyMs) {
+ // This method must not block or perform long-running operations.
+ public synchronized void onDnsEvent(int netId, int eventType, int returnCode, int latencyMs,
+ String hostname, String[] ipAddresses, int ipAddressesCount, int uid) {
maybeVerboseLog(String.format("onDnsEvent(%d, %d, %d, %d)",
netId, eventType, returnCode, latencyMs));
@@ -138,6 +140,14 @@ public class NetdEventListenerService extends INetdEventListener.Stub {
batch.addResult((byte) eventType, (byte) returnCode, latencyMs);
}
+ @Override
+ // Called concurrently by multiple binder threads.
+ // This method must not block or perform long-running operations.
+ public synchronized void onConnectEvent(int netId, int latencyMs, String ipAddr, int port,
+ int uid) {
+ maybeVerboseLog(String.format("onConnectEvent(%d, %d)", netId, latencyMs));
+ }
+
public synchronized void dump(PrintWriter writer) {
IndentingPrintWriter pw = new IndentingPrintWriter(writer, " ");
pw.println(TAG + ":");