Show event log when application data is deleted
Add event log to show the information of trigger for deleting application data. Log Format: - Event log name : installer_clear_app_data_caller - Caller PID - Caller UID - package which is the target for deleting data - flag - Event log name : installer_clear_app_data_call_stack - method name on Call stack - class name on Call stack - file name on Call stack - line number on Call stack - Event log name : pm_clear_app_data_caller - Caller PID - Caller UID - package which is the target for deleting data - Event log name : am_clear_app_data_caller - Caller PID - Caller UID - package which is the target for deleting data Manual test steps: Start a logcat viewer on a adb host with the device under test connected 1. Do $ adb logcat -b events | grep clear_app_data Delete app data on the device under test. 2. Go to Settings->Apps->All apps 4. Click on an app, for example Chrome 5. Click on [Storage and cache] 6. Click on [Clear storage] 7. Click on [Delete] 8. Observe: See output from the adb host with the logcat command. 10-17 13:01:57.649 1766 3657 I am_clear_app_data_caller: [7093,10268,com.android.chrome] 10-17 13:01:57.671 1766 3657 I pm_clear_app_data_caller: [1766,1000,com.android.chrome] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_caller: [1766,1000,com.android.chrome,7] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [clearAppData,com.android.server.pm.Installer,Installer.java,447] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [clearAppDataLeafLIF,com.android.server.pm.AppDataHelper,AppDataHelper.java,580] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [clearAppDataLIF,com.android.server.pm.AppDataHelper,AppDataHelper.java,565] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [clearApplicationUserDataLIF,com.android.server.pm.PackageManagerService,PackageManagerService.java,3495] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [-$$Nest$mclearApplicationUserDataLIF,com.android.server.pm.PackageManagerService,PackageManagerService.java,0] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [run,com.android.server.pm.PackageManagerService$IPackageManagerImpl$1,PackageManagerService.java,4789] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [handleCallback,android.os.Handler,Handler.java,958] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [dispatchMessage,android.os.Handler,Handler.java,99] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [loopOnce,android.os.Looper,Looper.java,205] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [loop,android.os.Looper,Looper.java,294] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [run,android.os.HandlerThread,HandlerThread.java,67] 10-17 13:01:57.680 1766 2401 I installer_clear_app_data_call_stack: [run,com.android.server.ServiceThread,ServiceThread.java,46] Bug: 305787657 Test: manual Change-Id: I9396c0fc23d43f1c88b268a0596e8682dd5a8377
Loading
Please register or sign in to comment