add tier and production into task config
This commit is contained in:
parent
4d0e61c816
commit
130983693a
9 changed files with 69 additions and 3 deletions
9
task.go
9
task.go
|
@ -79,7 +79,9 @@ func TaskFromThrift(config *aurora.TaskConfig) *AuroraTask {
|
|||
Name(config.Job.Name).
|
||||
MaxFailure(config.MaxTaskFailures).
|
||||
IsService(config.IsService).
|
||||
Priority(config.Priority)
|
||||
Priority(config.Priority).
|
||||
Tier(*config.Tier).
|
||||
Production(*config.Production)
|
||||
|
||||
if config.Tier != nil {
|
||||
newTask.Tier(*config.Tier)
|
||||
|
@ -294,6 +296,11 @@ func (t *AuroraTask) Priority(priority int32) *AuroraTask {
|
|||
return t
|
||||
}
|
||||
|
||||
func (t *AuroraTask) Production(production bool) *AuroraTask {
|
||||
t.task.Production = &production
|
||||
return t
|
||||
}
|
||||
|
||||
// Add a list of URIs with the same extract and cache configuration. Scheduler must have
|
||||
// --enable_mesos_fetcher flag enabled. Currently there is no duplicate detection.
|
||||
func (t *AuroraTask) AddURIs(extract bool, cache bool, values ...string) *AuroraTask {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue