RackHD/on-tasks

View on GitHub

Showing 593 of 1,093 total issues

Function ipmiCatalogJobFactory has 121 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function ipmiCatalogJobFactory(
    BaseJob,
    parser,
    waterline,
    Logger,
Severity: Major
Found in lib/jobs/ipmi-catalog.js - About 4 hrs to fix

    Function LocalCatalogJobFactory has 121 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function LocalCatalogJobFactory(
        BaseJob,
        parser,
        waterline,
        Logger,
    Severity: Major
    Found in lib/jobs/local-catalog.js - About 4 hrs to fix

      Function DellWsmanConfigureRedfishAlertFactory has 120 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function DellWsmanConfigureRedfishAlertFactory(
          BaseJob,
          WsmanTool,
          Logger,
          Promise,
      Severity: Major
      Found in lib/jobs/dell-wsman-configure-redfish-alert.js - About 4 hrs to fix

        Function run has 119 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            DockerJob.prototype._run = function run() {
                var self = this;
        
                return waterline.nodes.needByIdentifier(self.nodeId)
                    .then(function (node) {
        Severity: Major
        Found in lib/jobs/docker-job.js - About 4 hrs to fix

          Function _calculateSineticaPowerData has 119 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              SnmpPduPowerMetric.prototype._calculateSineticaPowerData = function(powerData) {
                  var out = {};
                  var unitsMap = { 
                      'pduOutName': 'null',
                      'pduOutOn': 'null',
          Severity: Major
          Found in lib/utils/metrics/snmp-pdu-power-status.js - About 4 hrs to fix

            Function racadmFactory has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring.
            Open

            function racadmFactory(
                Promise,
                parser,
                ChildProcess,
                assert,
            Severity: Minor
            Found in lib/utils/job-utils/racadm-tool.js - About 4 hrs to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Function diagUpdateFirmwareFactory has 118 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function diagUpdateFirmwareFactory(
                BaseJob,
                DiagTool,
                Logger,
                util,
            Severity: Major
            Found in lib/jobs/emc-diag-update-firmware.js - About 4 hrs to fix

              Function collectIpmiSelEntries has 118 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  IpmiJob.prototype.collectIpmiSelEntries = function(data) {
                      var self = this;
                      var lastPreviouslyReadSelEntry;
                      var lastSelDeleteTimeCurrent, lastSelDeleteTimeLastRun;
                      var totalEntries;
              Severity: Major
              Found in lib/jobs/ipmi-job.js - About 4 hrs to fix

                Function RedfishIpRangeDiscoveryJobFactory has 118 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function RedfishIpRangeDiscoveryJobFactory(
                    BaseJob,
                    Logger,
                    Promise,
                    assert,
                Severity: Major
                Found in lib/jobs/redfish-ip-range-discovery.js - About 4 hrs to fix

                  Function DellWsmanBiosJobFactory has 115 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  function DellWsmanBiosJobFactory(
                      BaseJob,
                      Logger,
                      Promise,
                      assert,
                  Severity: Major
                  Found in lib/jobs/dell-wsman-bios.js - About 4 hrs to fix

                    Function replacer has 111 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        GeneralRedfishCatalogJob.prototype.replacer = function(nodeId, odataId, res) {
                            var self = this;
                    
                            var catalogString = JSON.stringify(res.body);
                            var odataIdString = odataId;
                    Severity: Major
                    Found in lib/jobs/general-redfish-catalog.js - About 4 hrs to fix

                      Function WsmanAddHotspareUpdateXmlFactory has 111 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      function WsmanAddHotspareUpdateXmlFactory(
                          BaseJob,
                          Logger,
                          assert,
                          util,
                      Severity: Major
                      Found in lib/jobs/dell-wsman-add-hotspare-updatexml.js - About 4 hrs to fix

                        Function BaseObmServiceFactory has 111 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                        function BaseObmServiceFactory (assert, Promise, _, Logger, ChildProcess) {
                            var logger = Logger.initialize(BaseObmServiceFactory);
                        
                            /**
                             *
                        Severity: Major
                        Found in lib/services/base-obm-service.js - About 4 hrs to fix

                          Function dockerReconcilerJobFactory has 110 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function dockerReconcilerJobFactory(
                            BaseJob,
                            waterline,
                            messenger,
                            Logger,
                          Severity: Major
                          Found in lib/jobs/docker-reconciler-job.js - About 4 hrs to fix

                            Function panduitObmServiceFactory has 109 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            function panduitObmServiceFactory(
                                Promise,
                                BaseObmService,
                                _,
                                assert,
                            Severity: Major
                            Found in lib/services/panduit-obm-service.js - About 4 hrs to fix

                              Function validationJobFactory has 106 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                              function validationJobFactory(
                                  BaseJob,
                                  util,
                                  Logger,
                                  assert,
                              Severity: Major
                              Found in lib/jobs/validate-ssh.js - About 4 hrs to fix

                                Function generateSkuJobFactory has 106 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                function generateSkuJobFactory(
                                    BaseJob,
                                    waterline,
                                    eventsProtocol,
                                    catalogSearch,
                                Severity: Major
                                Found in lib/jobs/generate-sku.js - About 4 hrs to fix

                                  Function updateXml has 106 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      WsmanAddVolumeXmlJob.prototype.updateXml = function(data, drives, raidLevel, name, stripeSize, writePolicy){
                                          var self = this;
                                          var xmlFile = String.fromCharCode.apply(null, new Uint16Array(data));
                                          var doc = new xmldom().parseFromString(xmlFile, 'application/xml');
                                          var components = doc.getElementsByTagName('Component');
                                  Severity: Major
                                  Found in lib/jobs/dell-wsman-add-volume-updateXml.js - About 4 hrs to fix

                                    File snmp-job.js has 342 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    // Copyright 2015, EMC, Inc.
                                    
                                    'use strict';
                                    
                                    var di = require('di');
                                    Severity: Minor
                                    Found in lib/jobs/snmp-job.js - About 4 hrs to fix

                                      File racadm-tool.js has 342 lines of code (exceeds 250 allowed). Consider refactoring.
                                      Open

                                      // Copyright 2016, EMC, Inc.
                                      
                                      'use strict';
                                      
                                      var di = require('di');
                                      Severity: Minor
                                      Found in lib/utils/job-utils/racadm-tool.js - About 4 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language