formatted code.
This commit is contained in:
parent
5a6edb802e
commit
5128c51b22
6 changed files with 10 additions and 10 deletions
|
@ -5,6 +5,8 @@ import (
|
|||
"bitbucket.org/sunybingcloud/electron/def"
|
||||
"bitbucket.org/sunybingcloud/electron/pcp"
|
||||
"bitbucket.org/sunybingcloud/electron/rapl"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"fmt"
|
||||
"github.com/golang/protobuf/proto"
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
|
@ -17,8 +19,6 @@ import (
|
|||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
)
|
||||
|
||||
// Decides if to take an offer or not
|
||||
|
|
|
@ -2,6 +2,8 @@ package schedulers
|
|||
|
||||
import (
|
||||
"bitbucket.org/sunybingcloud/electron/def"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"fmt"
|
||||
"github.com/golang/protobuf/proto"
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
|
@ -12,8 +14,6 @@ import (
|
|||
"sort"
|
||||
"strings"
|
||||
"time"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
)
|
||||
|
||||
// Decides if to take an offer or not
|
||||
|
|
|
@ -5,6 +5,8 @@ import (
|
|||
"bitbucket.org/sunybingcloud/electron/def"
|
||||
"bitbucket.org/sunybingcloud/electron/pcp"
|
||||
"bitbucket.org/sunybingcloud/electron/rapl"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"fmt"
|
||||
"github.com/golang/protobuf/proto"
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
|
@ -17,8 +19,6 @@ import (
|
|||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
)
|
||||
|
||||
// electron scheduler implements the Scheduler interface
|
||||
|
|
|
@ -5,6 +5,8 @@ import (
|
|||
"bitbucket.org/sunybingcloud/electron/def"
|
||||
"bitbucket.org/sunybingcloud/electron/pcp"
|
||||
"bitbucket.org/sunybingcloud/electron/rapl"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"fmt"
|
||||
"github.com/golang/protobuf/proto"
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
|
@ -16,8 +18,6 @@ import (
|
|||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/offerUtils"
|
||||
"bitbucket.org/sunybingcloud/electron/utilities/mesosUtils"
|
||||
)
|
||||
|
||||
// Decides if to take an offer or not
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
package mesosUtils
|
||||
|
||||
import (
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
"github.com/golang/protobuf/proto"
|
||||
mesos "github.com/mesos/mesos-go/mesosproto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
|
|
@ -32,7 +32,7 @@ func getInstance(curSum float64, wSize int) *runningAverageCalculator {
|
|||
if racSingleton == nil {
|
||||
racSingleton = &runningAverageCalculator{
|
||||
considerationWindowSize: wSize,
|
||||
currentSum: curSum,
|
||||
currentSum: curSum,
|
||||
}
|
||||
return racSingleton
|
||||
} else {
|
||||
|
|
Reference in a new issue