You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "terrymanu (via GitHub)" <gi...@apache.org> on 2025/11/14 08:33:20 UTC

Re: [I] Lose sharding table rules and readwrite splitting rules after proxy restart [shardingsphere]

terrymanu commented on issue #28908:
URL: https://github.com/apache/shardingsphere/issues/28908#issuecomment-3531582880

   Based on the analysis of your issue, I recommend the following troubleshooting approach to determine if this is a Kubernetes environment problem or a ShardingSphere functionality issue.
   
     Step 1: Test Outside Kubernetes Environment
   
     Please try to reproduce the issue in a simpler container environment first:
   
     # Start an independent MySQL container
     docker run -d --name mysql-test \
       -e MYSQL_ROOT_PASSWORD=root \
       -e MYSQL_DATABASE=sharding_metadata_db \
       -e MYSQL_USER=sharding_metadata \
       -e MYSQL_PASSWORD=sharding_metadata \
       -p 3306:3306 \
       mysql:8.0
   
     # Start ShardingSphere-Proxy locally (not in K8s)
     # Use the same configuration but update jdbc_url to localhost:3306
   
     Step 2: Reproduction Steps
   
     1. Configure sharding and readwrite splitting rules using your preferred method
     2. Verify the rules work correctly by executing test queries
     3. Restart ShardingSphere-Proxy
     4. Check if the rules are still present and working
   
     Step 3: Analyze Results
   
     - If rules persist correctly: This indicates a Kubernetes environment issue (likely database persistence, networking, or configuration management)
     - If rules are lost: This suggests a potential issue with ShardingSphere Standalone + JDBC functionality
   
     This approach will help us quickly identify whether the issue is environmental or product-related, allowing us to focus on the appropriate solution.
   
   


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