Skip to content

Commit

Permalink
[doc] Fix duplicate possible values in the configuration doc. (#3821)
Browse files Browse the repository at this point in the history
  • Loading branch information
LinMingQiang authored Jul 28, 2024
1 parent c9e62d7 commit 59e0ae1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 36 deletions.
4 changes: 2 additions & 2 deletions docs/layouts/shortcodes/generated/core_configuration.html
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@
<td><h5>partition.expiration-strategy</h5></td>
<td style="word-wrap: break-word;">values-time</td>
<td><p>Enum</p></td>
<td>Specifies the expiration strategy for partition expiration.<br />Possible values:<ul><li>values-time: A partition expiration policy that compares the time extracted from the partition value with the current time.</li></ul><ul><li>update-time: A partition expiration policy that compares the last update time of the partition with the current time.</li></ul><br /><br />Possible values:<ul><li>"values-time": The strategy compares the time extracted from the partition value with the current time.</li><li>"update-time": The strategy compares the last update time of the partition with the current time.</li></ul></td>
<td>The strategy determines how to extract the partition time and compare it with the current time.<br /><br />Possible values:<ul><li>"values-time": This strategy compares the time extracted from the partition value with the current time.</li><li>"update-time": This strategy compares the last update time of the partition with the current time.</li></ul></td>
</tr>
<tr>
<td><h5>partition.expiration-time</h5></td>
Expand Down Expand Up @@ -748,7 +748,7 @@
<td><h5>streaming-read-mode</h5></td>
<td style="word-wrap: break-word;">(none)</td>
<td><p>Enum</p></td>
<td>The mode of streaming read that specifies to read the data of table file or log<br /><br />Possible values:<br /><ul><li>file: Reads from the data of table file store.</li></ul><ul><li>log: Read from the data of table log store.</li></ul><br /><br />Possible values:<ul><li>"log": Reads from the log store.</li><li>"file": Reads from the file store.</li></ul></td>
<td>The mode of streaming read that specifies to read the data of table file or log.<br /><br />Possible values:<ul><li>"log": Read from the data of table log store.</li><li>"file": Read from the data of table file store.</li></ul></td>
</tr>
<tr>
<td><h5>streaming-read-overwrite</h5></td>
Expand Down
40 changes: 6 additions & 34 deletions paimon-common/src/main/java/org/apache/paimon/CoreOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -707,20 +707,7 @@ public class CoreOptions implements Serializable {
.enumType(PartitionExpireStrategy.class)
.defaultValue(PartitionExpireStrategy.VALUES_TIME)
.withDescription(
Description.builder()
.text(
"Specifies the expiration strategy for partition expiration.")
.linebreak()
.text("Possible values:")
.list(
text(
PartitionExpireStrategy.VALUES_TIME.value
+ ": A partition expiration policy that compares the time extracted from the partition value with the current time."))
.list(
text(
PartitionExpireStrategy.UPDATE_TIME.value
+ ": A partition expiration policy that compares the last update time of the partition with the current time."))
.build());
"The strategy determines how to extract the partition time and compare it with the current time.");

public static final ConfigOption<Duration> PARTITION_EXPIRATION_TIME =
key("partition.expiration-time")
Expand Down Expand Up @@ -898,22 +885,7 @@ public class CoreOptions implements Serializable {
.enumType(StreamingReadMode.class)
.noDefaultValue()
.withDescription(
Description.builder()
.text(
"The mode of streaming read that specifies to read the data of table file or log")
.linebreak()
.linebreak()
.text("Possible values:")
.linebreak()
.list(
text(
StreamingReadMode.FILE.getValue()
+ ": Reads from the data of table file store."))
.list(
text(
StreamingReadMode.LOG.getValue()
+ ": Read from the data of table log store."))
.build());
"The mode of streaming read that specifies to read the data of table file or log.");

public static final ConfigOption<Duration> CONSUMER_EXPIRATION_TIME =
key("consumer.expiration-time")
Expand Down Expand Up @@ -2249,8 +2221,8 @@ public InlineElement getDescription() {

/** Specifies the type for streaming read. */
public enum StreamingReadMode implements DescribedEnum {
LOG("log", "Reads from the log store."),
FILE("file", "Reads from the file store.");
LOG("log", "Read from the data of table log store."),
FILE("file", "Read from the data of table file store.");

private final String value;
private final String description;
Expand Down Expand Up @@ -2601,11 +2573,11 @@ public InlineElement getDescription() {
public enum PartitionExpireStrategy implements DescribedEnum {
VALUES_TIME(
"values-time",
"The strategy compares the time extracted from the partition value with the current time."),
"This strategy compares the time extracted from the partition value with the current time."),

UPDATE_TIME(
"update-time",
"The strategy compares the last update time of the partition with the current time.");
"This strategy compares the last update time of the partition with the current time.");

private final String value;

Expand Down

0 comments on commit 59e0ae1

Please sign in to comment.