[ https://issues.apache.org/jira/browse/HDFS-10533?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15332569#comment-15332569 ]
Chris Nauroth commented on HDFS-10533: -------------------------------------- Is this targeted to 3.0.0-alpha1 so that there is freedom to make a backward-incompatible change? If so, then I know at least Hive and Falcon would be impacted, and possibly Oozie too. https://github.com/apache/hive/blob/release-2.0.1/shims/0.23/src/main/java/org/apache/hadoop/hive/shims/Hadoop23Shims.java#L1262-L1279 https://github.com/apache/falcon/blob/release-0.9-rc0/replication/src/main/java/org/apache/falcon/replication/FeedReplicator.java#L187-L239 https://github.com/apache/oozie/blob/release-4.2.0/sharelib/distcp/src/main/java/org/apache/oozie/action/hadoop/DistcpMain.java#L74-L96 If downstream projects expect a stable interface, then we should update the interface audience and stability annotations too. > Make DistCpOptions class immutable > ---------------------------------- > > Key: HDFS-10533 > URL: https://issues.apache.org/jira/browse/HDFS-10533 > Project: Hadoop HDFS > Issue Type: Improvement > Components: distcp > Reporter: Mingliang Liu > Assignee: Mingliang Liu > > Currently the {{DistCpOptions}} class encapsulates all DistCp options, which > may be set from command-line (via the {{OptionsParser}}) or may be set > manually (eg construct an instance and call setters). As there are multiple > option fields and more (e.g. [HDFS-9868], [HDFS-10314]) to add, validating > them can be cumbersome. Ideally, the {{DistCpOptions}} object should be > immutable. The benefits are: > # {{DistCpOptions}} is simple and easier to use and share, plus it scales well > # validation is automatic, e.g. manually constructed {{DistCpOptions}} gets > validated before usage > # validation error message is well-defined which does not depend on the order > of setters > This jira is to track the effort of making the {{DistCpOptions}} immutable by > using a Builder pattern for creation. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org