Make "Recycle" Android Lint rule blocking for ExtServices

"Recycle" Android Lint rule checks the code for unclosed Cursor
objects, as well as other unclosed resources. Cursors which are
not closed as soon as they are not used anymore may lead to
Android performance issues:

* if Cursor was created by querying ContentProvider, then it
  will hold an active binding to the process that hosts
  ContentProvider, which will prevent this process from being
  cached or unloaded
* each Cursor can hold an up to 2 MB CursorWindow memory buffer

Changing "Recycle" rule severity to "error" will block the code
with unclosed Cursors from being submitted.

Bug: 266775648
Test: m ExtServices
Test: m lint-check
Merged-In: Ibf8e167e8f526e0e9cb31b6538c43759d170405f
Change-Id: I8e07f387864060438337bea7427672c5ed4ac32e
1 file changed
tree: 9ce5135cd2135e7352124436b2186470daededf4
  1. apex/
  2. java/
  3. jni/
  4. native/
  5. .clang-format
  6. Android.bp
  7. AndroidManifest.xml
  8. NOTICE
  9. OWNERS
  10. PREUPLOAD.cfg
  11. proguard.proguard
  12. README.md
  13. TEST_MAPPING
README.md

ExtServices module

Introduction

ExtServices is an updatable Mainline module that contains the logic used by Android framework components such as storage cache, autofill, textclassifier, package watchdog, notifications and notification ranking that run continually. For the new features or bug fixes of these platform defined services above or a new added platform service, it will provide more flexibility and benefits by updating ExtServices in a more frequent cycle than a platform release cycle.

Development (internal)

Before you start to develop on ExtServices, please read go/smart-os-extservices to get the guideline.

Other resources