docker/swarmkit

View on GitHub

Showing 1,820 of 1,820 total issues

Similar blocks of code found in 10 locations. Consider refactoring.
Open

    case EventUpdateVolume:
        if v.OldVolume != nil {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Volume{Volume: v.Volume}}, OldObject: &Object{Object: &Object_Volume{Volume: v.OldVolume}}}
        } else {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Volume{Volume: v.Volume}}}
Severity: Major
Found in api/objects.pb.go and 9 other locations - About 1 hr to fix
api/objects.pb.go on lines 5871..5876
api/objects.pb.go on lines 5881..5886
api/objects.pb.go on lines 5891..5896
api/objects.pb.go on lines 5901..5906
api/objects.pb.go on lines 5911..5916
api/objects.pb.go on lines 5921..5926
api/objects.pb.go on lines 5931..5936
api/objects.pb.go on lines 5941..5946
api/objects.pb.go on lines 5951..5956

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 134.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

    case EventUpdateNode:
        if v.OldNode != nil {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Node{Node: v.Node}}, OldObject: &Object{Object: &Object_Node{Node: v.OldNode}}}
        } else {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Node{Node: v.Node}}}
Severity: Major
Found in api/objects.pb.go and 9 other locations - About 1 hr to fix
api/objects.pb.go on lines 5881..5886
api/objects.pb.go on lines 5891..5896
api/objects.pb.go on lines 5901..5906
api/objects.pb.go on lines 5911..5916
api/objects.pb.go on lines 5921..5926
api/objects.pb.go on lines 5931..5936
api/objects.pb.go on lines 5941..5946
api/objects.pb.go on lines 5951..5956
api/objects.pb.go on lines 5961..5966

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 134.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

    case EventUpdateService:
        if v.OldService != nil {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Service{Service: v.Service}}, OldObject: &Object{Object: &Object_Service{Service: v.OldService}}}
        } else {
            return &WatchMessage_Event{Action: WatchActionKindUpdate, Object: &Object{Object: &Object_Service{Service: v.Service}}}
Severity: Major
Found in api/objects.pb.go and 9 other locations - About 1 hr to fix
api/objects.pb.go on lines 5871..5876
api/objects.pb.go on lines 5891..5896
api/objects.pb.go on lines 5901..5906
api/objects.pb.go on lines 5911..5916
api/objects.pb.go on lines 5921..5926
api/objects.pb.go on lines 5931..5936
api/objects.pb.go on lines 5941..5946
api/objects.pb.go on lines 5951..5956
api/objects.pb.go on lines 5961..5966

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 134.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

package node

import (
    "fmt"

Severity: Major
Found in swarmd/cmd/swarmctl/node/drain.go and 4 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/node/activate.go on lines 1..24
swarmd/cmd/swarmctl/node/demote.go on lines 1..24
swarmd/cmd/swarmctl/node/pause.go on lines 1..24
swarmd/cmd/swarmctl/node/promote.go on lines 1..24

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        for _, taskID := range removeTasks {
            if err := batch.Update(func(tx store.Tx) error {
                t := store.GetTask(tx, taskID)
                if t == nil {
                    return nil
Severity: Major
Found in manager/orchestrator/jobs/global/reconciler.go and 1 other location - About 1 hr to fix
manager/orchestrator/jobs/replicated/reconciler.go on lines 249..265

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

package node

import (
    "fmt"

Severity: Major
Found in swarmd/cmd/swarmctl/node/demote.go and 4 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/node/activate.go on lines 1..24
swarmd/cmd/swarmctl/node/drain.go on lines 1..24
swarmd/cmd/swarmctl/node/pause.go on lines 1..24
swarmd/cmd/swarmctl/node/promote.go on lines 1..24

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

package node

import (
    "fmt"

Severity: Major
Found in swarmd/cmd/swarmctl/node/pause.go and 4 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/node/activate.go on lines 1..24
swarmd/cmd/swarmctl/node/demote.go on lines 1..24
swarmd/cmd/swarmctl/node/drain.go on lines 1..24
swarmd/cmd/swarmctl/node/promote.go on lines 1..24

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    if storeObject.WatchSelectors.CustomPrefix != nil && *storeObject.WatchSelectors.CustomPrefix {
        d.P("func ", ccTypeName, "CheckCustomPrefix(v1, v2 *", ccTypeName, ") bool {")
        d.In()
        // Node is a special case
        if _, hasNoSpec := typesWithNoSpec[*m.Name]; hasNoSpec {
Severity: Major
Found in protobuf/plugin/storeobject/storeobject.go and 1 other location - About 1 hr to fix
protobuf/plugin/storeobject/storeobject.go on lines 252..264

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

package node

import (
    "fmt"

Severity: Major
Found in swarmd/cmd/swarmctl/node/promote.go and 4 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/node/activate.go on lines 1..24
swarmd/cmd/swarmctl/node/demote.go on lines 1..24
swarmd/cmd/swarmctl/node/drain.go on lines 1..24
swarmd/cmd/swarmctl/node/pause.go on lines 1..24

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        for _, taskID := range removeTasks {
            if err := batch.Update(func(tx store.Tx) error {
                t := store.GetTask(tx, taskID)
                if t == nil {
                    return nil
Severity: Major
Found in manager/orchestrator/jobs/replicated/reconciler.go and 1 other location - About 1 hr to fix
manager/orchestrator/jobs/global/reconciler.go on lines 213..229

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

    if flags.Changed("update-order") {
        if spec.Update == nil {
            spec.Update = &api.UpdateConfig{}
        }

Severity: Major
Found in swarmd/cmd/swarmctl/service/flagparser/update.go and 2 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 109..126
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 128..146

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

    if flags.Changed("rollback-on-failure") {
        if spec.Rollback == nil {
            spec.Rollback = &api.UpdateConfig{}
        }

Severity: Major
Found in swarmd/cmd/swarmctl/service/flagparser/update.go and 2 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 61..79
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 128..146

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    if storeObject.WatchSelectors.Custom != nil && *storeObject.WatchSelectors.Custom {
        d.P("func ", ccTypeName, "CheckCustom(v1, v2 *", ccTypeName, ") bool {")
        d.In()
        // Node is a special case
        if _, hasNoSpec := typesWithNoSpec[*m.Name]; hasNoSpec {
Severity: Major
Found in protobuf/plugin/storeobject/storeobject.go and 1 other location - About 1 hr to fix
protobuf/plugin/storeobject/storeobject.go on lines 266..278

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

package node

import (
    "fmt"

Severity: Major
Found in swarmd/cmd/swarmctl/node/activate.go and 4 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/node/demote.go on lines 1..24
swarmd/cmd/swarmctl/node/drain.go on lines 1..24
swarmd/cmd/swarmctl/node/pause.go on lines 1..24
swarmd/cmd/swarmctl/node/promote.go on lines 1..24

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

    if flags.Changed("rollback-order") {
        if spec.Rollback == nil {
            spec.Rollback = &api.UpdateConfig{}
        }

Severity: Major
Found in swarmd/cmd/swarmctl/service/flagparser/update.go and 2 other locations - About 1 hr to fix
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 61..79
swarmd/cmd/swarmctl/service/flagparser/update.go on lines 109..126

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 133.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Method Agent.handleSessionMessage has 51 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func (a *Agent) handleSessionMessage(ctx context.Context, message *api.SessionMessage, nti *api.NodeTLSInfo) error {
    seen := map[api.Peer]struct{}{}
    for _, manager := range message.Managers {
        if manager.Peer.Addr == "" {
            continue
Severity: Minor
Found in agent/agent.go - About 1 hr to fix

    Function parseRestart has 51 lines of code (exceeds 50 allowed). Consider refactoring.
    Open

    func parseRestart(flags *pflag.FlagSet, spec *api.ServiceSpec) error {
        if spec.Task.Restart == nil {
            // set new service's restart policy as RestartOnAny
            spec.Task.Restart = &api.RestartPolicy{
                Condition: api.RestartOnAny,
    Severity: Minor
    Found in swarmd/cmd/swarmctl/service/flagparser/restart.go - About 1 hr to fix

      Method Resource.MarshalToSizedBuffer has 51 lines of code (exceeds 50 allowed). Consider refactoring.
      Open

      func (m *Resource) MarshalToSizedBuffer(dAtA []byte) (int, error) {
          i := len(dAtA)
          _ = i
          var l int
          _ = l
      Severity: Minor
      Found in api/objects.pb.go - About 1 hr to fix

        Method ServiceSpec.CopyFrom has 51 lines of code (exceeds 50 allowed). Consider refactoring.
        Open

        func (m *ServiceSpec) CopyFrom(src interface{}) {
        
            o := src.(*ServiceSpec)
            *m = *o
            github_com_moby_swarmkit_v2_api_deepcopy.Copy(&m.Annotations, &o.Annotations)
        Severity: Minor
        Found in api/specs.pb.go - About 1 hr to fix

          Method Server.ListServiceStatuses has 51 lines of code (exceeds 50 allowed). Consider refactoring.
          Open

          func (s *Server) ListServiceStatuses(ctx context.Context, req *api.ListServiceStatusesRequest) (*api.ListServiceStatusesResponse, error) {
              resp := &api.ListServiceStatusesResponse{}
              if req == nil {
                  return resp, nil
              }
          Severity: Minor
          Found in manager/controlapi/service.go - About 1 hr to fix
            Severity
            Category
            Status
            Source
            Language