featzhang commented on code in PR #35:
URL: 
https://github.com/apache/flink-connector-http/pull/35#discussion_r3015350819


##########
flink-connector-http/src/main/java/org/apache/flink/connector/http/config/HttpConnectorConfigConstants.java:
##########
@@ -164,4 +164,15 @@ public final class HttpConnectorConfigConstants {
             SOURCE_RETRY_EXP_DELAY_PREFIX + "max-backoff";
     public static final String SOURCE_RETRY_EXP_DELAY_MULTIPLIER =
             SOURCE_RETRY_EXP_DELAY_PREFIX + "backoff-multiplier";
+
+    // -------------- Error logging configuration --------------
+
+    public static final String ERROR_LOG_LEVEL = FLINK_CONNECTOR_HTTP + 
"error.log.level";

Review Comment:
   Thanks for the feedback. I've raised a Jira to document the motivation: 
https://issues.apache.org/jira/browse/FLINK-39367.
   
     To clarify the reasoning behind introducing a separate mechanism rather 
than extending http.logging.level:
   
     The existing http.logging.level controls content verbosity — how much 
detail (headers, body) is logged for every HTTP request and response. It is 
always emitted at DEBUG level and is intended for development-time 
troubleshooting.
   
     The new http.error.log.* configuration addresses a different concern: 
error severity — at what SLF4J level (ERROR/WARN/INFO) failures are surfaced. 
These are orthogonal dimensions:
   
     - A user may want minimal content (no body) but still want errors logged 
at ERROR level so that alerting systems can detect failures. With only 
http.logging.level, this is impossible because all output is DEBUG.
     - Conversely, a user may want MAX content detail but only at DEBUG to 
avoid noise in monitoring dashboards.
   
     Extending http.logging.level to also control log severity would conflate 
two unrelated concerns into a single option, making the configuration harder to 
reason about. Keeping them separate matches the pattern used in other Flink 
connectors where error handling and general logging are configured 
independently.
   
     One additional behavioral detail worth noting: HttpErrorLogger respects 
continue-on-error. When continue-on-error=true, errors are tolerated and only a 
DEBUG message is emitted — logging at ERROR/WARN in that case would be 
misleading since the connector is functioning as configured. The configured 
error log level only applies when the exception will actually be thrown.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to