Showing 67 of 131 total issues
Method opatch
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
def opatch(action)
user = resource[:os_user]
patchName = resource[:patch_id]
oracle_product_home_dir = resource[:oracle_product_home_dir]
jdk_home_dir = resource[:jdk_home_dir]
Method domain_partition_control
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
def domain_partition_control(action)
Puppet.debug "domain_partition action: #{action}"
name = resource[:domain_partition]
user = resource[:os_user]
Method execute_rest
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
def execute_rest(domain, parameters, operation)
array_size = parameters['attributes'].size
weblogicUser = domain['weblogic_user'] || 'weblogic'
weblogicConnectUrl = domain['connect_url'] || 'http://localhost:7001'
- Read upRead up
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
Method domain_partition_control
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def domain_partition_control(action)
Puppet.debug "domain_partition action: #{action}"
name = resource[:domain_partition]
user = resource[:os_user]
- Read upRead up
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
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Avoid deeply nested control flow statements. Open
unless osb == 'empty'
osb = osb.strip.downcase
if osb.include? target
log 'osb_cluster_configured return true'
return true
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Method patches_in_home
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def self.patches_in_home(oracle_product_home_dir, os_user, orainst_dir)
kernel = Facter.value(:kernel)
su_shell = kernel == 'Linux' ? '-s /bin/bash' : ''
full_command = "#{oracle_product_home_dir}/OPatch/opatch lsinventory -oh #{oracle_product_home_dir} -invPtrLoc #{orainst_dir}/oraInst.loc"
if Puppet.features.root?
- Read upRead up
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
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Avoid deeply nested control flow statements. Open
case type
when 'jdbc'
jdbc = lookup_wls_var(prefix + '_' + n.to_s + '_jdbc')
unless jdbc == 'empty'
return true if jdbc.include? wlsObject
Method change_to_s
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def change_to_s(from, to)
return_value = []
realm_path = wls_get_realm_path('', provider)
base_path = "#{realm_path}/AuthenticationProviders/#{resource['authentication_provider_name']}"
from.keys.each do | property|
- Read upRead up
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
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Avoid deeply nested control flow statements. Open
unless bam == 'empty'
bam = bam.strip.downcase
if bam.include? target
log 'bam_cluster_configured return true'
return true
Avoid deeply nested control flow statements. Open
unless soa == 'empty'
soa = soa.strip.downcase
if soa.include? target
log 'soa_cluster_configured return true'
return true
Method sync
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def sync
event = super()
# rubocop:disable all
if property = @resource.property(:enable)
val = property.retrieve
- Read upRead up
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
Avoid deeply nested control flow statements. Open
unless jrf == 'empty'
jrf = jrf.strip.downcase
if jrf.include? target
log 'jrf_cluster_configured return true'
return true
Method execute_wlst
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def execute_wlst(script, tmpFile, parameters, domain, domainValues, options = {})
Avoid deeply nested control flow statements. Open
unless oim == 'empty'
if oim == 'true'
log 'oim_configured return true'
return true
end