Commit ce9d2eaa authored by Daniel Wolf's avatar Daniel Wolf
Browse files

Provide more mem info

parent 0940e250
Pipeline #7694 passed with stage
in 4 minutes and 17 seconds
......@@ -153,7 +153,7 @@ dependencies {
implementation 'com.frostnerd.utilskt:lifecycle:1.2.1'
implementation 'com.frostnerd.utilskt:preferences:1.5.30' // https://git.frostnerd.com/AndroidUtils/preferenceskt
implementation 'com.frostnerd.utilskt:navigationdraweractivity:1.4.2' // https://git.frostnerd.com/AndroidUtils/navigationdraweractivity
implementation 'com.frostnerd.utilskt:encrypteddnstunnelproxy:2.1.21' // https://git.frostnerd.com/AndroidUtils/encrypteddnstunnelproxy
implementation 'com.frostnerd.utilskt:encrypteddnstunnelproxy:2.1.23' // https://git.frostnerd.com/AndroidUtils/encrypteddnstunnelproxy
implementation 'com.frostnerd.utilskt:general:1.0.25' // https://git.frostnerd.com/AndroidUtils/generalkt
implementation 'com.frostnerd.utilskt:adapters:1.2.0' // https://git.frostnerd.com/AndroidUtils/Adapters
......
......@@ -123,6 +123,7 @@ class ConnectionWatchdog(private val trafficStats: TrafficStats,
private fun printMemInfo() {
val nativeHeapSize = Debug.getNativeHeapSize()
val nativeHeapFreeSize = Debug.getNativeHeapFreeSize()
val memInfo = trafficStats.memInfo()
log(buildString {
append("MemInfo: [")
append("OpenSockets: ")
......@@ -135,6 +136,14 @@ class ConnectionWatchdog(private val trafficStats: TrafficStats,
append(trafficStats.bytesSentToDevice)
append(", BytesQueued: ")
append(trafficStats.bytesQueuedToDevice)
append(", MetaSize: ")
append(memInfo?.metaSize ?: "?")
append(", OutputSize: ")
append(memInfo?.outputSize ?: "?")
append(", OutputSizeBytes: ")
append(memInfo?.outputSizeBytes ?: "?")
append(", WaitingPackets: ")
append(memInfo?.waitingPacketSize ?: "?")
append(", HeapSize: ")
append(nativeHeapSize/1000/1000)
append("mb")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment