Skip to content

Commit 8a4cead

Browse files
remove unused python file
1 parent f406cb3 commit 8a4cead

File tree

3 files changed

+17
-91
lines changed

3 files changed

+17
-91
lines changed

core/src/main/python/discover.py

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,31 +12,32 @@
1212
from java.lang import IllegalArgumentException
1313
from java.lang import IllegalStateException
1414
from java.lang import String
15-
1615
from oracle.weblogic.deploy.aliases import AliasException
1716
from oracle.weblogic.deploy.discover import DiscoverException
1817
from oracle.weblogic.deploy.util import CLAException
1918
from oracle.weblogic.deploy.util import FileUtils
2019
from oracle.weblogic.deploy.util import PyWLSTException
2120
from oracle.weblogic.deploy.util import TranslateException
22-
from oracle.weblogic.deploy.util import WebLogicDeployToolingVersion
2321
from oracle.weblogic.deploy.util import WLSDeployArchive
2422
from oracle.weblogic.deploy.util import WLSDeployArchiveIOException
23+
from oracle.weblogic.deploy.util import WebLogicDeployToolingVersion
24+
from oracle.weblogic.deploy.validate import ValidateException
2525

2626
sys.path.append(os.path.dirname(os.path.realpath(sys.argv[0])))
2727

2828
from wlsdeploy.aliases.wlst_modes import WlstModes
2929
from wlsdeploy.exception import exception_helper
3030
from wlsdeploy.logging.platform_logger import PlatformLogger
3131
from wlsdeploy.util import getcreds
32-
from wlsdeploy.tool.util.variable_injector import VariableInjector
3332
from wlsdeploy.tool.discover import discoverer
3433
from wlsdeploy.tool.discover.deployments_discoverer import DeploymentsDiscoverer
3534
from wlsdeploy.tool.discover.domain_info_discoverer import DomainInfoDiscoverer
3635
from wlsdeploy.tool.discover.multi_tenant_discoverer import MultiTenantDiscoverer
3736
from wlsdeploy.tool.discover.resources_discoverer import ResourcesDiscoverer
3837
from wlsdeploy.tool.discover.topology_discoverer import TopologyDiscoverer
3938
from wlsdeploy.tool.util import filter_helper
39+
from wlsdeploy.tool.util.variable_injector import VariableInjector
40+
from wlsdeploy.tool.validate.validator import Validator
4041
from wlsdeploy.util import wlst_helper
4142
from wlsdeploy.util import model_translator
4243
from wlsdeploy.util.cla_utils import CommandLineArgUtil
@@ -373,25 +374,25 @@ def __check_and_customize_model(model, model_context):
373374
inject_variables_keyword_file()
374375
if inserted:
375376
model = Model(variable_model)
376-
# try:
377-
# validator = Validator(model_context, wlst_mode=__wlst_mode)
378-
#
379-
# # no variables are generated by the discover tool
380-
# validator.validate_in_tool_mode(model.get_model(), variables_file_name=variable_file_name,
381-
# archive_file_name=model_context.get_archive_file_name())
382-
# except ValidateException, ex:
383-
# __logger.warning('WLSDPLY-06015', ex.getLocalizedMessage(), class_name=_class_name, method_name=_method_name)
377+
try:
378+
validator = Validator(model_context, wlst_mode=__wlst_mode)
379+
380+
# no variables are generated by the discover tool
381+
validator.validate_in_tool_mode(model.get_model(), variables_file_name=variable_file_name,
382+
archive_file_name=model_context.get_archive_file_name())
383+
except ValidateException, ex:
384+
__logger.warning('WLSDPLY-06015', ex.getLocalizedMessage(), class_name=_class_name, method_name=_method_name)
384385
return model
385386

386387

387-
def __log_and_exit(exit_code, _class_name, _method_name):
388+
def __log_and_exit(exit_code, class_name, _method_name):
388389
"""
389390
Helper method to log the exiting message and call sys.exit()
390391
:param exit_code: the exit code to use
391-
:param _class_name: the class name to pass to the logger
392+
:param class_name: the class name to pass to the logger
392393
:param _method_name: the method name to pass to the logger
393394
"""
394-
__logger.exiting(result=exit_code, class_name=_class_name, method_name=_method_name)
395+
__logger.exiting(result=exit_code, class_name=class_name, method_name=_method_name)
395396
sys.exit(exit_code)
396397

397398

@@ -444,7 +445,7 @@ def main(args):
444445

445446
except TranslateException, ex:
446447
__logger.severe('WLSDPLY-20024', _program_name, model_context.get_archive_file_name(), ex.getLocalizedMessage(),
447-
error=ex, class_name=_class_name, method_name=_method_name)
448+
error=ex, class_name=_class_name, method_name=_method_name)
448449
__log_and_exit(CommandLineArgUtil.PROG_ERROR_EXIT_CODE, _class_name, _method_name)
449450

450451
__close_archive(model_context)

core/src/main/python/wlsdeploy/util/model_search_helper.py

Lines changed: 0 additions & 76 deletions
This file was deleted.

installer/src/main/lib/variable_keywords.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
"PORT": "port.json",
44
"HOST": "host.json",
55
"URL": "url.json",
6+
"TARGET": "target.json",
67
"TOPOLOGY": "topology.json"
78
}

0 commit comments

Comments
 (0)