Skip to content

Commit c1acc07

Browse files
committed
WDT-771: Adding missing MBeans
1 parent 45be11a commit c1acc07

File tree

13 files changed

+173
-11
lines changed

13 files changed

+173
-11
lines changed

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

+6
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,10 @@
5151
from wlsdeploy.aliases.alias_constants import WLST_TYPE
5252
from wlsdeploy.aliases.flattened_folder import FlattenedFolder
5353
from wlsdeploy.aliases.location_context import LocationContext
54+
from wlsdeploy.aliases.model_constants import ALLOW_LIST
5455
from wlsdeploy.aliases.model_constants import APP_DEPLOYMENTS
5556
from wlsdeploy.aliases.model_constants import APPLICATION
57+
from wlsdeploy.aliases.model_constants import CALLOUT
5658
from wlsdeploy.aliases.model_constants import DOMAIN_INFO
5759
from wlsdeploy.aliases.model_constants import DOMAIN_INFO_ALIAS
5860
from wlsdeploy.aliases.model_constants import JOLT_CONNECTION_POOL
@@ -61,6 +63,7 @@
6163
from wlsdeploy.aliases.model_constants import OHS
6264
from wlsdeploy.aliases.model_constants import OPSS_INITIALIZATION
6365
from wlsdeploy.aliases.model_constants import RCU_DB_INFO
66+
from wlsdeploy.aliases.model_constants import REMOTE_CONSOLE_HELPER
6467
from wlsdeploy.aliases.model_constants import RESOURCE_MANAGER
6568
from wlsdeploy.aliases.model_constants import RESOURCES
6669
from wlsdeploy.aliases.model_constants import SYSTEM_COMPONENT
@@ -96,6 +99,8 @@ class AliasEntries(object):
9699

97100
__topology_top_level_folders = [
98101
'AdminConsole',
102+
ALLOW_LIST,
103+
CALLOUT,
99104
'CdiContainer',
100105
'Cluster',
101106
'EmbeddedLDAP',
@@ -107,6 +112,7 @@ class AliasEntries(object):
107112
'Machine',
108113
'MigratableTarget',
109114
'NMProperties',
115+
REMOTE_CONSOLE_HELPER,
110116
"RestfulManagementServices",
111117
'Security',
112118
'SecurityConfiguration',

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

+3
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
ACTIVE_DIRECTORY_AUTHENTICATOR = 'ActiveDirectoryAuthenticator'
1717
ADJUDICATOR = 'Adjudicator'
18+
ALLOW_LIST = 'AllowList'
1819
ADMIN_CONSOLE = 'AdminConsole'
1920
ADMIN_PASSWORD = 'AdminPassword'
2021
ADMIN_SERVER_NAME = 'AdminServerName'
@@ -30,6 +31,7 @@
3031
AUTHENTICATION_PROVIDER = 'AuthenticationProvider'
3132
AUTHORIZER = 'Authorizer'
3233
CALCULATED_LISTEN_PORTS = 'CalculatedListenPorts'
34+
CALLOUT = 'Callout'
3335
CAPACITY = 'Capacity'
3436
CDI_CONTAINER = 'CdiContainer'
3537
CERT_PATH_PROVIDER = 'CertPathProvider'
@@ -234,6 +236,7 @@
234236
RCU_STG_INFO = 'storageXMLLocation'
235237
RCU_TEMP_TBLSPACE = 'rcu_temp_tablespace'
236238
RCU_VARIABLES = 'rcu_variables'
239+
REMOTE_CONSOLE_HELPER = 'RemoteConsoleHelper'
237240
REMOTE_DOMAIN = 'RemoteDomain'
238241
REMOTE_HOST = 'RemoteHost'
239242
REMOTE_PASSWORD = 'RemotePassword'

core/src/main/python/wlsdeploy/tool/discover/topology_discoverer.py

+40-1
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,9 @@ def discover(self):
129129

130130
model_folder_name, folder_result = self._get_ws_securities()
131131
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
132+
133+
model_top_folder_name, callouts = self.get_callouts()
134+
discoverer.add_to_model_if_not_empty(self._dictionary, model_top_folder_name, callouts)
132135
finally:
133136
if current_tree is not None:
134137
current_tree()
@@ -139,6 +142,39 @@ def discover(self):
139142
_logger.exiting(class_name=_class_name, method_name=_method_name)
140143
return self._dictionary
141144

145+
def get_callouts(self):
146+
"""
147+
Discover the Callouts in the domain.
148+
:return: model name for the dictionary and the dictionary containing the cluster information
149+
"""
150+
_method_name = 'get_callouts'
151+
_logger.entering(class_name=_class_name, method_name=_method_name)
152+
153+
result = OrderedDict()
154+
model_top_folder_name = model_constants.CALLOUT
155+
location = LocationContext(self._base_location)
156+
location.append_location(model_top_folder_name)
157+
callouts = self._find_names_in_folder(location)
158+
if callouts is not None:
159+
_logger.info('WLSDPLY-06671', len(callouts), class_name=_class_name, method_name=_method_name)
160+
typedef = self._model_context.get_domain_typedef()
161+
name_token = self._aliases.get_name_token(location)
162+
for callout in callouts:
163+
if typedef.is_filtered(location, callout):
164+
_logger.info('WLSDPLY-06673', typedef.get_domain_type(), callout, class_name=_class_name,
165+
method_name=_method_name)
166+
else:
167+
_logger.info('WLSDPLY-06672', callout, class_name=_class_name, method_name=_method_name)
168+
location.add_name_token(name_token, callout)
169+
result[callout] = OrderedDict()
170+
self._populate_model_parameters(result[callout], location)
171+
location.remove_name_token(name_token)
172+
location.pop_location()
173+
174+
_logger.exiting(class_name=_class_name, method_name=_method_name, result=model_top_folder_name)
175+
return model_top_folder_name, result
176+
177+
142178
def get_clusters(self):
143179
"""
144180
Discover the Clusters in the domain.
@@ -356,6 +392,8 @@ def discover_domain_parameters(self):
356392

357393
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.ADMIN_CONSOLE)
358394
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
395+
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.ALLOW_LIST)
396+
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
359397
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.CDI_CONTAINER)
360398
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
361399
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.JMX)
@@ -368,7 +406,8 @@ def discover_domain_parameters(self):
368406
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
369407
model_folder_name, folder_result = self._get_nm_properties()
370408
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
371-
409+
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.REMOTE_CONSOLE_HELPER)
410+
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
372411
model_folder_name, folder_result = self.discover_domain_mbean(model_constants.RESTFUL_MANAGEMENT_SERVICES)
373412
discoverer.add_to_model_if_not_empty(self._dictionary, model_folder_name, folder_result)
374413

core/src/main/python/wlsdeploy/tool/util/wlst_helper.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ def set_with_cmo(self, wlst_name, wlst_value, masked=False):
179179
Set the specified attribute using the corresponding cmo set method (e.g., cmo.setListenPort()).
180180
:param wlst_name: the WLST attribute name
181181
:param wlst_value: the WLST value
182-
:param masked: whether or not to mask the wlst_value from the log files.
182+
:param masked: whether to mask the wlst_value from the log files.
183183
:raises: Exception for the specified tool type: if a WLST error occurs
184184
"""
185185
_method_name = 'set_with_cmo'
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"copyright": "Copyright (c) 2023, Oracle Corporation and/or its affiliates.",
3+
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
4+
"version": "[14.1.2,)",
5+
"wlst_type": "AllowList",
6+
"online_bean": "weblogic.management.configuration.AllowListMBean",
7+
"default_name_value": "${NO_NAME_0:%DOMAIN%}",
8+
"folders": {},
9+
"attributes": {
10+
"AllowListRecordingEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "AllowListRecordingEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ],
11+
"AllowListViolationAction": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "AllowListViolationAction", "wlst_path": "WP001", "default_value": "${__NULL__:ignore}", "wlst_type": "string" } ],
12+
"CoherenceClassesAlwaysBlock": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "CoherenceClassesAlwaysBlock", "wlst_path": "WP001", "default_value": true, "wlst_type": "boolean" } ],
13+
"Notes": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
14+
"SerialPropFilePollingInterval": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "SerialPropFilePollingInterval", "wlst_path": "WP001", "default_value": "60", "wlst_type": "integer" } ],
15+
"SynthesizeAllowListEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "SynthesizeAllowListEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ]
16+
},
17+
"wlst_attributes_path": "WP001",
18+
"wlst_paths": {
19+
"WP001": "/AllowList/%ALLOWLIST%"
20+
}
21+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"copyright": "Copyright (c) 2023, Oracle Corporation and/or its affiliates.",
3+
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
4+
"version": "[14.1.2,)",
5+
"wlst_type": "Callout${:s}",
6+
"online_bean": "weblogic.management.configuration.CalloutMBean",
7+
"child_folders_type": "multiple",
8+
"folders": {},
9+
"attributes": {
10+
"Argument": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Argument", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
11+
"ClassName": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "ClassName", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
12+
"HookPoint": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "HookPoint", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
13+
"Notes": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ]
14+
},
15+
"wlst_attributes_path": "WP001",
16+
"wlst_paths": {
17+
"WP001": "/Callout${:s}/%CALLOUT%"
18+
}
19+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"copyright": "Copyright (c) 2023, Oracle Corporation and/or its affiliates.",
3+
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
4+
"version": "[14.1.2,)",
5+
"wlst_type": "RemoteConsoleHelper",
6+
"online_bean": "weblogic.management.configuration.RemoteConsoleHelperMBean",
7+
"default_name_value": "${NO_NAME_0:%DOMAIN%}",
8+
"folders": {},
9+
"attributes": {
10+
"ContextPath": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "ContextPath", "wlst_path": "WP001", "default_value": "${consolehelper:console}", "wlst_type": "string" } ],
11+
"CookieName": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "CookieName", "wlst_path": "WP001", "default_value": "REMOTECONSOLESESSION", "wlst_type": "string" } ],
12+
"Notes": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
13+
"ProtectedCookieEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "ProtectedCookieEnabled", "wlst_path": "WP001", "default_value": true, "wlst_type": "boolean" } ],
14+
"SessionTimeout": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "SessionTimeout", "wlst_path": "WP001", "default_value": "600", "wlst_type": "integer" } ],
15+
"TokenTimeout": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "TokenTimeout", "wlst_path": "WP001", "default_value": "60", "wlst_type": "integer" } ]
16+
},
17+
"wlst_attributes_path": "WP001",
18+
"wlst_paths": {
19+
"WP001": "/RemoteConsoleHelper/%REMOTECONSOLEHELPER%"
20+
}
21+
}

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

+21-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
"folders": {
7878
"DataSourceLogFile": {
7979
"wlst_type": "DataSourceLogFile",
80-
"default_name_value": "${NO_NAME_0:%SERVER}",
80+
"default_name_value": "${NO_NAME_0:%SERVER%}",
8181
"folders": {},
8282
"attributes": {
8383
"BufferSizeKb": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "BufferSizeK${b:B}", "wlst_path": "WP001", "default_value": 8, "wlst_type": "integer" } ],
@@ -992,7 +992,26 @@
992992
"wlst_type": "ServerDiagnosticConfig",
993993
"online_bean": "weblogic.management.configuration.WLDFServerDiagnosticMBean",
994994
"default_name_value": "${NO_NAME_0:%SERVER%}",
995-
"folders": {},
995+
"folders": {
996+
"WldfBuiltinWatchConfiguration": {
997+
"wlst_type": "${Wldf:WLDF}BuiltinWatchConfiguration",
998+
"version": "[14.1.2,)",
999+
"default_name_value": "${NO_NAME_0:%SERVER%}",
1000+
"folders": {},
1001+
"attributes": {
1002+
"Notes": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
1003+
"StuckThreadDiagnosticImageNotificationEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadDiagnosticImageNotificationEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ],
1004+
"StuckThreadThreadDumpActionCount": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionCount", "wlst_path": "WP001", "default_value": 3, "wlst_type": "integer" } ],
1005+
"StuckThreadThreadDumpActionDelaySeconds": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionDelaySeconds", "wlst_path": "WP001", "default_value": 10, "wlst_type": "integer" } ],
1006+
"StuckThreadThreadDumpActionEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ],
1007+
"StuckThreadWatchEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadWatchEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ]
1008+
},
1009+
"wlst_attributes_path": "WP001",
1010+
"wlst_paths": {
1011+
"WP001": "/Server${:s}/%SERVER%/ServerDiagnosticConfig/%SERVERDIAGNOSTICCONFIG%/${Wldf:WLDF}BuiltinWatchConfiguration/%WLDFBUILTINWATCHCONFIGURATION%"
1012+
}
1013+
}
1014+
},
9961015
"attributes": {
9971016
"DataRetirementEnabled": [ {"version": "[10,)" , "wlst_mode": "both", "wlst_name": "DataRetirementEnabled", "wlst_path": "WP001", "default_value": "true", "wlst_type": "boolean"} ],
9981017
"DataRetirementTestModeEnabled": [ {"version": "[10,)" , "wlst_mode": "offline", "wlst_name": "DataRetirementTestModeEnabled", "wlst_path": "WP001", "default_value": "false", "wlst_type": "boolean"} ],

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

+20-1
Original file line numberDiff line numberDiff line change
@@ -1002,7 +1002,26 @@
10021002
"online_bean": "weblogic.management.configuration.WLDFServerDiagnosticMBean",
10031003
"default_name_value": "${NO_NAME_0:%SERVERTEMPLATE%}",
10041004
"version": "[12.1.2,)",
1005-
"folders": {},
1005+
"folders": {
1006+
"WldfBuiltinWatchConfiguration": {
1007+
"wlst_type": "${Wldf:WLDF}BuiltinWatchConfiguration",
1008+
"version": "[14.1.2,)",
1009+
"default_name_value": "${NO_NAME_0:%SERVERTEMPLATE%}",
1010+
"folders": {},
1011+
"attributes": {
1012+
"Notes": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "default_value": null, "wlst_type": "string" } ],
1013+
"StuckThreadDiagnosticImageNotificationEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadDiagnosticImageNotificationEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ],
1014+
"StuckThreadThreadDumpActionCount": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionCount", "wlst_path": "WP001", "default_value": 3, "wlst_type": "integer" } ],
1015+
"StuckThreadThreadDumpActionDelaySeconds": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionDelaySeconds", "wlst_path": "WP001", "default_value": 10, "wlst_type": "integer" } ],
1016+
"StuckThreadThreadDumpActionEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadThreadDumpActionEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ],
1017+
"StuckThreadWatchEnabled": [ {"version": "[14.1.2,)", "wlst_mode": "both", "wlst_name": "StuckThreadWatchEnabled", "wlst_path": "WP001", "default_value": false, "wlst_type": "boolean" } ]
1018+
},
1019+
"wlst_attributes_path": "WP001",
1020+
"wlst_paths": {
1021+
"WP001": "/ServerTemplate${:s}/%SERVERTEMPLATE%/ServerDiagnosticConfig/%SERVERDIAGNOSTICCONFIG%/${Wldf:WLDF}BuiltinWatchConfiguration/%WLDFBUILTINWATCHCONFIGURATION%"
1022+
}
1023+
}
1024+
},
10061025
"attributes": {
10071026
"DataRetirementEnabled": [ {"version": "[12.1.2,)", "wlst_mode": "both", "wlst_name": "DataRetirementEnabled", "wlst_path": "WP001", "default_value": "true", "wlst_type": "boolean" } ],
10081027
"DataRetirementTestModeEnabled": [ {"version": "[12.1.2,)", "wlst_mode": "offline", "wlst_name": "DataRetirementTestModeEnabled", "wlst_path": "WP001", "default_value": "false", "wlst_type": "boolean" } ],

core/src/main/resources/oracle/weblogic/deploy/messages/wlsdeploy_rb.properties

+3
Original file line numberDiff line numberDiff line change
@@ -933,6 +933,9 @@ WLSDPLY-06667=Skipping {0} Managed Executor Service Template {1}
933933
WLSDPLY-06668=Skipping {0} Managed Scheduled Executor Service {1}
934934
WLSDPLY-06669=Skipping {0} Managed Thread Factory Template {1}
935935
WLSDPLY-06670=Skipping {0} Web Service Security {1}
936+
WLSDPLY-06671=Discovering {0} callouts
937+
WLSDPLY-06672=Adding Callout {0}
938+
WLSDPLY-06673=Skipping {0} Callout {1}
936939

937940
# multi_tenant_discoverer.py, multi_tenant_resources_dsi
938941
WLSDPLY-06700=Discover Multi-tenant

core/src/test/python/aliases_test.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -867,9 +867,7 @@ def testIsValidModelFolderName(self):
867867

868868
for folder in top_level_topology_folders:
869869
result, message = self.aliases.is_valid_model_folder_name(location, folder)
870-
self.assertEqual(result, ValidationCodes.VALID)
871-
872-
return
870+
self.assertEqual(result == ValidationCodes.VALID or result == ValidationCodes.VERSION_INVALID, True)
873871

874872
def testBooleanDefaultValues(self):
875873
location = LocationContext().append_location(FOLDERS.RESTFUL_MANAGEMENT_SERVICES, DOMAIN='mydomain')

0 commit comments

Comments
 (0)