diff --git a/README.md b/README.md index 55651455b..cabaabe6e 100644 --- a/README.md +++ b/README.md @@ -213,6 +213,8 @@ participants: # global `logLevel` = `info` then Geth would receive `3`, Besu would receive `INFO`, etc.) # If this is not emptystring, then this value will override the global `logLevel` setting to allow for fine-grained control # over a specific participant's logging + # Set to "custom" (Besu only) to disable global logging settings and leave it up to the client configuration, + # for example, when using a custom log4j2.xml file el_log_level: "" # The storage type for the EL client: "full" or "archive" @@ -313,13 +315,10 @@ participants: # global `logLevel` = `info` then Teku would receive `INFO`, Prysm would receive `info`, etc.) # If this is not emptystring, then this value will override the global `logLevel` setting to allow for fine-grained control # over a specific participant's logging + # Set to "custom" (Teku only) to disable global logging settings and leave it up to the client configuration, + # for example, when using a custom log4j.xml file cl_log_level: "" - # Used to disable global logging settings for this participant and leave it up to the configuration to set logging configurations, - # for example, when using a custom log4j.xml file in Teku - # NOTE: this option is only supported by Teku at the moment - custom_log_config: false - # A list of optional extra env_vars the cl container should spin up with cl_extra_env_vars: {} diff --git a/network_params.yaml b/network_params.yaml index 217359444..e73b85a0a 100644 --- a/network_params.yaml +++ b/network_params.yaml @@ -33,7 +33,6 @@ participants: cl_max_mem: 0 supernode: false use_separate_vc: true - custom_log_config: false # Validator vc_type: lighthouse vc_image: sigp/lighthouse:latest diff --git a/src/cl/teku/teku_launcher.star b/src/cl/teku/teku_launcher.star index e4b8c35c4..003280c6a 100644 --- a/src/cl/teku/teku_launcher.star +++ b/src/cl/teku/teku_launcher.star @@ -29,6 +29,7 @@ VERBOSITY_LEVELS = { constants.GLOBAL_LOG_LEVEL.info: "INFO", constants.GLOBAL_LOG_LEVEL.debug: "DEBUG", constants.GLOBAL_LOG_LEVEL.trace: "TRACE", + constants.GLOBAL_LOG_LEVEL.custom: "CUSTOM", } @@ -223,8 +224,7 @@ def get_beacon_config( # ^^^^^^^^^^^^^^^^^^^ METRICS CONFIG ^^^^^^^^^^^^^^^^^^^^^ ] - if participant.custom_log_config: - # ignores log_level and expects a custom log config + if log_level == "CUSTOM": cmd.append("--log-destination=CUSTOM") else: cmd.append("--logging=" + log_level) diff --git a/src/el/besu/besu_launcher.star b/src/el/besu/besu_launcher.star index 12f58692d..b7c1fd898 100644 --- a/src/el/besu/besu_launcher.star +++ b/src/el/besu/besu_launcher.star @@ -27,6 +27,7 @@ VERBOSITY_LEVELS = { constants.GLOBAL_LOG_LEVEL.info: "INFO", constants.GLOBAL_LOG_LEVEL.debug: "DEBUG", constants.GLOBAL_LOG_LEVEL.trace: "TRACE", + constants.GLOBAL_LOG_LEVEL.custom: "CUSTOM", } @@ -142,7 +143,12 @@ def get_config( cmd = [ "besu", - "--logging=" + log_level, + ] + + if log_level != "CUSTOM": + cmd.append("--logging=" + log_level) + + cmd += [ "--data-path=" + EXECUTION_DATA_DIRPATH_ON_CLIENT_CONTAINER, "--host-allowlist=*", "--rpc-http-enabled=true", diff --git a/src/package_io/constants.star b/src/package_io/constants.star index c7a18f1cb..ca248bf5a 100644 --- a/src/package_io/constants.star +++ b/src/package_io/constants.star @@ -40,6 +40,7 @@ GLOBAL_LOG_LEVEL = struct( warn="warn", debug="debug", trace="trace", + custom="custom", ) CLIENT_TYPES = struct( diff --git a/src/package_io/input_parser.star b/src/package_io/input_parser.star index 0c95a2948..4f7c40460 100644 --- a/src/package_io/input_parser.star +++ b/src/package_io/input_parser.star @@ -519,7 +519,6 @@ def input_parser(plan, input_args): cl_volume_size=participant["cl_volume_size"], cl_extra_env_vars=participant["cl_extra_env_vars"], cl_tolerations=participant["cl_tolerations"], - custom_log_config=participant["custom_log_config"], use_separate_vc=participant["use_separate_vc"], vc_type=participant["vc_type"], vc_image=participant["vc_image"], @@ -1596,7 +1595,6 @@ def default_participant(): "cl_min_mem": 0, "cl_max_mem": 0, "cl_force_restart": False, - "custom_log_config": False, "supernode": False, "use_separate_vc": None, "vc_type": "", diff --git a/src/package_io/sanity_check.star b/src/package_io/sanity_check.star index 851be2642..e61af3855 100644 --- a/src/package_io/sanity_check.star +++ b/src/package_io/sanity_check.star @@ -35,7 +35,6 @@ PARTICIPANT_CATEGORIES = { "cl_force_restart", "supernode", "use_separate_vc", - "custom_log_config", "vc_type", "vc_image", "vc_binary_path", @@ -119,7 +118,6 @@ PARTICIPANT_MATRIX_PARAMS = { "cl_min_mem", "cl_max_mem", "use_separate_vc", - "custom_log_config", "vc_type", "vc_image", "vc_binary_path",