Skip to content

Add logging max size and count for rotation #2229

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 3 commits into from
Feb 25, 2021
Merged
Show file tree
Hide file tree
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
44 changes: 22 additions & 22 deletions docs/charts/index.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@ entries:
weblogic-operator:
- apiVersion: v1
appVersion: 3.2.0
created: "2021-02-23T09:10:09.881083-05:00"
created: "2021-02-25T14:46:05.542187-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 9107dcfa259abc0f615a63529ac4e4aa0216d5d356baf16b4bc551e0a72fab3c
digest: 398c4b215350f28ac20a74475acdbaef603e2c899d5f244d898e1d148db6f35e
name: weblogic-operator
type: application
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.2.0.tgz
version: 3.2.0
- apiVersion: v1
appVersion: 3.1.3
created: "2021-02-23T09:10:09.880353-05:00"
created: "2021-02-25T14:46:05.539704-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: e306bd590dbe84400c6b5bb7a64325330e597223dff63792bb5811c9cfae10ac
name: weblogic-operator
Expand All @@ -23,7 +23,7 @@ entries:
version: 3.1.3
- apiVersion: v1
appVersion: 3.1.2
created: "2021-02-23T09:10:09.87918-05:00"
created: "2021-02-25T14:46:05.538076-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 2d8b77038ba870cc66ddd45e07a593a5ac3159c8b9531b5309688028b5268a5f
name: weblogic-operator
Expand All @@ -33,7 +33,7 @@ entries:
version: 3.1.2
- apiVersion: v1
appVersion: 3.1.1
created: "2021-02-23T09:10:09.878279-05:00"
created: "2021-02-25T14:46:05.536707-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: d839cb7bbce4421a59cd9c3df64b1df8649eeebcb6c6b7be34fec25ad00aa141
name: weblogic-operator
Expand All @@ -43,7 +43,7 @@ entries:
version: 3.1.1
- apiVersion: v1
appVersion: 3.1.0
created: "2021-02-23T09:10:09.87555-05:00"
created: "2021-02-25T14:46:05.535579-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 9e105bec11bab249973370a4d5e653f9104cd9fbaaa0c2090fb173805fb3a692
name: weblogic-operator
Expand All @@ -52,123 +52,123 @@ entries:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.1.0.tgz
version: 3.1.0
- apiVersion: v1
created: "2021-02-23T09:10:09.874384-05:00"
created: "2021-02-25T14:46:05.534523-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 557d0df9958bbdd2f456134d8aff9edf33900bb65774fb0baf2054abd49fdc97
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.4.tgz
version: 3.0.4
- apiVersion: v1
created: "2021-02-23T09:10:09.873665-05:00"
created: "2021-02-25T14:46:05.533712-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 83a0ac84a033ddd9939d4bc5884cc60b22225d7326c43ce8e54a6f403b453814
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.3.tgz
version: 3.0.3
- apiVersion: v1
created: "2021-02-23T09:10:09.872927-05:00"
created: "2021-02-25T14:46:05.532509-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: fa3af5d21f858ff93cc7d58664a6eb0a920207af09e4c669a7ffb12e9e15b88d
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.2.tgz
version: 3.0.2
- apiVersion: v1
created: "2021-02-23T09:10:09.87219-05:00"
created: "2021-02-25T14:46:05.531682-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: aa2b2afe75305bd69f6b07d61e64a37d3bfd249074c81f6a999cef6b4a217fd0
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.1.tgz
version: 3.0.1
- apiVersion: v1
created: "2021-02-23T09:10:09.871333-05:00"
created: "2021-02-25T14:46:05.530712-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 6540a3a7c6a1c34fcf2ff66679947a1964a35e61232b2a8dea3da087a2d5411d
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.0.tgz
version: 3.0.0
- apiVersion: v1
created: "2021-02-23T09:10:09.870633-05:00"
created: "2021-02-25T14:46:05.5299-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 5f4cd8f4f3282b52b5e90a1169f26986e8272671845053606ade9c855fb04151
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-3.0.0-rc1.tgz
version: 3.0.0-rc1
- apiVersion: v1
created: "2021-02-23T09:10:09.869589-05:00"
created: "2021-02-25T14:46:05.528848-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: e3596b2380b264a0a70ba438858ca9af102a79689bf2e21e237eb63ea2997d66
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.6.0.tgz
version: 2.6.0
- apiVersion: v1
created: "2021-02-23T09:10:09.868503-05:00"
created: "2021-02-25T14:46:05.527672-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: fe41421b7dc45dc8a3b2888d3a626a37f5d3c8e1fa292fb6699deedc5e1db33d
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.5.0.tgz
version: 2.5.0
- apiVersion: v1
created: "2021-02-23T09:10:09.867664-05:00"
created: "2021-02-25T14:46:05.526784-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: b36bd32083f67453a62d089a2c09ce38e6655d88ac8a7b38691230c55c40e672
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.4.0.tgz
version: 2.4.0
- apiVersion: v1
created: "2021-02-23T09:10:09.866564-05:00"
created: "2021-02-25T14:46:05.525648-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: a3eafe4c2c6ff49384e56421201e59a3737d651af8d5b605b87a19eb1f6f1dc3
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.3.1.tgz
version: 2.3.1
- apiVersion: v1
created: "2021-02-23T09:10:09.863446-05:00"
created: "2021-02-25T14:46:05.521184-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: cbc6caaa6eb28e3c7e906ede14b2ae511a0b35fc12a8e3ab629155b09993e8b2
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.3.0.tgz
version: 2.3.0
- apiVersion: v1
created: "2021-02-23T09:10:09.862171-05:00"
created: "2021-02-25T14:46:05.520208-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 23d5a1c554fa8211cc1e86b7ade09460917cb2069e68fb4bfdddafc8db44fdcd
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.2.1.tgz
version: 2.2.1
- apiVersion: v1
created: "2021-02-23T09:10:09.856003-05:00"
created: "2021-02-25T14:46:05.519086-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: bba303686cb55d84fe8c0d693a2436e7e686b028085b56e012f6381699a3911f
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.2.0.tgz
version: 2.2.0
- apiVersion: v1
created: "2021-02-23T09:10:09.850986-05:00"
created: "2021-02-25T14:46:05.518174-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 391e23c0969ada5f0cd2a088ddc6f11f237f57521801ed3925db2149a8437a0d
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.1.tgz
version: "2.1"
- apiVersion: v1
created: "2021-02-23T09:10:09.845295-05:00"
created: "2021-02-25T14:46:05.517295-05:00"
description: Helm chart for configuring the WebLogic operator.
digest: 298acda78ab73db6b7ba6f2752311bfa40c65874e03fb196b70976192211c1a5
name: weblogic-operator
urls:
- https://oracle.github.io/weblogic-kubernetes-operator/charts/weblogic-operator-2.0.1.tgz
version: 2.0.1
generated: "2021-02-23T09:10:09.843742-05:00"
generated: "2021-02-25T14:46:05.515789-05:00"
Binary file modified docs/charts/weblogic-operator-3.2.0.tgz
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ spec:
value: "false"
- name: "JAVA_LOGGING_LEVEL"
value: {{ .javaLoggingLevel | quote }}
- name: "JAVA_LOGGING_MAXSIZE"
value: {{ .javaLoggingFileSizeLimit | default 20000000 | quote }}
- name: "JAVA_LOGGING_COUNT"
value: {{ .javaLoggingFileCount | default 10 | quote }}
- name: ISTIO_ENABLED
value: {{ .istioEnabled | quote }}
{{- if .remoteDebugNodePortEnabled }}
Expand Down
11 changes: 10 additions & 1 deletion kubernetes/charts/weblogic-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,19 @@ elasticSearchHost: "elasticsearch.default.svc.cluster.local"
# This parameter is ignored if 'elkIntegrationEnabled' is false.
elasticSearchPort: 9200

# javaLoggingLevel specifies the Java logging level for the operator.
# javaLoggingLevel specifies the Java logging level for the operator. This affects the operator pod's
# log output and the contents of log files in the container's /logs/ directory.
# Valid values are: "SEVERE", "WARNING", "INFO", "CONFIG", "FINE", "FINER", and "FINEST".
javaLoggingLevel: "INFO"

# javaLoggingFileSizeLimit specifies the maximum size in bytes of the Java logging files in the operator container's
# /logs/ directory.
javaLoggingFileSizeLimit: 20000000

# javaLoggingFileCount specifies the number of Java logging files to preserve in the operator container's /logs/
# directory as the files are rotated.
javaLoggingFileCount: 10

# nodeSelector specifies a matching rule that the Kubernetes scheduler will use when selecting the node
# where the operator will run. If the nodeSelector value is specified, then this content will be added to
# the operator's deployment. See https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector
Expand Down
2 changes: 1 addition & 1 deletion operator/scripts/logstash.conf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
input {
file {
path => "/logs/operator.log"
path => "/logs/operator*.log"
start_position => "beginning"
type => "weblogic-operator"
}
Expand Down
4 changes: 3 additions & 1 deletion operator/scripts/logstash.properties
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,6 @@ java.util.logging.ConsoleHandler.level=INFO
java.util.logging.ConsoleHandler.formatter=oracle.kubernetes.operator.logging.LoggingFormatter
java.util.logging.FileHandler.level=INFO
java.util.logging.FileHandler.formatter=oracle.kubernetes.operator.logging.LoggingFormatter
java.util.logging.FileHandler.pattern=/logs/operator.log
java.util.logging.FileHandler.pattern=/logs/operator%g.log
java.util.logging.FileHandler.limit=JAVA_LOGGING_MAXSIZE
java.util.logging.FileHandler.count=JAVA_LOGGING_COUNT
5 changes: 4 additions & 1 deletion operator/scripts/operator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ if [[ ! -z "$JAVA_LOGGING_LEVEL" ]]; then
fi
fi

sed -i -e "s|JAVA_LOGGING_MAXSIZE|${JAVA_LOGGING_MAXSIZE:-20000000}|g" $LOGGING_CONFIG
sed -i -e "s|JAVA_LOGGING_COUNT|${JAVA_LOGGING_COUNT:-10}|g" $LOGGING_CONFIG

if [ "${MOCK_WLS}" == 'true' ]; then
MOCKING_WLS="-DmockWLS=true"
fi
Expand All @@ -64,7 +67,7 @@ cp /operator/logstash.conf /logs/logstash.conf
# assumption is that we have mounted a volume on /logs which is also visible to
# the logstash container/pod.

# Container memory optimizaton flags
# Container memory optimization flags
HEAP="-XshowSettings:vm"

# Start operator
Expand Down