This is an automated email from the ASF dual-hosted git repository.
hefengen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shenyu-plugin-store.git
The following commit(s) were added to refs/heads/master by this push:
new 52e0445 [type:init] add tars and motan starter (#3)
52e0445 is described below
commit 52e0445f63bdbf1e4c24d8721c3ef2f2e24a89a8
Author: moremind <[email protected]>
AuthorDate: Fri Apr 17 16:45:19 2026 +0800
[type:init] add tars and motan starter (#3)
---
.../pom.xml | 57 ++++++++++++++
.../plugin/motan/MotanPluginConfiguration.java | 92 ++++++++++++++++++++++
.../src/main/resources/META-INF/spring.factories | 19 +++++
.../src/main/resources/META-INF/spring.provides | 18 +++++
...rk.boot.autoconfigure.AutoConfiguration.imports | 18 +++++
.../plugin/motan/MotanPluginConfigurationTest.java | 85 ++++++++++++++++++++
.../shenyu-spring-boot-starter-plugin-tars/pom.xml | 35 ++++++++
.../plugin/tars/TarsPluginConfiguration.java | 80 +++++++++++++++++++
.../src/main/resources/META-INF/spring.factories | 19 +++++
.../src/main/resources/META-INF/spring.provides | 18 +++++
...rk.boot.autoconfigure.AutoConfiguration.imports | 18 +++++
.../plugin/tars/TarsPluginConfigurationTest.java | 88 +++++++++++++++++++++
12 files changed, 547 insertions(+)
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/pom.xml
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/pom.xml
new file mode 100644
index 0000000..1a9b416
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/pom.xml
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one or more
+ ~ contributor license agreements. See the NOTICE file distributed with
+ ~ this work for additional information regarding copyright ownership.
+ ~ The ASF licenses this file to You under the Apache License, Version 2.0
+ ~ (the "License"); you may not use this file except in compliance with
+ ~ the License. You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <parent>
+ <groupId>org.apache.shenyu</groupId>
+ <artifactId>shenyu-spring-boot-starter-plugin</artifactId>
+ <version>2.7.1-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>shenyu-spring-boot-starter-plugin-motan</artifactId>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.shenyu</groupId>
+ <artifactId>shenyu-plugin-motan</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+
+ <!-- Test dependencies for Motan -->
+ <dependency>
+ <groupId>com.weibo</groupId>
+ <artifactId>motan-core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.weibo</groupId>
+ <artifactId>motan-transport-netty4</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.weibo</groupId>
+ <artifactId>motan-registry-zookeeper</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.weibo</groupId>
+ <artifactId>motan-springsupport</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfiguration.java
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfiguration.java
new file mode 100644
index 0000000..cbac118
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfiguration.java
@@ -0,0 +1,92 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shenyu.springboot.starter.plugin.motan;
+
+import org.apache.shenyu.plugin.api.ShenyuPlugin;
+import org.apache.shenyu.plugin.api.context.ShenyuContextDecorator;
+import org.apache.shenyu.plugin.base.handler.MetaDataHandler;
+import org.apache.shenyu.plugin.base.handler.PluginDataHandler;
+import org.apache.shenyu.plugin.motan.MotanPlugin;
+import org.apache.shenyu.plugin.motan.context.MotanShenyuContextDecorator;
+import org.apache.shenyu.plugin.motan.handler.MotanPluginDataHandler;
+import org.apache.shenyu.plugin.motan.proxy.MotanProxyService;
+import org.apache.shenyu.plugin.motan.handler.MotanMetaDataHandler;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * The type motan plugin configuration.
+ */
+@Configuration
+@ConditionalOnClass(MotanPlugin.class)
+@ConditionalOnProperty(value = {"shenyu.plugins.motan.enabled"}, havingValue =
"true", matchIfMissing = true)
+public class MotanPluginConfiguration {
+
+ /**
+ * Motan proxy service.
+ *
+ * @return the motan proxy service
+ */
+ @Bean
+ public MotanProxyService motanProxyService() {
+ return new MotanProxyService();
+ }
+
+ /**
+ * Motan plugin.
+ *
+ * @param motanProxyService the motan proxy service
+ * @return the shenyu plugin
+ */
+ @Bean
+ public ShenyuPlugin motanPlugin(final MotanProxyService motanProxyService)
{
+ return new MotanPlugin(motanProxyService);
+ }
+
+ /**
+ * Motan plugin data handler.
+ *
+ * @return the plugin data handler
+ */
+ @Bean
+ public PluginDataHandler motanPluginDataHandler() {
+ return new MotanPluginDataHandler();
+ }
+
+ /**
+ * Motan meta data handler.
+ *
+ * @return the meta data handler
+ */
+ @Bean
+ public MetaDataHandler motanMetaDataHandler() {
+ return new MotanMetaDataHandler();
+ }
+
+ /**
+ * motan shenyu context decorator.
+ *
+ * @return the shenyu context decorator
+ */
+ @Bean
+ public ShenyuContextDecorator motanShenyuContextDecorator() {
+ return new MotanShenyuContextDecorator();
+ }
+}
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.factories
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.factories
new file mode 100644
index 0000000..f6ae991
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.factories
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
+org.apache.shenyu.springboot.starter.plugin.motan.MotanPluginConfiguration
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.provides
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.provides
new file mode 100644
index 0000000..77d8c47
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring.provides
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+provides: shenyu-spring-boot-starter-plugin-motan
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
new file mode 100644
index 0000000..4201fba
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+org.apache.shenyu.springboot.starter.plugin.motan.MotanPluginConfiguration
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/test/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfigurationTest.java
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/test/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfigurationTest.java
new file mode 100644
index 0000000..4665c36
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-motan/src/test/java/org/apache/shenyu/springboot/starter/plugin/motan/MotanPluginConfigurationTest.java
@@ -0,0 +1,85 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shenyu.springboot.starter.plugin.motan;
+
+import org.apache.shenyu.plugin.api.context.ShenyuContextDecorator;
+import org.apache.shenyu.plugin.base.handler.MetaDataHandler;
+import org.apache.shenyu.plugin.base.handler.PluginDataHandler;
+import org.apache.shenyu.plugin.motan.MotanPlugin;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+import org.springframework.boot.autoconfigure.AutoConfigurations;
+import
org.springframework.boot.context.properties.EnableConfigurationProperties;
+import org.springframework.boot.test.context.runner.ApplicationContextRunner;
+import org.springframework.context.annotation.Configuration;
+
+import static org.junit.jupiter.api.Assertions.assertNotNull;
+
+/**
+ * Test case for {@link MotanPluginConfiguration}.
+ */
+@Configuration
+@EnableConfigurationProperties
+public class MotanPluginConfigurationTest {
+
+ private ApplicationContextRunner applicationContextRunner;
+
+ @BeforeEach
+ public void before() {
+ applicationContextRunner = new ApplicationContextRunner()
+
.withConfiguration(AutoConfigurations.of(MotanPluginConfiguration.class))
+ .withBean(MotanPluginConfigurationTest.class)
+ .withPropertyValues("debug=true");
+ }
+
+ @Test
+ public void testMotanPlugin() {
+ applicationContextRunner.run(context -> {
+ MotanPlugin plugin = context.getBean("motanPlugin",
MotanPlugin.class);
+ assertNotNull(plugin);
+ }
+ );
+ }
+
+ @Test
+ public void testMotanPluginDataHandler() {
+ applicationContextRunner.run(context -> {
+ PluginDataHandler handler =
context.getBean("motanPluginDataHandler", PluginDataHandler.class);
+ assertNotNull(handler);
+ }
+ );
+ }
+
+ @Test
+ public void testMotanMetaDataHandler() {
+ applicationContextRunner.run(context -> {
+ MetaDataHandler handler =
context.getBean("motanMetaDataHandler", MetaDataHandler.class);
+ assertNotNull(handler);
+ }
+ );
+ }
+
+ @Test
+ public void testMotanShenyuContextDecorator() {
+ applicationContextRunner.run(context -> {
+ ShenyuContextDecorator subscriber =
context.getBean("motanShenyuContextDecorator", ShenyuContextDecorator.class);
+ assertNotNull(subscriber);
+ }
+ );
+ }
+}
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/pom.xml
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/pom.xml
new file mode 100644
index 0000000..7e35186
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/pom.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one or more
+ ~ contributor license agreements. See the NOTICE file distributed with
+ ~ this work for additional information regarding copyright ownership.
+ ~ The ASF licenses this file to You under the Apache License, Version 2.0
+ ~ (the "License"); you may not use this file except in compliance with
+ ~ the License. You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <parent>
+ <groupId>org.apache.shenyu</groupId>
+ <artifactId>shenyu-spring-boot-starter-plugin</artifactId>
+ <version>2.7.1-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>shenyu-spring-boot-starter-plugin-tars</artifactId>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.shenyu</groupId>
+ <artifactId>shenyu-plugin-tars</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+</project>
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfiguration.java
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfiguration.java
new file mode 100644
index 0000000..0f4de58
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfiguration.java
@@ -0,0 +1,80 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shenyu.springboot.starter.plugin.tars;
+
+import org.apache.shenyu.plugin.api.ShenyuPlugin;
+import org.apache.shenyu.plugin.api.context.ShenyuContextDecorator;
+import org.apache.shenyu.plugin.base.handler.MetaDataHandler;
+import org.apache.shenyu.plugin.base.handler.PluginDataHandler;
+import org.apache.shenyu.plugin.tars.TarsPlugin;
+import org.apache.shenyu.plugin.tars.context.TarsShenyuContextDecorator;
+import org.apache.shenyu.plugin.tars.handler.TarsPluginDataHandler;
+import org.apache.shenyu.plugin.tars.handler.TarsMetaDataHandler;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * The type tars plugin configuration.
+ */
+@Configuration
+@ConditionalOnClass(TarsPlugin.class)
+@ConditionalOnProperty(value = {"shenyu.plugins.tars.enabled"}, havingValue =
"true", matchIfMissing = true)
+public class TarsPluginConfiguration {
+
+ /**
+ * Tars plugin.
+ *
+ * @return the tars plugin
+ */
+ @Bean
+ public ShenyuPlugin tarsPlugin() {
+ return new TarsPlugin();
+ }
+
+ /**
+ * Tars meta data handler.
+ *
+ * @return the meta data handler
+ */
+ @Bean
+ public MetaDataHandler tarsMetaDataHandler() {
+ return new TarsMetaDataHandler();
+ }
+
+ /**
+ * Tars plugin data handler.
+ *
+ * @return the plugin data handler
+ */
+ @Bean
+ public PluginDataHandler tarsPluginDataHandler() {
+ return new TarsPluginDataHandler();
+ }
+
+ /**
+ * Tars shenyu context decorator.
+ *
+ * @return the shenyu context decorator
+ */
+ @Bean
+ public ShenyuContextDecorator tarsShenyuContextDecorator() {
+ return new TarsShenyuContextDecorator();
+ }
+}
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.factories
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.factories
new file mode 100644
index 0000000..d56ac7b
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.factories
@@ -0,0 +1,19 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
+org.apache.shenyu.springboot.starter.plugin.tars.TarsPluginConfiguration
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.provides
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.provides
new file mode 100644
index 0000000..0a6c45b
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring.provides
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+provides: shenyu-spring-boot-starter-plugin-tars
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
new file mode 100644
index 0000000..8801589
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+org.apache.shenyu.springboot.starter.plugin.tars.TarsPluginConfiguration
diff --git
a/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/test/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfigurationTest.java
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/test/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfigurationTest.java
new file mode 100644
index 0000000..04889d5
--- /dev/null
+++
b/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-tars/src/test/java/org/apache/shenyu/springboot/starter/plugin/tars/TarsPluginConfigurationTest.java
@@ -0,0 +1,88 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shenyu.springboot.starter.plugin.tars;
+
+import org.apache.shenyu.common.enums.PluginEnum;
+import org.apache.shenyu.plugin.api.ShenyuPlugin;
+import org.apache.shenyu.plugin.api.context.ShenyuContextDecorator;
+import org.apache.shenyu.plugin.base.handler.MetaDataHandler;
+import org.apache.shenyu.plugin.base.handler.PluginDataHandler;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+import org.springframework.boot.autoconfigure.AutoConfigurations;
+import
org.springframework.boot.context.properties.EnableConfigurationProperties;
+import org.springframework.boot.test.context.runner.ApplicationContextRunner;
+import org.springframework.context.annotation.Configuration;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.junit.jupiter.api.Assertions.assertNotNull;
+
+/**
+ * Test case for {@link TarsPluginConfiguration}.
+ */
+@Configuration
+@EnableConfigurationProperties
+public class TarsPluginConfigurationTest {
+
+ private ApplicationContextRunner applicationContextRunner;
+
+ @BeforeEach
+ public void before() {
+ applicationContextRunner = new ApplicationContextRunner()
+
.withConfiguration(AutoConfigurations.of(TarsPluginConfiguration.class))
+ .withBean(TarsPluginConfigurationTest.class)
+ .withPropertyValues("debug=true");
+ }
+
+ @Test
+ public void testTarsPlugin() {
+ applicationContextRunner.run(context -> {
+ ShenyuPlugin plugin = context.getBean("tarsPlugin",
ShenyuPlugin.class);
+ assertNotNull(plugin);
+
assertThat(plugin.named()).isEqualTo(PluginEnum.TARS.getName());
+ }
+ );
+ }
+
+ @Test
+ public void testTarsMetaDataHandler() {
+ applicationContextRunner.run(context -> {
+ MetaDataHandler handler =
context.getBean("tarsMetaDataHandler", MetaDataHandler.class);
+ assertNotNull(handler);
+ }
+ );
+ }
+
+ @Test
+ public void testTarsPluginDataHandler() {
+ applicationContextRunner.run(context -> {
+ PluginDataHandler handler =
context.getBean("tarsPluginDataHandler", PluginDataHandler.class);
+ assertNotNull(handler);
+ }
+ );
+ }
+
+ @Test
+ public void testTarsShenyuContextDecorator() {
+ applicationContextRunner.run(context -> {
+ ShenyuContextDecorator decorator =
context.getBean("tarsShenyuContextDecorator", ShenyuContextDecorator.class);
+ assertNotNull(decorator);
+ }
+ );
+ }
+}