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/11/21 04:29:34 UTC

[GitHub] [shardingsphere] Waylon-Firework opened a new issue, #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Waylon-Firework opened a new issue, #22306:
URL: https://github.com/apache/shardingsphere/issues/22306

   ## Question
   
   Upgrade 4.1.1 to 5.2.1, I got an error
   
   ```
   org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'myTestController': Unsatisfied dependency expressed through method 'setMyTestService' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'myTestServiceImpl': Unsatisfied dependency expressed through method 'setMyTestDao' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'myTestDao' defined in file [/Users/waylon/Project/fjlandao/whale/server/account/target/classes/com/fjlandao/whale/server/account/dao/MyTestDao.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Uns
 atisfied dependency expressed through method 'sqlSessionFactory' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'shardingSphereDataSource' defined in class path resource [org/apache/shardingsphere/spring/boot/ShardingSphereAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [javax.sql.DataSource]: Factory method 'shardingSphereDataSource' threw exception; nested exception is org.yaml.snakeyaml.error.YAMLException: Unable to find getter for property 'tenantColumn' on object com.alibaba.druid.wall.WallFilter@60df7989:java.lang.reflect.InvocationTargetException
   
   ```
   


-- 
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.apache.org

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


[GitHub] [shardingsphere] RaigorJiang closed issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by "RaigorJiang (via GitHub)" <gi...@apache.org>.
RaigorJiang closed issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error
URL: https://github.com/apache/shardingsphere/issues/22306


-- 
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] Waylon-Firework commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by GitBox <gi...@apache.org>.
Waylon-Firework commented on issue #22306:
URL: https://github.com/apache/shardingsphere/issues/22306#issuecomment-1322363654

   5.1.2 is normal


-- 
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] linghengqian commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

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

   @Waylon-Firework 
   - Duplicate With https://github.com/apache/shardingsphere/issues/21211#issuecomment-1268667396 . If you only use the Druid base attributes, you'll find that everything works fine.
   
   - I assume you have a PR, right? 🤔


-- 
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] Waylon-Firework commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by GitBox <gi...@apache.org>.
Waylon-Firework commented on issue #22306:
URL: https://github.com/apache/shardingsphere/issues/22306#issuecomment-1321454035

   ```
   spring:
     config:
       activate:
         on-profile: dev
     application:
       name: testApp
     shardingsphere:
       props:
         sql:
           show: true
       datasource:
         names: test-0,test-1
         whale-0:
           driver-class-name: com.mysql.cj.jdbc.Driver
           url: jdbc:mysql://${my-sql-host}:${my-sql-host-port}/test-0
           username: root
           password: 
           type: com.alibaba.druid.pool.DruidDataSource
           initialSize: 5
           minIdle: 5
           maxActive: 20
           maxWait: 60000
           timeBetweenEvictionRunsMillis: 60000
           minEvictableIdleTimeMillis: 300000
           validationQuery: SELECT 1 FROM DUAL
           testWhileIdle: true
           testOnBorrow: false
           testOnReturn: false
           poolPreparedStatements: false
           filters: stat,wall,slf4j
           maxPoolPreparedStatementPerConnectionSize: 20
           useGlobalDataSourceStat: true
           connectionProperties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=500
         whale-1:
           driver-class-name: com.mysql.cj.jdbc.Driver
           url: jdbc:mysql://${my-sql-host}:${my-sql-host-port}/test-1
           username: root
           password: 
           type: com.alibaba.druid.pool.DruidDataSource
           initialSize: 5
           minIdle: 5
           maxActive: 20
           maxWait: 60000
           timeBetweenEvictionRunsMillis: 60000
           minEvictableIdleTimeMillis: 300000
           validationQuery: SELECT 1 FROM DUAL
           testWhileIdle: true
           testOnBorrow: false
           testOnReturn: false
           poolPreparedStatements: false
           filters: stat,wall,slf4j
           maxPoolPreparedStatementPerConnectionSize: 20
           useGlobalDataSourceStat: true
           connectionProperties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=500
       rules:
         sharding:
           tables:
             my_test:
               key-generator:
                 column: id
                 type: SNOWFLAKE
               actual-data-nodes: test-$->{0..1}.my_test_$->{0..1}
               database-strategy:
                 inline:
                   sharding‐column: id
                   algorithm-expression: test-$->{id % 2}
               table-strategy:
                 inline:
                   sharding‐column: id
                   algorithm-expression: my_test_$->{(Integer)((id % 4) / 2)}
           key-generators:
             snowflake:
               column: id
               type: SNOWFLAKE
   ```


-- 
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] Waylon-Firework commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by GitBox <gi...@apache.org>.
Waylon-Firework commented on issue #22306:
URL: https://github.com/apache/shardingsphere/issues/22306#issuecomment-1322335871

   If remove "filters: stat,wall,slf4j", it works. But if we do this, the druid feature will miss.


-- 
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] Waylon-Firework closed issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by GitBox <gi...@apache.org>.
Waylon-Firework closed issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error
URL: https://github.com/apache/shardingsphere/issues/22306


-- 
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] RaigorJiang commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by "RaigorJiang (via GitHub)" <gi...@apache.org>.
RaigorJiang commented on issue #22306:
URL: https://github.com/apache/shardingsphere/issues/22306#issuecomment-1407542047

   Closed for duplicate of #21211


-- 
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] Waylon-Firework commented on issue #22306: Upgrade 4.1.1 to 5.2.1, I got an error

Posted by GitBox <gi...@apache.org>.
Waylon-Firework commented on issue #22306:
URL: https://github.com/apache/shardingsphere/issues/22306#issuecomment-1321988009

   ```
       rules:
         sharding:
           key-generators:
             snowflake:
               type: SNOWFLAKE
               props:
                 worker-id: 123
   ```
   加上这个后好了


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