Merge "Add user quota information into the IpSecService dump" am: fedd856546 am: 318ca31081 am: 759696c47c
am: aa32c400ce
Change-Id: Iecd820e12495121f991bb00fa65cda07bf0f2abe
This commit is contained in:
@@ -142,6 +142,17 @@ public class IpSecService extends IIpSecService.Stub {
|
||||
}
|
||||
mCurrent--;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new StringBuilder()
|
||||
.append("{mCurrent=")
|
||||
.append(mCurrent)
|
||||
.append(", mMax=")
|
||||
.append(mMax)
|
||||
.append("}")
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
||||
private static final class UserQuotaTracker {
|
||||
@@ -159,6 +170,19 @@ public class IpSecService extends IIpSecService.Stub {
|
||||
public final ResourceTracker socket = new ResourceTracker(MAX_NUM_ENCAP_SOCKETS);
|
||||
public final ResourceTracker transform = new ResourceTracker(MAX_NUM_TRANSFORMS);
|
||||
public final ResourceTracker spi = new ResourceTracker(MAX_NUM_SPIS);
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new StringBuilder()
|
||||
.append("{socket=")
|
||||
.append(socket)
|
||||
.append(", transform=")
|
||||
.append(transform)
|
||||
.append(", spi=")
|
||||
.append(spi)
|
||||
.append("}")
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
||||
private final SparseArray<UserRecord> mUserRecords = new SparseArray<>();
|
||||
@@ -172,6 +196,11 @@ public class IpSecService extends IIpSecService.Stub {
|
||||
}
|
||||
return r;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return mUserRecords.toString();
|
||||
}
|
||||
}
|
||||
|
||||
private final UserQuotaTracker mUserQuotaTracker = new UserQuotaTracker();
|
||||
@@ -909,6 +938,8 @@ public class IpSecService extends IIpSecService.Stub {
|
||||
pw.println("NetdNativeService Connection: " + (isNetdAlive() ? "alive" : "dead"));
|
||||
pw.println();
|
||||
|
||||
pw.println("mUserQuotaTracker:");
|
||||
pw.println(mUserQuotaTracker);
|
||||
pw.println("mTransformRecords:");
|
||||
pw.println(mTransformRecords);
|
||||
pw.println("mUdpSocketRecords:");
|
||||
|
||||
Reference in New Issue
Block a user