Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1128)

Unified Diff: appengine/findit/model/build.py

Issue 820113002: [Findit] Add a sub-pipeline to detect first-known failure. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Test will come in next patchset. Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: appengine/findit/model/build.py
diff --git a/appengine/findit/model/build.py b/appengine/findit/model/build.py
index 3dcd47a2c4cd9fe422fb5ccbe06ec990232887f5..49d18a4dfff925d0de755ec09a582bf1cfecee83 100644
--- a/appengine/findit/model/build.py
+++ b/appengine/findit/model/build.py
@@ -2,12 +2,8 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-import calendar
-
from google.appengine.ext import ndb
-from model.build_analysis_status import BuildAnalysisStatus
-
class Build(ndb.Model):
"""Represent a build cycle of a builder in a waterfall."""
@@ -29,19 +25,13 @@ class Build(ndb.Model):
def GetBuild(master_name, builder_name, build_number): # pragma: no cover
return Build.CreateKey(master_name, builder_name, build_number).get()
- def Reset(self):
- """Reset to the state as if no analysis is run."""
- self.analysis_status = BuildAnalysisStatus.PENDING
- self.analysis_start_time = None
- self.analysis_updated_time = None
-
- # Information of the build.
master_name = ndb.StringProperty(indexed=False)
builder_name = ndb.StringProperty(indexed=False)
build_number = ndb.IntegerProperty(indexed=False)
- # Information of analysis processing.
- analysis_status = ndb.IntegerProperty(
- default=BuildAnalysisStatus.PENDING, indexed=False)
- analysis_start_time = ndb.DateTimeProperty(indexed=False)
- analysis_updated_time = ndb.DateTimeProperty(indexed=False)
+ data = ndb.JsonProperty(indexed=False, compressed=True)
+ last_crawled_time = ndb.DateTimeProperty(indexed=False)
+
+ start_time = ndb.DateTimeProperty(indexed=False)
+ completed = ndb.BooleanProperty(default=False, indexed=False)
+ result = ndb.IntegerProperty(indexed=False)

Powered by Google App Engine
This is Rietveld 408576698