Replace AsyncTask with an executor

This change replaces AsyncTask with an executor because Async task is
deprecated as of Android R (and [1] recommends using an executor
directly).

[1]: https://developer.android.com/reference/android/os/AsyncTask

Test: Check that trace files are still cleared as expected.
Bug: 227805529
Change-Id: I1775f4977104be899c737dee53a016dbe51de4b5
1 file changed