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 2021/08/30 08:24:01 UTC

[GitHub] [shardingsphere] soulasuna commented on a change in pull request #12099: Refactor shadow rule and modify shadow value generic type.

soulasuna commented on a change in pull request #12099:
URL: https://github.com/apache/shardingsphere/pull/12099#discussion_r698288889



##########
File path: shardingsphere-features/shardingsphere-shadow/shardingsphere-shadow-core/src/main/java/org/apache/shardingsphere/shadow/algorithm/shadow/column/ColumnRegexMatchShadowAlgorithm.java
##########
@@ -81,11 +81,11 @@ private void checkOperation() {
     }
     
     @Override
-    public boolean isShadow(final Collection<String> shadowTableNames, final PreciseColumnShadowValue<String> shadowValue) {
+    public boolean isShadow(final Collection<String> shadowTableNames, final PreciseColumnShadowValue<Comparable<?>> shadowValue) {
         boolean containTable = shadowTableNames.contains(shadowValue.getLogicTableName());

Review comment:
       Thanks.
   Method `isShadow()` in the algorithm is used to determine whether the sql contains shadow coloring. 
   Shadow tables and shadow algorithms are separately configured and referenced by ID. 
   If the user customizes the algorithm, he needs to get the configured shadow tables to customize his own judgment algorithm. 
   So the beginning of `isContainTable` is not used.




-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org