yx9o commented on a change in pull request #15828:
URL: https://github.com/apache/shardingsphere/pull/15828#discussion_r820228833
##########
File path:
examples/shardingsphere-jdbc-example/single-feature-example/encrypt-example/encrypt-spring-namespace-jpa-example/src/main/java/EncryptSpringNamespaceJPAExample.java
##########
@@ -0,0 +1,19 @@
+package org.apache.shardingsphere.example.sharding.spring.namespace.jpa;
+
+import org.apache.shardingsphere.example.core.api.ExampleExecuteTemplate;
+import org.apache.shardingsphere.example.core.api.service.ExampleService;
+import org.springframework.context.ConfigurableApplicationContext;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
+
+import java.sql.SQLException;
+
+public final class ShardingSpringNamespaceJpaExample {
+
+ private static final String CONFIG_FILE =
"META-INF/application-sharding-databases.xml";
+
+ public static void main(final String[] args) throws SQLException {
+ try (ConfigurableApplicationContext applicationContext = new
ClassPathXmlApplicationContext(CONFIG_FILE)) {
+
ExampleExecuteTemplate.run(applicationContext.getBean(ExampleService.class));
+ }
+ }
+}
Review comment:
There should be a blank line at the end.
--
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]