Skip to content

Commit 7e017fa

Browse files
committed
Degrade log statement in experiment_server
This is called every 2 second from the everest client polling for states, and implies too much noise for the INFO level. Changing to DEBUG level. (cherry picked from commit 48c7e5a)
1 parent 53db271 commit 7e017fa

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

src/ert/dark_storage/endpoints/experiment_server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ def _check_user(credentials: HTTPBasicCredentials) -> None:
139139

140140

141141
def _log(request: Request) -> None:
142-
logging.getLogger(EVERSERVER).info(
142+
logging.getLogger(EVERSERVER).debug(
143143
f"{request.scope['path']} entered from "
144144
f"{request.client.host if request.client else 'unknown host'} "
145145
f"with HTTP {request.method}"

tests/everest/test_logging.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,8 @@ def test_logging_setup(copy_math_func_test_data_to_tmp):
6969
# Avoid cases where optimization finished before we get a chance to check that
7070
# the everest server has started
7171
if endpoint_logs:
72-
assert (
73-
"everserver INFO: /experiment_server/status entered from" in endpoint_logs
74-
)
72+
assert "everserver INFO: Everserver starting" in endpoint_logs
73+
assert "everserver INFO: ExperimentRunner done" in endpoint_logs
7574

7675

7776
def test_that_cleanup_logging_is_idempotent(monkeypatch):

0 commit comments

Comments
 (0)