Skip to content

Commit 59f6303

Browse files
committed
Added a alias JSON file for Log as a root folder
1 parent fbd263a commit 59f6303

File tree

4 files changed

+71
-0
lines changed

4 files changed

+71
-0
lines changed

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ class AliasEntries(object):
8080
'JMX': 'JMX',
8181
'JTA': 'JTA',
8282
'Library': 'Library',
83+
'Log': 'Log',
8384
'Machine': 'Machine',
8485
'MailSession': 'MailSession',
8586
'MessagingBridge': 'MessagingBridge',
@@ -110,6 +111,7 @@ class AliasEntries(object):
110111
'Cluster',
111112
'JMX',
112113
'JTA',
114+
'Log',
113115
'Machine',
114116
'MigratableTarget',
115117
"RestfulManagementServices",

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@
131131
LDAP_X509_IDENTITY_ASSERTER = 'LDAPX509IdentityAsserter'
132132
LIBRARY = 'Library'
133133
LOAD_BALANCING_PARAMS = 'LoadBalancingParams'
134+
LOG = 'Log'
134135
LOG_ACTION = 'LogAction'
135136
MACHINE = 'Machine'
136137
MAIL_SESSION = 'MailSession'
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
{
2+
"copyright": "Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.",
3+
"license": "The Universal Permissive License (UPL), Version 1.0",
4+
"wlst_type": "Log",
5+
"folders": {},
6+
"attributes": {
7+
"BufferSizeKb": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "BufferSizeKb", "wlst_path": "WP001", "value": {"default": 8 }, "wlst_type": "integer"} ],
8+
"DateFormatPattern": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DateFormatPattern", "wlst_path": "WP001", "value": {"default": "MMM d, yyyy, h:mm:ss,S a z" }, "wlst_type": "string" } ],
9+
"DomainLogBroadcastFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DomainLogBroadcastFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
10+
"DomainLogBroadcastSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DomainLogBroadcastSeverity", "wlst_path": "WP001", "value": {"default": "Notice"}, "wlst_type": "string" } ],
11+
"DomainLogBroadcasterBufferSize": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DomainLogBroadcasterBufferSize", "wlst_path": "WP001", "value": {"default": 1 }, "wlst_type": "integer"} ],
12+
"FileCount": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileCount", "wlst_path": "WP001", "value": {"default": 7 }, "wlst_type": "integer"} ],
13+
"FileMinSize": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileMinSize", "wlst_path": "WP001", "value": {"default": 500 }, "wlst_type": "integer"} ],
14+
"FileName": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileName", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
15+
"FileTimeSpan": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileTimeSpan", "wlst_path": "WP001", "value": {"default": 24 }, "wlst_type": "integer"} ],
16+
"FileTimeSpanFactor": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FileTimeSpanFactor", "wlst_path": "WP001", "value": {"default": 3600000 }, "wlst_type": "long" } ],
17+
"Log4jLoggingEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Log4jLoggingEnabled", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean"} ],
18+
"LogFileFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LogFileFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
19+
"LogFileRotationDir": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LogFileRotationDir", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
20+
"LogFileSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LogFileSeverity", "wlst_path": "WP001", "value": {"default": "Trace" }, "wlst_type": "string" } ],
21+
"LogMonitoringEnabled": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringEnabled", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "string" } ],
22+
"LogMonitoringIntervalSecs": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringIntervalSecs", "wlst_path": "WP001", "value": {"default": 30 }, "wlst_type": "integer"} ],
23+
"LogMonitoringMaxThrottleMessageSignatureCount": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringMaxThrottleMessageSignatureCount", "wlst_path": "WP001", "value": {"default": 1000 }, "wlst_type": "integer"} ],
24+
"LogMonitoringThrottleMessageLength": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringThrottleMessageLength", "wlst_path": "WP001", "value": {"default": 50 }, "wlst_type": "integer"} ],
25+
"LogMonitoringThrottleThreshold": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringThrottleThreshold", "wlst_path": "WP001", "value": {"default": 1500 }, "wlst_type": "integer"} ],
26+
"LoggerSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverity", "wlst_path": "WP001", "value": {"default": "Info" }, "wlst_type": "string" } ],
27+
"LoggerSeverityProperties": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverityProperties", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
28+
"MemoryBufferFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
29+
"MemoryBufferSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferSeverity", "wlst_path": "WP001", "value": {"default": "Trace" }, "wlst_type": "string" } ],
30+
"MemoryBufferSize": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferSize", "wlst_path": "WP001", "value": {"default": 10 }, "wlst_type": "integer"} ],
31+
"Notes": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Notes", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
32+
"NumberOfFilesLimited": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "NumberOfFilesLimited", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "boolean"} ],
33+
"PlatformLoggerLevels": [ {"version": "[12.1.3,)", "wlst_mode": "both", "wlst_name": "PlatformLoggerLevels", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
34+
"RedirectStderrToServerLogEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "RedirectStderrToServerLogEnabled", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean"} ],
35+
"RedirectStdoutToServerLogEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "RedirectStdoutToServerLogEnabled", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean"} ],
36+
"RotateLogOnStartup": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "RotateLogOnStartup", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "boolean"} ],
37+
"RotationTime": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "RotationTime", "wlst_path": "WP001", "value": {"default": "00:00" }, "wlst_type": "string" } ],
38+
"RotationType": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "RotationType", "wlst_path": "WP001", "value": {"default": "bySize"}, "wlst_type": "string" } ],
39+
"ServerLoggingBridgeUseParentLoggersEnabled": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "ServerLoggingBridgeUseParentLoggersEnabled", "wlst_path": "WP001", "value": {"default": "false" }, "wlst_type": "boolean"} ],
40+
"StacktraceDepth": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StacktraceDepth", "wlst_path": "WP001", "value": {"default": 5 }, "wlst_type": "integer"} ],
41+
"StdoutFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StdoutFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
42+
"StdoutFormat": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StdoutFormat", "wlst_path": "WP001", "value": {"default": "standard"}, "wlst_type": "string" } ],
43+
"StdoutLogStack": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StdoutLogStack", "wlst_path": "WP001", "value": {"default": "true" }, "wlst_type": "boolean"} ],
44+
"StdoutSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StdoutSeverity", "wlst_path": "WP001", "value": {"default": "Notice"}, "wlst_type": "string" } ]
45+
},
46+
"wlst_attributes_path": "WP001",
47+
"wlst_paths": {
48+
"WP001": "/Log/%DOMAIN%"
49+
}
50+
}
51+

core/src/test/python/aliases_test.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1130,6 +1130,23 @@ def testIssue50Fix(self):
11301130

11311131
return
11321132

1133+
def testIssue57Fix(self):
1134+
location = LocationContext().append_location(FOLDERS.LOG)
1135+
token = self.aliases.get_name_token(location)
1136+
location.add_name_token(token, 'DemoDomain')
1137+
1138+
# NOTE: The FOLDERS.LOG folder is only visible in ONLINE mode, so technically
1139+
# this should fail...but it doesn't because we don't currently have anything
1140+
# that deals with "wlst_mode": "<wlst-mode>" at the folder level.
1141+
default_value = self.aliases.get_model_attribute_default_value(location, 'RotateLogOnStartup')
1142+
expected = 'true'
1143+
self.assertEqual(default_value, expected)
1144+
1145+
default_value = self.online_aliases.get_model_attribute_default_value(location, 'RotateLogOnStartup')
1146+
self.assertEqual(default_value, expected)
1147+
1148+
return
1149+
11331150
def testGetModelAttributeName(self):
11341151
location=LocationContext().append_location(FOLDERS.JMS_SYSTEM_RESOURCE)
11351152
token = self.aliases.get_name_token(location)

0 commit comments

Comments
 (0)