You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Yifan Cai (Jira)" <ji...@apache.org> on 2020/04/27 18:51:00 UTC
[jira] [Created] (CASSANDRA-15764) Optimize logging with lazy log
parameter evaluation
Yifan Cai created CASSANDRA-15764:
-------------------------------------
Summary: Optimize logging with lazy log parameter evaluation
Key: CASSANDRA-15764
URL: https://issues.apache.org/jira/browse/CASSANDRA-15764
Project: Cassandra
Issue Type: Improvement
Reporter: Yifan Cai
Assignee: Yifan Cai
Multiple logging statements in the source evaluate methods and use the return values as log parameter.
It does no harm when the log level permits for the statement.
However, for the logs that are permitted, the evaluation is a wastes of CPU.
The log parameters are not needed, but still being evaluated!
For such cases, lazy evaluation (by leveraging lambda) can be introduced to skip competing the string parameter.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org