featzhang commented on code in PR #7228:
URL: https://github.com/apache/inlong/pull/7228#discussion_r1089869876
##########
inlong-sort/sort-connectors/redis/src/main/java/org/apache/inlong/sort/redis/common/config/RedisOptions.java:
##########
@@ -200,6 +200,81 @@ public class RedisOptions {
.defaultValue(false)
.withDescription("whether to set async lookup.");
+ public static final ConfigOption<String> EXPIRE_TIME =
+ ConfigOptions.key("expire-time")
+ .stringType()
+ .defaultValue("0s")
+ .withDescription("The redis record expired time. If value
set to " +
+ "zero or negative, " +
+ "record in redis will never expired.");
+
+ public static final ConfigOption<Integer> SINK_MAX_RETRIES =
+ ConfigOptions.key("sink.max-retries")
+ .intType()
+ .defaultValue(5)
+ .withDescription("The maximum number of retries when an " +
+ "exception is caught.");
+
+ public static final ConfigOption<Integer> CLUSTER_MAX_TOTAL =
+ ConfigOptions.key("sink.max-connections")
+ .intType()
+ .defaultValue(2)
+ .withDescription("Set the value for connection instances
created " +
+ "in pool.");
+
+ public static final ConfigOption<Integer> CLUSTER_MAX_IDLE =
+ ConfigOptions.key("sink.max-idle-connections")
+ .intType()
+ .defaultValue(1)
+ .withDescription("Set the value for max idle connection " +
+ "instances created in pool.");
+
+ public static final ConfigOption<String> CLUSTER_MAX_WAIT =
+ ConfigOptions.key("sink.max-wait-time")
+ .stringType()
+ .defaultValue("10s")
+ .withDescription("Set the value for max waiting time if
there is " +
+ "no connection resource.");
+
+ public static final ConfigOption<Integer> MAX_CACHE_SIZE =
+ ConfigOptions.key("sink.max-cache-size")
+ .intType()
+ .defaultValue(-1)
+ .withDescription("The maximum number of results cached in
the " +
Review Comment:
This attribute is not used, I removed it.
##########
inlong-sort/sort-connectors/redis/src/main/java/org/apache/inlong/sort/redis/common/config/SchemaMappingMode.java:
##########
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.inlong.sort.redis.common.config;
+
+/**
+ * The MappingMode between Sql Schema and {@link RedisDataType}.
+ */
+public enum SchemaMappingMode {
+
+ /**
+ * The DYNAMIC mode witch mapping a {@link java.util.Map} to {@link
RedisDataType}.
+ * There are two members in DYNAMIC mode: <br/>
+ * the first member is Redis key. <br/>
+ * the second member is a {@link java.util.Map} object, witch will be
iterated, <br/>
Review Comment:
done
--
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]