Skip to content

Commit

Permalink
rm unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
pwzgorilla committed Sep 13, 2017
1 parent 47db7a7 commit a5237af
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 155 deletions.
16 changes: 0 additions & 16 deletions mesos/filter/constraints.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,19 +58,3 @@ func (f *constraintsFilter) getAttrs(agentIp string) map[string]string {

return s.Attrs
}

func merge(a map[string]string, b map[string]string) map[string]string {
c := make(map[string]string)

for k, v := range a {
c[k] = v
}

for k, v := range b {
if _, ok := c[k]; !ok {
c[k] = v
}
}

return c
}
3 changes: 1 addition & 2 deletions store/etcd/etcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const (
keyComposeNG = "/composes-ng" // compose instance (group apps)
keyFrameworkID = "/framework" // framework id
keyAgent = "/mesos/agents"
keyVCluster = "/vclusters"

keyTasks = "tasks" // sub key of keyApp
keyVersions = "versions" // sub key of keyApp
Expand Down Expand Up @@ -61,7 +60,7 @@ func NewEtcdStore(addrs []string) (*EtcdStore, error) {
}

// create base keys nodes
for _, node := range []string{keyApp, keyCompose, keyComposeNG, keyAgent, keyVCluster} {
for _, node := range []string{keyApp, keyCompose, keyComposeNG, keyAgent} {
store.ensureDir(node)
}

Expand Down
25 changes: 0 additions & 25 deletions store/etcd/node.go

This file was deleted.

80 changes: 0 additions & 80 deletions store/zk/node.go

This file was deleted.

2 changes: 0 additions & 2 deletions store/zk/zk.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ const (
keyComposeNG = "/composes-ng" // compose instance (group apps)
keyFrameworkID = "/frameworkId" // framework id
keyAgent = "/agents" // mesos agent with attributes
keyVCluster = "/vclusters" // mesos virtual cluster
)

var baseKeys = []string{
Expand All @@ -39,7 +38,6 @@ var baseKeys = []string{
keyComposeNG,
keyFrameworkID,
keyAgent,
keyVCluster,
}

type ZKStore struct {
Expand Down
2 changes: 0 additions & 2 deletions types/task.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ type TaskConfig struct {
Constraints []*Constraint `json:"constraints"`
Proxy *Proxy `json:"proxy"`
Version string `json:"version"`
Cluster string `json:"cluster"`
}

func NewTaskConfig(spec *Version, idx int) *TaskConfig {
Expand All @@ -107,7 +106,6 @@ func NewTaskConfig(spec *Version, idx int) *TaskConfig {
Constraints: spec.Constraints,
Proxy: spec.Proxy,
Version: spec.ID,
Cluster: spec.Cluster,
}

// with user specified ip address
Expand Down
28 changes: 0 additions & 28 deletions types/vcluster.go

This file was deleted.

0 comments on commit a5237af

Please sign in to comment.