joeywang310 opened a new issue #11056:
URL: https://github.com/apache/shardingsphere/issues/11056


   **my yaml config** 
   `
   sharding:
           sharding-algorithms:
             database_inline:
               props:
                 algorithm-expression: ds_${user_id % 2}
               type: INLINE
             table_inline:
               props:
                 algorithm-expression: t_order_${order_id % 2}
               type: INLINE
             balance_trade_record_db_class_based:
               props:
                 strategy: COMPLEX
                 algorithm_class_name: 
com.ypshengxian.account.server.infrastructure.config.shardingjdbc.BalanceDatabaseShardingAlgorithm
               type: CLASS_BASED
             balance_trade_record_table_class_based:
               type: CLASS_BASED
               props:
                 strategy: COMPLEX
                 algorithm_class_name: 
com.ypshengxian.account.server.infrastructure.config.shardingjdbc.BalanceTableShardingAlgorithm
   `
   **source code**
   
![image](https://user-images.githubusercontent.com/20478130/123772947-d7475080-d8fe-11eb-87fc-94cb44a5de82.png)
   
   **debug img**
   
   
![image](https://user-images.githubusercontent.com/20478130/123773159-0a89df80-d8ff-11eb-8776-c3da01d1da0a.png)
   
   As you can see from the picture, spring Environment is configured,
   `
   String propsPrefix = String.join("", prefix, each, ".props");
   boolean existProps = PropertyUtil.containPropertyPrefix(this.environment, 
propsPrefix);
   `
   existProps return **false**


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


Reply via email to