Fix state to start as PENDING and only become SCHEDULED on activation.

This commit is contained in:
Steve Pulec 2015-09-16 11:22:52 -04:00
commit db23b7d24c
2 changed files with 16 additions and 9 deletions

View file

@ -28,13 +28,14 @@ class Pipeline(object):
self.pipeline_id = get_random_pipeline_id()
self.creation_time = datetime.datetime.utcnow()
self.objects = []
self.status = "PENDING"
def to_json(self):
return {
"Description": self.description,
"Fields": [{
"key": "@pipelineState",
"stringValue": "SCHEDULED"
"stringValue": self.status,
}, {
"key": "description",
"stringValue": self.description
@ -76,7 +77,7 @@ class Pipeline(object):
]
def activate(self):
pass
self.status = "SCHEDULED"
class DataPipelineBackend(BaseBackend):