Skip to content
This repository was archived by the owner on Jan 5, 2019. It is now read-only.

Rewrite on azure storage services#32

Merged
jonasfj merged 0 commit intomasterfrom
rewrite-on-azure-storage-services
Mar 19, 2015
Merged

Rewrite on azure storage services#32
jonasfj merged 0 commit intomasterfrom
rewrite-on-azure-storage-services

Conversation

@jonasfj
Copy link
Contributor

@jonasfj jonasfj commented Feb 13, 2015

This is a pretty big rewrite... I don't recommend trying to read the diff... Just look at the result..

Please, don't hit the merge button... We shouldn't land this before we've ported both provisioning logic and docker-worker. I'll backport non-deprecated APIs so that we can do this before we deploy this.

Anyways, please leave comments if you have questions... Or if anything looks not right, sketchy just ask...

@jonasfj
Copy link
Contributor Author

jonasfj commented Feb 13, 2015

Oh, and don't worry about this failing on travis... I think it's due to network issues... sometimes it takes 4 mins on travis, sometimes it takes 30 min and times out left and right...

Note locally it only takes 90s to run npm test.

@jonasfj jonasfj mentioned this pull request Feb 20, 2015
routes/v1.js Outdated
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would we not want to publish to task-exception for a particular run that was caused by a worker shutdown?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not if we schedule another run to retry. At the moment we don't publish task-exception if the claim expired and we still have retries left, then we schedule a new run with reasonCreated: 'retry'. I think the same logic applies here, ie. we do what we normally would do when a claim is expired.

Note, IMO, task-completed, task-exception and task-failed should only come once for each task. Specifically when the queue is done processing the task. No more retries, etc. If some day we move auto-reruns into the queue it should do the same.

If we need run-level events, let's add them later as run-exception, etc...

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, thanks for clearing that up. Right now in a few different places, we rely on those pulse message to indicate a run of a task is complete, rather than information about the task itself. Having a way to listen for when a run has been completed could be useful later, but at least I know this is the behavior for now. Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, a run being completed also results in the task being resolved as completed.. We don't schedule retries for successful task yet -- I'm sure someone will ask for this feature later, he he :)

@jonasfj
Copy link
Contributor Author

jonasfj commented Mar 18, 2015

Okay, the resolvers/reapers... still have the potential timeout issues you mentioned. I think we should solve it at azure library level with timeouts... Note, https://github.com/gluwer/azure-table-node the library we use for table storage already defaults to 30s timeouts... IMO, we should still set this somewhere and make sure that base.Entity uses an HTTP agent... but that's all at base.Entity level patches suggestions are most welcome...

And implement producer consumer pattern for better more stable performance...

@jonasfj jonasfj merged commit fbe86e0 into master Mar 19, 2015
@jonasfj jonasfj deleted the rewrite-on-azure-storage-services branch March 23, 2016 19:11
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants