Update handling of rate limiter data load failure
New handling can be broken into these cases:
- No directory/file
- successfully create directory/file
- (1) this is likely the first time it's being used, treat as no runs.
- fail to create directory/file
- (2) previous runs have likely been lost and we can't persist
- Failed to open/read file
- (3) previous runs have likely been lost
Of the 3 states:
1 - treat as no records, initialize and set ready for use
2 - can't persist, disable feature entirely
3 - delete old file and try to create new one
- if successful, make mock records to and set ready for use (effectively disable feature for 1 week)
- if failed, treat as state (2)
Test: atest ProfilingServiceTests
Bug: 335542725
Flag: EXEMPT - bug fix
Change-Id: Ie6ddfa4b811ab4acbef4862ba99f4201f656562c
2 files changed