Skip to content

Delete machines once, after templates are loaded #1436

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions core/src/main/python/wlsdeploy/tool/create/domain_creator.py
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ def __create_ws_security(self, location):
self.logger.exiting(class_name=self.__class_name, method_name=_method_name)
return

def __create_machines(self, location):
def __create_machines(self, location, delete_now=True):
"""
Create the /Machine and /UnixMachine folder objects, if any.
:param location: the location to use
Expand All @@ -888,9 +888,10 @@ def __create_machines(self, location):
unix_machine_nodes = dictionary_utils.get_dictionary_element(self._topology, UNIX_MACHINE)

if len(machine_nodes) > 0:
self._create_named_mbeans(MACHINE, machine_nodes, location, log_created=True)
self._create_named_mbeans(MACHINE, machine_nodes, location, log_created=True, delete_now=delete_now)
if len(unix_machine_nodes) > 0:
self._create_named_mbeans(UNIX_MACHINE, unix_machine_nodes, location, log_created=True)
self._create_named_mbeans(UNIX_MACHINE, unix_machine_nodes, location, log_created=True,
delete_now=delete_now)
self.logger.exiting(class_name=self.__class_name, method_name=_method_name)
return

Expand All @@ -907,7 +908,7 @@ def __create_machines_clusters_and_servers(self, delete_now=True):
location.add_name_token(domain_name_token, self._domain_name)
self.logger.entering(str_helper.to_string(location), class_name=self.__class_name, method_name=_method_name)

self.__create_machines(location)
self.__create_machines(location, delete_now=delete_now)
#
# In order for source domain provisioning to work with dynamic clusters, we have to provision
# the ServerTemplates. There is a cyclical dependency between Server Template and Clusters so we
Expand Down