OLD | NEW |
(Empty) | |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. |
| 4 |
| 5 from google.appengine.ext import ndb |
| 6 |
| 7 from model.base_build_model import BaseBuildModel |
| 8 |
| 9 |
| 10 class Step(BaseBuildModel): |
| 11 """Represents a step in a build cycle of a builder in a waterfall.""" |
| 12 |
| 13 @staticmethod |
| 14 def CreateKey( |
| 15 master_name, builder_name, build_number, step_name): # pragma: no cover |
| 16 build_id = BaseBuildModel.CreateBuildId( |
| 17 master_name, builder_name, build_number) |
| 18 return ndb.Key('Build', build_id, 'Step', step_name) |
| 19 |
| 20 @staticmethod |
| 21 def CreateStep( |
| 22 master_name, builder_name, build_number, step_name): # pragma: no cover |
| 23 return Step( |
| 24 key=Step.CreateKey(master_name, builder_name, build_number, step_name)) |
| 25 |
| 26 @staticmethod |
| 27 def GetStep( |
| 28 master_name, builder_name, build_number, step_name): # pragma: no cover |
| 29 return Step.CreateKey( |
| 30 master_name, builder_name, build_number, step_name).get() |
| 31 |
| 32 log_data = ndb.JsonProperty(indexed=False, compressed=True) |
OLD | NEW |