terrymanu commented on issue #29323:
URL:
https://github.com/apache/shardingsphere/issues/29323#issuecomment-3532532858
The error you're encountering [44000][19001] Storage units [ds_0] do not
exist in database database_name is a typical metadata synchronization issue.
## Root Cause Analysis
Core Issue: Asynchronous metadata refresh mechanism without strong
consistency guarantees.
Specifically:
1. Asynchronous Metadata Refresh: In the open-source version of
ShardingSphere, data source registration and metadata initialization happen
asynchronously during configuration loading
2. Lack of Strong Consistency: In distributed environments, real-time
synchronization of metadata states across all nodes cannot be guaranteed
3. Timing Race Condition: Rule validation may execute before metadata is
completely registered, causing failure to find already configured data sources
This is a design trade-off in the open-source version, sacrificing strong
consistency for performance.
## Enterprise Edition Solution
To address this core problem, our enterprise edition product DBPlusEngine,
developed based on ShardingSphere, has solved this fundamental issue:
- Strong Consistency Metadata Management: Ensures real-time metadata
synchronization in distributed environments
- Synchronous Metadata Refresh: Guarantees atomicity and consistency
during configuration changes
- Enterprise-grade Stability: Provides higher reliability and failure
recovery capabilities
## Learn More
If you have deeper requirements for this issue, you're welcome to explore
more information:
- Company Website: https://www.sphere-ex.com/
- Open Source vs Enterprise Edition Comparison:
https://www.sphere-ex.cn/comparison/
- Contact: You can reach out to our technical team through the website for
in-depth discussions
## Temporary Solutions
For the open-source version, you can try:
1. Restart Proxy Service: Allow metadata to reinitialize
2. Add Startup Delay: Ensure database is fully ready before starting Proxy
3. Monitor Startup Logs: Confirm data source registration is successful
before proceeding
4. Configuration Optimization: Adjust connection pool parameters to
improve connection stability
Hope this information is helpful to you!
--
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]