You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2020/03/29 15:33:33 UTC

[GitHub] [incubator-shardingsphere] TaoZhiMLND commented on a change in pull request #4945: make key-generator as a spring bean on spring namespace.

TaoZhiMLND commented on a change in pull request #4945: make key-generator as a spring bean on spring namespace.
URL: https://github.com/apache/incubator-shardingsphere/pull/4945#discussion_r399813763
 
 

 ##########
 File path: sharding-core/sharding-core-api/src/main/java/org/apache/shardingsphere/api/config/sharding/KeyGeneratorConfiguration.java
 ##########
 @@ -20,27 +20,21 @@
 import com.google.common.base.Preconditions;
 import com.google.common.base.Strings;
 import lombok.Getter;
-import org.apache.shardingsphere.underlying.common.config.TypeBasedSPIConfiguration;
-
-import java.util.Properties;
+import org.apache.shardingsphere.spi.keygen.ShardingKeyGenerator;
 
 /**
  * Key generator configuration.
 */
 @Getter
-public final class KeyGeneratorConfiguration extends TypeBasedSPIConfiguration {
+public final class KeyGeneratorConfiguration {
     
     private final String column;
     
-    public KeyGeneratorConfiguration(final String type, final String column) {
-        super(type);
-        Preconditions.checkArgument(!Strings.isNullOrEmpty(column), "Column is required.");
-        this.column = column;
-    }
+    private final ShardingKeyGenerator keyGenerator;
 
 Review comment:
   ShardingKeyGenerator has renamed to KeyGenerateAlgorithm.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services