mongodb/mongo-ruby-driver

View on GitHub
lib/mongo/server.rb

Summary

Maintainability
B
7 hrs
Test Coverage

Class Server has 27 methods (exceeds 20 allowed). Consider refactoring.
Open

  class Server
    extend Forwardable
    include Monitoring::Publishable
    include Event::Publisher

Severity: Minor
Found in lib/mongo/server.rb - About 3 hrs to fix

    File server.rb has 256 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    module Mongo
    
      # Represents a single server on the server side that can be standalone, part of
      # a replica set, or a mongos.
      #
    Severity: Minor
    Found in lib/mongo/server.rb - About 2 hrs to fix

      Method initialize has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          def initialize(address, cluster, monitoring, event_listeners, options = {})
            @address = address
            @cluster = cluster
            @monitoring = monitoring
            options = options.dup
      Severity: Minor
      Found in lib/mongo/server.rb - About 1 hr to fix

        Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            def initialize(address, cluster, monitoring, event_listeners, options = {})
        Severity: Minor
        Found in lib/mongo/server.rb - About 35 mins to fix

          There are no issues that match your filters.

          Category
          Status