slievrly commented on PR #30138:
URL: https://github.com/apache/shardingsphere/pull/30138#issuecomment-1948797823

   > For #29052.
   > 
   > Changes proposed in this pull request:
   > 
   > * Add GraalVM Reachability Metadata and corresponding nativeTest for Seata 
integration.
   > * Remove inappropriate reference to 
`com.mysql.cj.jdbc.exceptions.CommunicationsException`.
   > * Uses `io.seata:seata-all:1.7.1` and make corresponding adjustments in 
nativeTests.  Before merging [feature: First support `native-image` for 
`seata-client` 
incubator-seata#5234](https://github.com/apache/incubator-seata/pull/5234), 
using Seata Client under GraalVM Native Image requires using the version 
released under its native branch. Using `io.seata:seata-all:2.0.0` under 
nativeTest needs to wait for the ByteBuddy Java API to be removed on the seata 
side.
   
   Seata 1.x supports native image from version 1.7.0, refer to the merged PR 
https://github.com/apache/incubator-seata/pull/5476#issue-1647084093.  
Currently, 2.x does not support native image, and this function of 1.x will be 
translated in the future. For native image integration, I recommend using 
1.8.0, the latest version of 1.x.
   
   > * seata's configuration file `file.conf` has no dynamically defined Java 
API, which prevents the integration of testcontainers.
   
   The client-side uses the Seata SDK, which can depend on Seata in two ways:
   
   1. By using seata-all.jar, it will read registry-$env.conf (with the default 
value being registry.conf), which defines how Seata accesses the metadata from 
the registry and configuration centers. When config.type=xxx is read from the 
configuration center and xxx is set to 'file', it will by default read the 
configuration from file.conf located in the same directory (though other paths 
and filenames can be specified). This does not support dynamic refresh of the 
configuration. When xxx is set to a third-party configuration center, some 
configurations support dynamic refresh, but most configurations are read-once 
types during startup. Currently, it does not support using Java API to modify 
configurations and reload them directly.
   
   2. By using seata-spring-boot-starter.jar. This defaults to including 
seata-all.jar dependency and adds autoconfiguration features for Spring Boot. 
It supports directly using Spring Boot's configuration files (either properties 
or yml) for configuration. Refer to 
https://github.com/apache/incubator-seata/tree/2.x/script/client/spring for 
examples. You can consider storing these configurations in your application's 
configuration center, where some configurations support dynamic refresh. 
Likewise, it does not support using Java API to modify configurations and 
reload them directly.
   
   Furthermore, the priority of Seata client configuration is ENV 
(System.getenv()) > -D (System.getProperty()) > file or configuration center. 
You can consider injecting environment variables in testContainer.
   


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