Skip to content

Commit e8a3a06

Browse files
CarolynRountreeddsharpe
authored andcommitted
support for WLS 12214 (#425)
1 parent 1ed1f72 commit e8a3a06

File tree

11 files changed

+180
-155
lines changed

11 files changed

+180
-155
lines changed

core/src/main/python/wlsdeploy/aliases/alias_constants.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,11 @@
103103
]
104104
ALIAS_MAP_TYPES = [PROPERTIES, DICTIONARY]
105105

106+
ALIAS_BOOLEAN_TYPES = [
107+
BOOLEAN,
108+
JAVA_LANG_BOOLEAN
109+
]
110+
106111
ALIAS_PRIMITIVE_DATA_TYPES = [
107112
BOOLEAN,
108113
CREDENTIAL,

core/src/main/python/wlsdeploy/aliases/aliases.py

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
from wlsdeploy.aliases.alias_constants import USES_PATH_TOKENS
4747
from wlsdeploy.aliases.alias_constants import VALUE
4848
from wlsdeploy.aliases.alias_constants import WLST_NAME
49+
from wlsdeploy.aliases.alias_constants import WLST_READ_TYPE
4950
from wlsdeploy.aliases.alias_constants import WLST_TYPE
5051
from wlsdeploy.aliases.model_constants import MODEL_LIST_DELIMITER
5152

@@ -1130,6 +1131,40 @@ def get_ignore_attribute_names(self):
11301131
"""
11311132
return self._alias_entries.IGNORE_FOR_MODEL_LIST
11321133

1134+
def get_preferred_model_type(self, location, model_attribute_name):
1135+
"""
1136+
Return the preferred model type, if present, for the alias attribute definition.
1137+
:param location: current location context
1138+
:param model_attribute_name: name of the attribute to look up in model representation
1139+
:return: alias attribute preferred model type or None if not present or attribute not found
1140+
"""
1141+
_method_name = 'get_preferred_model_type'
1142+
self._logger.entering(str(location), model_attribute_name,
1143+
class_name=self._class_name, method_name=_method_name)
1144+
result = None
1145+
attribute_info = self._alias_entries.get_alias_attribute_entry_by_model_name(location, model_attribute_name)
1146+
if attribute_info is not None and PREFERRED_MODEL_TYPE in attribute_info:
1147+
result = attribute_info[PREFERRED_MODEL_TYPE]
1148+
self._logger.exiting(class_name=self._class_name, method_name=_method_name, result=result)
1149+
return result
1150+
1151+
def get_wlst_read_type(self, location, model_attribute_name):
1152+
"""
1153+
Return the aliases attribute WLST_READ_TYPE, which overrides the WLST_TYPE when retrieving the attribute value.
1154+
:param location: The context for the current location in WLST
1155+
:param model_attribute_name: the model name for the WLST attribute
1156+
:return: WLST_READ_TYPE or None if not defined for the attribute in the alias definitions
1157+
"""
1158+
_method_name = 'get_wlst_read_type'
1159+
self._logger.entering(str(location), model_attribute_name,
1160+
class_name=self._class_name, method_name=_method_name)
1161+
result = None
1162+
attribute_info = self._alias_entries.get_alias_attribute_entry_by_model_name(location, model_attribute_name)
1163+
if attribute_info is not None and WLST_READ_TYPE in attribute_info:
1164+
result = attribute_info[WLST_READ_TYPE]
1165+
self._logger.exiting(class_name=self._class_name, method_name=_method_name, result=result)
1166+
return result
1167+
11331168
def decrypt_password(self, text):
11341169
"""
11351170
Encrypt the specified password if encryption is used and the password is encrypted.

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/FileStore.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"DeploymentOrder": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DeploymentOrder", "wlst_path": "WP001", "value": {"default": 1000 }, "wlst_type": "integer" } ],
1111
"Directory": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Directory", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "restart_required": "true" } ],
1212
"DistributionPolicy": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "DistributionPolicy", "wlst_path": "WP001", "value": {"default": "${None:Distributed}"}, "wlst_type": "string", "restart_required": "true" } ],
13+
"FailOverLimit": [ {"version": "[12.2.1.4,)", "wlst_mode": "both", "wlst_name": "FailOverLimit", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "integer" } ],
1314
"FailbackDelaySeconds": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "FailbackDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" } ],
1415
"FileLockingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileLockingEnabled", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "boolean" } ],
1516
"InitialBootDelaySeconds": [ {"version": "[12.2.1,12.2.1.1)", "wlst_mode": "both", "wlst_name": "InitialBootDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" },

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/JDBCStore.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
"DeploymentOrder": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DeploymentOrder", "wlst_path": "WP001", "value": {"default": 1000 }, "wlst_type": "integer" } ],
1515
"DistributionPolicy": [ {"version": "[12.2,)", "wlst_mode": "both", "wlst_name": "DistributionPolicy", "wlst_path": "WP001", "value": {"default": "${None:Distributed}"}, "wlst_type": "string", "restart_required": "true" } ],
1616
"FailbackDelaySeconds": [ {"version": "[12.2,)", "wlst_mode": "both", "wlst_name": "FailbackDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" } ],
17+
"FailOverLimit": [ {"version": "[12.2.1.4,)", "wlst_mode": "both", "wlst_name": "FailOverLimit", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "integer" } ],
1718
"InitialBootDelaySeconds": [ {"version": "[12.2,12.2.1.1)", "wlst_mode": "both", "wlst_name": "InitialBootDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" },
1819
{"version": "[12.2.1.1,)", "wlst_mode": "both", "wlst_name": "InitialBootDelaySeconds", "wlst_path": "WP001", "value": {"default": 60 }, "wlst_type": "long" } ],
1920
"InsertsPerBatchMaximum": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "InsertsPerBatchMaximum", "wlst_path": "WP001", "value": {"default": 20 }, "wlst_type": "integer", "restart_required": "true" } ],

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/JMSSystemResource.json

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,9 @@
8989
"wlst_type": "LoadBalancingParams",
9090
"folders": {},
9191
"attributes": {
92-
"LoadBalancingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoadBalancingEnabled", "wlst_path": "WP001", "value": {"default": "true"}, "wlst_type": "boolean"} ],
93-
"ServerAffinityEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "ServerAffinityEnabled", "wlst_path": "WP001", "value": {"default": "true"}, "wlst_type": "boolean"} ]
92+
"LoadBalancingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoadBalancingEnabled", "wlst_path": "WP001", "value": {"default": "true"}, "wlst_type": "boolean"} ],
93+
"ProducerLoadBalancingPolicy": [ {"version": "[12.2.1.4,)", "wlst_mode": "both", "wlst_name": "ProducerLoadBalancingPolicy", "wlst_path": "WP001", "value": {"default": "${None:Per-Member}"}, "wlst_type": "string"} ],
94+
"ServerAffinityEnabled": [ { "version": "[10,)", "wlst_mode": "both", "wlst_name": "ServerAffinityEnabled", "wlst_path": "WP001", "value": {"default": "true"}, "wlst_type": "boolean"} ]
9495
},
9596
"wlst_attributes_path": "WP001",
9697
"wlst_paths": {
@@ -494,16 +495,17 @@
494495
}
495496
},
496497
"attributes": {
497-
"DefaultTargetingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DefaultTargetingEnabled", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "boolean", "restart_required": "true"} ],
498-
"JNDIPrefix": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "JNDIPrefix", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
499-
"Notes": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
500-
"SAFErrorHandling": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SAFErrorHandling", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "get_method": "LSA", "set_method": "MBEAN.set_saf_error_handling_mbean", "set_mbean_type": "weblogic.j2ee.descriptor.wl.SAFErrorHandlingBean", "restart_required": "true" } ],
501-
"SAFRemoteContext": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SAFRemoteContext", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "get_method": "LSA", "set_method": "MBEAN.set_saf_remote_context_mbean", "set_mbean_type": "weblogic.j2ee.descriptor.wl.SAFRemoteContextBean"} ],
502-
"SubDeploymentName": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SubDeploymentName", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "restart_required": "true" } ],
503-
"TimeToLiveDefault": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "TimeToLiveDefault", "wlst_path": "WP001", "value": {"default": "${0:3600000}" }, "wlst_type": "long" } ],
504-
"UnitOfOrderRouting": [ {"version": "[10,12.2.1.2)", "wlst_mode": "both", "wlst_name": "UnitOfOrderRouting", "wlst_path": "WP001", "value": {"default": "Hash" }, "wlst_type": "string", "get_method": "LSA", "restart_required": "true" } ,
505-
{"version": "[12.2.1.2,)", "wlst_mode": "both", "wlst_name": "UnitOfOrderRouting", "wlst_path": "WP001", "value": {"default": "${None:Hash}" }, "wlst_type": "string", "get_method": "LSA", "restart_required": "true" } ],
506-
"UseSAFTimeToLiveDefault": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UseSAFTimeToLiveDefault", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean" } ]
498+
"DefaultTargetingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DefaultTargetingEnabled", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "boolean", "restart_required": "true"} ],
499+
"ExactlyOnceLoadBalancingPolicy": [ {"version": "[12.2.1.4,)", "wlst_mode": "both", "wlst_name": "ExactlyOnceLoadBalancingPolicy", "wlst_path": "WP001", "value": {"default": "${None:Per-Member}" }, "wlst_type": "string", "restart_required": "true"} ],
500+
"JNDIPrefix": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "JNDIPrefix", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
501+
"Notes": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
502+
"SAFErrorHandling": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SAFErrorHandling", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "get_method": "LSA", "set_method": "MBEAN.set_saf_error_handling_mbean", "set_mbean_type": "weblogic.j2ee.descriptor.wl.SAFErrorHandlingBean", "restart_required": "true" } ],
503+
"SAFRemoteContext": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SAFRemoteContext", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "get_method": "LSA", "set_method": "MBEAN.set_saf_remote_context_mbean", "set_mbean_type": "weblogic.j2ee.descriptor.wl.SAFRemoteContextBean"} ],
504+
"SubDeploymentName": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "SubDeploymentName", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "restart_required": "true" } ],
505+
"TimeToLiveDefault": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "TimeToLiveDefault", "wlst_path": "WP001", "value": {"default": "${0:3600000}" }, "wlst_type": "long" } ],
506+
"UnitOfOrderRouting": [ {"version": "[10,12.2.1.2)", "wlst_mode": "both", "wlst_name": "UnitOfOrderRouting", "wlst_path": "WP001", "value": {"default": "Hash" }, "wlst_type": "string", "get_method": "LSA", "restart_required": "true" } ,
507+
{"version": "[12.2.1.2,)", "wlst_mode": "both", "wlst_name": "UnitOfOrderRouting", "wlst_path": "WP001", "value": {"default": "${None:Hash}" }, "wlst_type": "string", "get_method": "LSA", "restart_required": "true" } ],
508+
"UseSAFTimeToLiveDefault": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UseSAFTimeToLiveDefault", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean" } ]
507509
},
508510
"wlst_attributes_path": "WP001",
509511
"wlst_paths": {

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/MessagingBridge.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"DistributionPolicy": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "DistributionPolicy", "wlst_path": "WP001", "value": {"default": "${None:Distributed}" }, "wlst_type": "string", "restart_required": "true" } ],
1313
"DurabilityEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DurabilityEnabled", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "boolean", "restart_required": "true" } ],
1414
"FailbackDelaySeconds": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "FailbackDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" } ],
15+
"FailOverLimit": [ {"version": "[12.2.1.4,)", "wlst_mode": "both", "wlst_name": "FailOverLimit", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "integer" } ],
1516
"IdleTimeMaximum": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "IdleTimeMaximum", "wlst_path": "WP001", "value": {"default": 60 }, "wlst_type": "integer" } ],
1617
"InitialBootDelaySeconds": [ {"version": "[12.2.1,12.2.1.1)", "wlst_mode": "both", "wlst_name": "InitialBootDelaySeconds", "wlst_path": "WP001", "value": {"default": -1 }, "wlst_type": "long" } ,
1718
{"version": "[12.2.1.1,)", "wlst_mode": "both", "wlst_name": "InitialBootDelaySeconds", "wlst_path": "WP001", "value": {"default": 60 }, "wlst_type": "long" } ],

0 commit comments

Comments
 (0)