eemario commented on code in PR #27430:
URL: https://github.com/apache/flink/pull/27430#discussion_r2703068406


##########
flink-core/src/main/java/org/apache/flink/configuration/HistoryServerOptions.java:
##########
@@ -137,6 +126,24 @@ public class HistoryServerOptions {
             "Specify the option in only one HistoryServer instance to avoid 
errors caused by multiple instances simultaneously cleaning up remote files, ";
     private static final String CONFIGURE_CONSISTENT =
             "Or you can keep the value of this configuration consistent across 
them. ";
+    private static final String LEGACY_NOTE_MESSAGE =
+            "Note: This option applies only to legacy job archives created 
before the introduction of application archiving (FLINK-38761).";
+    private static final String RETAINED_STRATEGY_MESSAGE =
+            "Archived entities will be removed if their TTL has expired or the 
retention count limit has been reached. ";
+
+    /** If this option is enabled then deleted job archives are also deleted 
from HistoryServer. */
+    public static final ConfigOption<Boolean> 
HISTORY_SERVER_CLEANUP_EXPIRED_JOBS =
+            key("historyserver.archive.clean-expired-jobs")
+                    .booleanType()
+                    .defaultValue(false)
+                    .withDescription(
+                            Description.builder()
+                                    .text(
+                                            "Whether HistoryServer should 
cleanup jobs that are no longer present in the archive directory defined by %s. 
",
+                                            
code(HISTORY_SERVER_ARCHIVE_DIRS.key()))
+                                    .linebreak()
+                                    .text(LEGACY_NOTE_MESSAGE)

Review Comment:
   Hi @davidradl Thank you for raising this point. After some thought, I 
believe there are some nuances worth clarifying regarding the History Server.
   
   These configuration options specifically apply to job archives generated 
prior to FLINK-38761 (most likely before Flink 2.4). Until that legacy format 
reaches its end-of-service, the History Server must remain capable of parsing 
such archives and providing users with the necessary configuration parameters 
to control their behavior. Therefore, these options are not deprecated and will 
not be removed in the next major version.
   
   That said, if you feel this approach is problematic or have concerns about 
maintaining these options, I’m happy to discuss further!



-- 
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