firehol/netdata

View on GitHub
src/go/plugin/go.d/modules/oracledb/collect.go

Summary

Maintainability
A
1 hr
Test Coverage

Method OracleDB.collect has 6 return statements (exceeds 4 allowed).
Open

func (o *OracleDB) collect() (map[string]int64, error) {
    if o.db == nil {
        if err := o.openConnection(); err != nil {
            return nil, fmt.Errorf("failed to open connection: %v", err)
        }
Severity: Major
Found in src/go/plugin/go.d/modules/oracledb/collect.go - About 40 mins to fix

    Method OracleDB.doQuery has 5 return statements (exceeds 4 allowed).
    Open

    func (o *OracleDB) doQuery(query string, assign func(column, value string, lineEnd bool) error) error {
        ctx, cancel := context.WithTimeout(context.Background(), o.Timeout.Duration())
        defer cancel()
    
        rows, err := o.db.QueryContext(ctx, query)
    Severity: Major
    Found in src/go/plugin/go.d/modules/oracledb/collect.go - About 35 mins to fix

      There are no issues that match your filters.

      Category
      Status