New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 900381 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 1
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

[Findit] Add customized validator to cache

Project Member Reported by chanli@chromium.org, Oct 30

Issue description

When cache some data, it's possible we end up cache some broken data and we have to wait the cache to be expired or flush cache or delete the entry.

The plan is to add a customized result validator to cache so that we can only cache the valid results to save us trouble.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/infra/infra/+/912ffdf41c985af55a6732d62c4109c044508b2d

commit 912ffdf41c985af55a6732d62c4109c044508b2d
Author: Chan <chanli@chromium.org>
Date: Tue Oct 30 23:02:02 2018

[Findit] Validate step_metadata before caching it.

In the change,
+ a result_validator is added to CacheDecorator to enable customized result validation
+ Validate the step_metadata is a dict before caching it

Bug:  900381 
Change-Id: I4be79a9ec2953de182c5ef7dd3b217a14637e27f
Reviewed-on: https://chromium-review.googlesource.com/c/1308794
Reviewed-by: Roberto Carrillo <robertocn@chromium.org>
Reviewed-by: Jeffrey Li <lijeffrey@chromium.org>
Commit-Queue: Chan Li <chanli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#18671}
[modify] https://crrev.com/912ffdf41c985af55a6732d62c4109c044508b2d/appengine/findit/services/step_util.py
[modify] https://crrev.com/912ffdf41c985af55a6732d62c4109c044508b2d/appengine/findit/libs/cache_decorator.py
[modify] https://crrev.com/912ffdf41c985af55a6732d62c4109c044508b2d/appengine/findit/services/test/step_util_test.py
[modify] https://crrev.com/912ffdf41c985af55a6732d62c4109c044508b2d/appengine/findit/libs/test/cache_decorator_test.py

Status: Fixed (was: Started)

Sign in to add a comment