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 2022/01/17 08:27:24 UTC

[GitHub] [shardingsphere] zjcnb opened a new issue #14828: Maybe load TableMetaData are some problems.

zjcnb opened a new issue #14828:
URL: https://github.com/apache/shardingsphere/issues/14828


   ## Bug Report
   
   **For English only**, other languages will not accept.
   
   Before report a bug, make sure you have:
   
   - Searched open and closed [GitHub issues](https://github.com/apache/shardingsphere/issues).
   - Read documentation: [ShardingSphere Doc](https://shardingsphere.apache.org/document/current/en/overview).
   
   Please pay attention on issues you submitted, because we maybe need more details. 
   If no response anymore and we cannot reproduce it on current information, we will **close it**.
   
   Please answer these questions before submitting your issue. Thanks!
   
   ### Which version of ShardingSphere did you use?
   
   `master`
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   
   `ShardingSphere-JDBC`
   
   ### Expected behavior
   
   Load all tables and persist zookeeper.
   
   ### Actual behavior
   
   I have five tables, but only load three tables.
   
   ### Reason analyze (If you can)
   
   ![image](https://user-images.githubusercontent.com/33742097/149733494-a6b7a8dd-b381-4dc0-9471-d7f41992ccb1.png)
   
   ### Configuration
   ```
   server:
     port: 8899
   spring:
     shardingsphere:
       props:
         sql-show: true
       datasource:
         ds0:
           username: root
           password: 123456
           jdbc-url: jdbc:mysql://127.0.0.1:3306/ds0
           type: com.zaxxer.hikari.HikariDataSource
           driver-class-name: com.mysql.cj.jdbc.Driver
         name: ds0
   
       rules:
         sharding:
           sharding-algorithms:
             # 分表算法
             table-inline:
               type: INTERVAL
               props:
                 datetime-pattern: yyyy-MM-dd HH:mm:ss
                 datetime-lower: 2020-01-17 00:00:00
                 datetime-upper: 2023-01-17 00:00:00
                 datetime-interval-amount: 7
                 sharding-suffix-pattern: yyyyMMdd
           tables:
             user:
               actual-data-nodes: ds0.user$->{20210107..20230117}
               # 分库策略
               table-strategy:
                 standard:
                   sharding-column: create_time
                   sharding-algorithm-name: table-inline
   
       mode:
         type: cluster
         repository:
           type: zookeeper
           props:
             namespace: governance_ds
             server-lists: localhost:2181
             retryIntervalMilliseconds: 500
             timeToLiveSeconds: 60
             maxRetries: 3
             operationTimeoutMilliseconds: 500
         overwrite: true
   ```
   ### Tables
   
   ```
   CREATE TABLE `t_order1` (
     `id` int NOT NULL AUTO_INCREMENT,
     `user_id` int DEFAULT NULL,
     `order_id` int DEFAULT NULL,
     `cloumn` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL,
     PRIMARY KEY (`id`) USING BTREE
   ) ENGINE=InnoDB AUTO_INCREMENT=1233452 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;
   
   CREATE TABLE `t_order2` (
     `id` int NOT NULL AUTO_INCREMENT,
     `user_id` int DEFAULT NULL,
     `order_id` int DEFAULT NULL,
     `cloumn` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL,
     PRIMARY KEY (`id`) USING BTREE
   ) ENGINE=InnoDB AUTO_INCREMENT=1233452 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci ROW_FORMAT=DYNAMIC;
   
   CREATE TABLE `t_user0` (
     `id` bigint NOT NULL AUTO_INCREMENT,
     `name` varchar(50) DEFAULT NULL,
     `sharding_key` int DEFAULT NULL,
     PRIMARY KEY (`id`)
   ) ENGINE=InnoDB AUTO_INCREMENT=680740116461236232 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
   
   CREATE TABLE `user20220117` (
     `id` bigint NOT NULL AUTO_INCREMENT,
     `name` varchar(50) DEFAULT NULL,
     `sharding_key` int DEFAULT NULL,
     `create_time` date DEFAULT NULL,
     PRIMARY KEY (`id`)
   ) ENGINE=InnoDB AUTO_INCREMENT=680740116461236232 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
   
   CREATE TABLE `user20220118` (
     `id` bigint NOT NULL AUTO_INCREMENT,
     `name` varchar(50) DEFAULT NULL,
     `sharding_key` int DEFAULT NULL,
     `create_time` date DEFAULT NULL,
     PRIMARY KEY (`id`)
   ) ENGINE=InnoDB AUTO_INCREMENT=680740116461236232 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
   ```


-- 
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



[GitHub] [shardingsphere] zjcnb commented on issue #14828: Maybe load TableMetaData are some problems.

Posted by GitBox <gi...@apache.org>.
zjcnb commented on issue #14828:
URL: https://github.com/apache/shardingsphere/issues/14828#issuecomment-1014428876


   Got it, thx.


-- 
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



[GitHub] [shardingsphere] tuichenchuxin commented on issue #14828: Maybe load TableMetaData are some problems.

Posted by GitBox <gi...@apache.org>.
tuichenchuxin commented on issue #14828:
URL: https://github.com/apache/shardingsphere/issues/14828#issuecomment-1014326303


   Because of this cofig `actual-data-nodes: ds0.user$->{20210107..20230117}`
   So when loading table about user, SchemaLoader will just load for table `user20210107` but this table is not exist.


-- 
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



[GitHub] [shardingsphere] zjcnb closed issue #14828: Maybe load TableMetaData are some problems.

Posted by GitBox <gi...@apache.org>.
zjcnb closed issue #14828:
URL: https://github.com/apache/shardingsphere/issues/14828


   


-- 
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



[GitHub] [shardingsphere] tuichenchuxin commented on issue #14828: Maybe load TableMetaData are some problems.

Posted by GitBox <gi...@apache.org>.
tuichenchuxin commented on issue #14828:
URL: https://github.com/apache/shardingsphere/issues/14828#issuecomment-1014262541


   I want to investigate this issue.


-- 
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