Class: MintPress::OracleDatabase::Patch
- Inherits:
-
Object
- Object
- MintPress::OracleDatabase::Patch
- Defined in:
- src/oracle-database/lib/oracle-database/model/database/patch.rb
Overview
Properties (Read/Write)
-
#name ⇒ String
Patch ARU - almost always a number like 12354566 Name of the patch. This is often, but not always, the same as the ARU. It's primarily used as an internal identifier
Property Attributes- required ⇒ true
- from ⇒ Integer
64
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 64 property :name, type: String, required: true, from: Integer
-
#aru ⇒ String (Default Value: Proc.new { self.name })
ARU of the patch - this is usually numeric. THis defaults to the name, if not specified.
Property Attributes- from ⇒ Integer
- default ⇒ Proc.new { self.name }
66
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 66 property :aru, type: String, from: Integer, default: Proc.new { self.name }
-
#stage ⇒ Pathname (Default Value: Proc.new { find_in_super([:stage, :software_stage]) })
Location of the patch on disk
Property Attributes- from ⇒ String
- required ⇒ true
- default ⇒ Proc.new { find_in_super([:stage, :software_stage]) }
68
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 68 property :stage, type: Pathname, from: String, required: true, default: Proc.new { find_in_super([:stage, :software_stage]) }
-
#opatchcmd ⇒ String (Default Value: "opatch")
Command to use for opatch - unless you know better, this can be left as the default of 'opatch'
Property Attributes- default ⇒ "opatch"
70
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 70 property :opatchcmd, type: String, default: "opatch"
-
#listcmd ⇒ String (Default Value: "lspatches")
Opatch parameter for listing. Unless you know better, this can be left as the default of 'lspatches'
Property Attributes- default ⇒ "lspatches"
72
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 72 property :listcmd, type: String, default: "lspatches"
-
#applycmd ⇒ String (Default Value: "napply -skip_duplicate -skip_subset")
Opatch paramteres for apply. Unless you know better, this can be left as default.
Property Attributes- default ⇒ "napply -skip_duplicate -skip_subset"
74
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 74 property :applycmd, type: String, default: "napply -skip_duplicate -skip_subset"
-
#optional_args ⇒ String (Default Value: "")
Any optional arguments to pass to opatch
Property Attributes- default ⇒ ""
76
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 76 property :optional_args, type: String, default: ""
-
#installation ⇒ [ MintPress::OracleDatabase::Installation, MintPress::OracleGridInfrastructure::Installation, MintPress::OracleDatabaseClient::Installation ] (Default Value: Proc.new { patchset.installation })
Installation object this patch is being applied to
Property Attributes- default ⇒ Proc.new { patchset.installation }
79
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 79 property :installation, type: [ MintPress::OracleDatabase::Installation, MintPress::OracleGridInfrastructure::Installation, MintPress::OracleDatabaseClient::Installation ], default: Proc.new { patchset.installation }
-
#opatch_autoupdate_file ⇒ Pathname (Default Value: Proc.new { find_in_super(:opatch_autoupdate_file) })
Property Attributes- default ⇒ Proc.new { find_in_super(:opatch_autoupdate_file) }
- from ⇒ String
81
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 81 property :opatch_autoupdate_file, default: Proc.new { find_in_super(:opatch_autoupdate_file) }, type: Pathname, from: String
-
#required_opatch_version ⇒ String (Default Value: Proc.new {
ov = find_in_super(:required_opatch_version)
ov
})
'The minimum opatch version required, if we do not find this version, we will update it using the opatch_autoupdate_file'
Property Attributes- default ⇒ Proc.new { ov = find_in_super(:required_opatch_version) ov }
84 85 86 87
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 84 property :required_opatch_version, type: String, default: Proc.new { ov = find_in_super(:required_opatch_version) ov }, description: 'The minimum opatch version required, if we do not find this version, we will update it using the opatch_autoupdate_file'
-
#patchset ⇒ MintPress::OracleDatabase::PatchSet
Backreference to any patchset in which we are present
Property Attributes- required ⇒ false
- prop_name ⇒ :patches
91
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 91 property :patchset, type: MintPress::OracleDatabase::PatchSet, required: false, prop_name: :patches
-
#default_action ⇒ Symbol (Default Value: :apply)
This is for patch ordering
Property Attributes- default ⇒ :apply
- allowed_values ⇒ [ :apply, :rollback ]
94
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 94 property :default_action, type: Symbol, default: :apply, allowed_values: [ :apply, :rollback ]
-
#apply_before ⇒ Array of ⇒ String
as "apply_before", a list of patch names that must be applied first - this is what you should use if your default action is 'apply' as "rollback_after", a list of patch names that must be applied after this patch - this is what you should use if your default action is 'rollback'
Property Attributes- alias ⇒ :rollback_after
98
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 98 property :apply_before, type: String, array: true, alias: :rollback_after
-
#apply_after ⇒ Array of ⇒ String
as "apply_after", a list of patch names that must be applied after this patch - this is what you should use if your default action is 'apply' as "rollback_before", a list of patch names that must be applied first - this is what you should use if your default action is 'rollback'
Property Attributes- alias ⇒ :rollback_before
102
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 102 property :apply_after, type: String, array: true, alias: :rollback_before
-
#execute_before ⇒ String (Default Value: nil)
'Accepts commands or script that will be executed before a patch is applied.'
Property Attributes- default ⇒ nil
104
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 104 property :execute_before, type: String, default: nil, description: 'Accepts commands or script that will be executed before a patch is applied.'
-
#execute_after ⇒ String (Default Value: nil)
'Accepts commands or script that will be executed after a patch is applied.'
Property Attributes- default ⇒ nil
105
# File 'src/oracle-database/lib/oracle-database/model/database/patch.rb', line 105 property :execute_after, type: String, default: nil, description: 'Accepts commands or script that will be executed after a patch is applied.'
Properties (Read Only)
Constant Summary
Constants included from MintLogger
MintLogger::DEBUG, MintLogger::ERROR, MintLogger::FATAL, MintLogger::INFO, MintLogger::UNKNOWN, MintLogger::VERBOSE, MintLogger::WARN
Instance Attribute Summary collapse
-
#aru ⇒ Integer
The Patch ARU.
-
#installation ⇒ MintPress::OracleDatabase::Installation
The Installation object associated with this patch.
-
#stage ⇒ Pathname
The location path for the Patch.
Attributes included from Mixins::Properties
#autopush_set_cache, #dynamic_create, #harvest_on_access, #harvest_undefined_only, #harvested, #tree_root
Instance Method Summary collapse
-
#apply ⇒ void
Apply the patch using OPatch utility.
-
#exists? ⇒ TrueClass, FalseClass
Detemine whether the patch has been applied to the OracleWeblogic::Installation with the OPatch utility.
- #find_in_super(iprop) ⇒ Object
- #get_inventory_location ⇒ Object
-
#get_opatch_version ⇒ String
Obtain the version of the OPatch utility installed on the target Installation.
-
#get_opatch_version_numeric(opatch_version) ⇒ Integer
Obtain the version of the OPatch utility installed on the target Installation.
-
#get_stage_opatch_version(opatch_file = "") ⇒ String
Obtain the version of the OPatch patch from stage patch file.
-
#initialize(opts) ⇒ MintPress::OracleDatabase::Patch
constructor
The constructor.
-
#not_already_calling?(prop, obj: self) ⇒ Boolean
Check that find_in_super did not put us in a proc loop!.
- #required_op_version(default) ⇒ Object
-
#rollback ⇒ void
Rollback the patch using OPatch utility.
-
#to_hash ⇒ Hash
Return a Hash representation for the Patch.
-
#update_opatch(opatch_file: nil) ⇒ void
Update the OPatch utility to the latest version specified in the opatch_file.
-
#usage ⇒ String
Example usage of the class.
Methods included from Mixins::Properties
#[], #[]=, #add_validate_report_result, #armour_set_property, #array_contains?, #array_is_a?, #check_autopush, #check_stack_overflow, #clone_property_object, #cloner_handle_single_property, #coerce_single, #contains_as_string?, #display_validate_report_result, #double_initialize?, #dump_to_hash, #find_parent, #find_parent_by_identity, #generate_accessor_functions, #get_canonical_renamed, #get_from_opts, #get_my_name, #get_property, #get_property_item, #has?, included, #initialize_validate_report, #inspect, #is_cloned_object?, #is_mintpress_object?, #is_probably_canonical?, #is_set?, #local_debug, #local_info, #local_verbose, #mintpress_property_definitions, #place_object_by_identity, #process_properties, #prop_set?, #property, #property_definitions, #property_details, #property_is_simple_object?, #push_root!, #require_property, #require_update, #retrieve_docstring, #sanitize, #set_map_dirty, #set_property, #set_property_item, #show_short_array, #strip_defaults!, #synchronize, #uncloned_property_definitions, #update_map, #validate, #validate_generic, #validate_properties, #validate_property, #validate_required, #version_allowed?, #weakref
Methods included from MintLogger::Utils::Common
#boolean_val, #has_value?, #no_value?, #nvl, #path_as_symbol, #ruby_level_to_send
Methods included from MintPress::OracleWeblogic::Utils
#activate_list, #already_traversed, #announce_self, #bean_type, #build_activate_list, #clear_property_sheet_cache, #create_generic, #create_mbean_components, #delete, #destroy_generic, #empty_mbean?, #execute_script, #fast_ls_all, #fast_ls_folder, #fast_ls_object, #fast_ls_object_map, #find_cluster, #find_runtime_path_in_rest, #find_server, #full_url, #get, #get_all_self_names, #get_identity, #get_local_wlst_session, #get_matching_self_names, #get_property_from_target, #get_property_from_target_rest, #get_property_from_target_wlst, #get_property_from_target_wlst_impl, #get_property_sheet, #get_rest_item, #get_rest_url_for_parent, #get_rest_url_for_self, #get_servers, #get_servers_rest, #get_servers_wlst, #get_wl_home, #globmatch?, #handle_create, #http_delete, #http_get, #http_post, #http_put, included, #invalidate_session, #is_meta_object?, #longclass, #massage_return, #mbean_components, #mbean_exists?, #mbean_lookup, #mbean_properties, #mbean_to_hash, #meta_list?, #my_short_name, #perform_method_generic, #perform_runtime_call_generic_rest, #perform_runtime_method_generic, #post, #raise_http_exception, #remove, #request_headers, #reset_activate_list, #rest_activate_change, #rest_create_generic, #rest_create_mbean_components, #rest_destroy_self, #rest_edit_url, #rest_has_changes, #rest_idempotent_create, #rest_locked, #rest_nonedit_url, #rest_start_change, #rest_undo_change, #runtime_introspection, #shortclass, #start_with_async, #state_with_net_ping, #stop_with_async, #to_nested, #wlst_cd_to, #wlst_create_generic, #wlst_destroy_self, #wlst_find_object, #wlst_find_parent_object, #wlst_generic_mbean_update_all, #wlst_idempotent_create, #wlst_update_mbean
Constructor Details
#initialize(opts) ⇒ MintPress::OracleDatabase::Patch
Instance Attribute Details
#aru ⇒ Integer
#installation ⇒ MintPress::OracleDatabase::Installation
#stage ⇒ Pathname
Instance Method Details
#apply ⇒ void
This method returns an undefined value.
Apply the patch using OPatch utility#exists? ⇒ TrueClass, FalseClass
#find_in_super(iprop) ⇒ Object
#get_inventory_location ⇒ Object
#get_opatch_version ⇒ String
#get_opatch_version_numeric(opatch_version) ⇒ Integer
#get_stage_opatch_version(opatch_file = "") ⇒ String
#not_already_calling?(prop, obj: self) ⇒ Boolean
#required_op_version(default) ⇒ Object
#rollback ⇒ void
This method returns an undefined value.
Rollback the patch using OPatch utility#to_hash ⇒ Hash
#update_opatch(opatch_file: nil) ⇒ void
This method returns an undefined value.
Update the OPatch utility to the latest version specified in the opatch_file