lib/puppet_x/coi/jboss/provider/jdbcdriver.rb
# Method to check if there is jdbc-driver.
# Method calls recursive read-resource to validate if jdbc-driver is present.
Method to check if there is jdbc-driver.
Method calls recursive read-resource to validate if jdbc-driver is present.
Method to check if there is jdbc - driver . Method calls recursive read - resource to validate if jdbc - driver is present .
def exists?
    @data = {}
    cmd = compilecmd "/subsystem=datasources/jdbc-driver=#{@resource[:name]}:read-resource(recursive=true)"
    res = execute_and_get cmd
    if(res[:result] == false)
        Puppet.debug("JDBC Driver #{@resource[:name]} does NOT exist")
        return false
    end
    Puppet.debug("JDBC Driver exists: #{res[:data].inspect}")
    @data = res[:data]
    return true
  end
def exists? @data = { } cmd = compilecmd "/subsystem=datasources/jdbc-driver=#{@resource[:name]}:read-resource(recursive=true)" res = execute_and_get cmd if ( res [ :result ] == false ) Puppet . debug ( "JDBC Driver #{@resource[:name]} does NOT exist" ) return false end Puppet . debug ( "JDBC Driver exists: #{res[:data].inspect}" ) @data = res [ :data ] return true end
Method to check if there is jdbc-driver.
Method to check if there is jdbc - driver .