diff --git a/my/pom.xml b/my/pom.xml
index 8ad7f8c8c..a98839245 100644
--- a/my/pom.xml
+++ b/my/pom.xml
@@ -1,279 +1,279 @@
-
-
- 4.0.0
- org.redkale
- redkale
- jar
- RedkaleProject
- https://redkale.org
- redkale -- java framework
- 2.8.0-SNAPSHOT
-
-
- UTF-8
- 11
- 11
-
- 5.9.0
- 3.4.0
- 3.2.4
- 3.2.0
- 3.7.0
- 1.7.0
- 3.13.0
- 3.2.5
- 3.2.5
- 2.43.0
- 2.46.0
-
-
-
-
-
- Apache 2
- https://www.apache.org/licenses/
- repo
- Apache License
-
-
-
-
-
- org.junit.jupiter
- junit-jupiter
- ${junit.version}
- test
-
-
-
-
-
- central
- Central Repository
- https://repo.maven.apache.org/maven2
-
-
- sonatype-nexus-snapshots
- Sonatype Nexus Snapshots
- https://oss.sonatype.org/content/repositories/snapshots
-
-
-
-
-
- Redkale
- redkale
- redkale@qq.com
- https://redkale.org
-
- Project Manager
- Architect
-
- redkale
- https://redkale.org
-
- No
-
- 8
-
-
-
-
-
- ossrh
- https://oss.sonatype.org/service/local/staging/deploy/maven2/
-
-
- ossrh
- https://oss.sonatype.org/content/repositories/snapshots/
-
-
-
-
- https://github.com/redkale/redkale
- scm:git:git@github.com/redkale/redkale.git
- scm:git:git@github.com:redkale/redkale.git
-
-
-
- GitHub Issues
- https://github.com/redkale/redkale/issues
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-compiler-plugin
- ${maven-compiler-plugin.version}
-
- UTF-8
-
- -parameters
-
-
-
-
-
- org.apache.maven.plugins
- maven-jar-plugin
- ${maven-jar-plugin.version}
-
-
- false
-
- org.redkale.boot.Application
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-surefire-plugin
- ${maven-surefire-plugin.version}
-
- once
- -Dfile.encoding=UTF-8
-
-
-
-
- org.apache.maven.plugins
- maven-failsafe-plugin
- ${maven-failsafe-plugin.version}
-
-
- org.apache.maven.plugins
- maven-gpg-plugin
- ${maven-gpg-plugin.version}
-
-
- sign-artifacts
- verify
-
- sign
-
-
- bc
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-source-plugin
- ${maven-source-plugin.version}
-
-
-
- jar
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-javadoc-plugin
- ${maven-source-plugin.version}
-
-
-
- jar
-
-
-
-
-
-
- org.apache.maven.plugins
- maven-assembly-plugin
- ${maven-assembly-plugin.version}
-
- false
-
- my/assembly.xml
-
-
-
-
- redkale
- package
-
- single
-
-
-
-
-
-
- org.sonatype.plugins
- nexus-staging-maven-plugin
- ${nexus-staging-plugin.version}
- true
-
- ossrh
- https://oss.sonatype.org/
- true
-
-
-
-
- com.diffplug.spotless
- spotless-maven-plugin
- ${spotless-maven-plugin.version}
-
- UNIX
-
-
-
- src/**/java/**/*.java
-
-
-
-
- true
- 4
-
-
-
-
-
- ${palantir-java-format.version}
-
- true
-
-
-
-
-
-
- check
-
- compile
-
-
-
-
-
-
-
+
+
+ 4.0.0
+ org.redkale
+ redkale
+ jar
+ RedkaleProject
+ https://redkale.org
+ redkale -- java framework
+ 2.8.0-SNAPSHOT
+
+
+ UTF-8
+ 11
+ 11
+
+ 5.9.0
+ 3.4.0
+ 3.2.4
+ 3.2.0
+ 3.7.0
+ 1.7.0
+ 3.13.0
+ 3.2.5
+ 3.2.5
+ 2.43.0
+ 2.46.0
+
+
+
+
+
+ Apache 2
+ https://www.apache.org/licenses/
+ repo
+ Apache License
+
+
+
+
+
+ org.junit.jupiter
+ junit-jupiter
+ ${junit.version}
+ test
+
+
+
+
+
+ central
+ Central Repository
+ https://repo.maven.apache.org/maven2
+
+
+ sonatype-nexus-snapshots
+ Sonatype Nexus Snapshots
+ https://oss.sonatype.org/content/repositories/snapshots
+
+
+
+
+
+ Redkale
+ redkale
+ redkale@qq.com
+ https://redkale.org
+
+ Project Manager
+ Architect
+
+ redkale
+ https://redkale.org
+
+ No
+
+ 8
+
+
+
+
+
+ ossrh
+ https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/
+
+
+ ossrh
+ https://s01.oss.sonatype.org/content/repositories/snapshots/
+
+
+
+
+ https://github.com/redkale/redkale
+ scm:git:git@github.com/redkale/redkale.git
+ scm:git:git@github.com:redkale/redkale.git
+
+
+
+ GitHub Issues
+ https://github.com/redkale/redkale/issues
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-compiler-plugin
+ ${maven-compiler-plugin.version}
+
+ UTF-8
+
+ -parameters
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-jar-plugin
+ ${maven-jar-plugin.version}
+
+
+ false
+
+ org.redkale.boot.Application
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-surefire-plugin
+ ${maven-surefire-plugin.version}
+
+ once
+ -Dfile.encoding=UTF-8
+
+
+
+
+ org.apache.maven.plugins
+ maven-failsafe-plugin
+ ${maven-failsafe-plugin.version}
+
+
+ org.apache.maven.plugins
+ maven-gpg-plugin
+ ${maven-gpg-plugin.version}
+
+
+ sign-artifacts
+ verify
+
+ sign
+
+
+ bc
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-source-plugin
+ ${maven-source-plugin.version}
+
+
+
+ jar
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-javadoc-plugin
+ ${maven-source-plugin.version}
+
+
+
+ jar
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-assembly-plugin
+ ${maven-assembly-plugin.version}
+
+ false
+
+ my/assembly.xml
+
+
+
+
+ redkale
+ package
+
+ single
+
+
+
+
+
+
+ org.sonatype.plugins
+ nexus-staging-maven-plugin
+ ${nexus-staging-plugin.version}
+ true
+
+ ossrh
+ https://s01.oss.sonatype.org/
+ true
+
+
+
+
+ com.diffplug.spotless
+ spotless-maven-plugin
+ ${spotless-maven-plugin.version}
+
+ UNIX
+
+
+
+ src/**/java/**/*.java
+
+
+
+
+ true
+ 4
+
+
+
+
+
+ ${palantir-java-format.version}
+
+ true
+
+
+
+
+
+
+ check
+
+ compile
+
+
+
+
+
+
+
diff --git a/src/main/java/org/redkale/mq/MessageManager.java b/src/main/java/org/redkale/mq/MessageManager.java
index 2ab1698f5..6485e063a 100644
--- a/src/main/java/org/redkale/mq/MessageManager.java
+++ b/src/main/java/org/redkale/mq/MessageManager.java
@@ -4,6 +4,7 @@
package org.redkale.mq;
import java.util.List;
+import java.util.concurrent.CompletableFuture;
import org.redkale.inject.Resourcable;
/**
@@ -20,22 +21,22 @@ public interface MessageManager extends Resourcable {
* 创建topic
*
* @param topics topic集合
- * @return 是否成功
+ * @return 是否完成
*/
- public boolean createTopic(String... topics);
+ public CompletableFuture createTopic(String... topics);
/**
* 删除topic,如果不存在则跳过
*
* @param topics topic集合
- * @return 是否成功
+ * @return 是否完成
*/
- public boolean deleteTopic(String... topics);
+ public CompletableFuture deleteTopic(String... topics);
/**
* 查询所有topic
*
* @return topic集合
*/
- public abstract List queryTopic();
+ public abstract CompletableFuture> queryTopic();
}
diff --git a/src/main/java/org/redkale/mq/spi/MessageAgent.java b/src/main/java/org/redkale/mq/spi/MessageAgent.java
index 1107eb631..29a15126a 100644
--- a/src/main/java/org/redkale/mq/spi/MessageAgent.java
+++ b/src/main/java/org/redkale/mq/spi/MessageAgent.java
@@ -5,9 +5,6 @@
*/
package org.redkale.mq.spi;
-import static org.redkale.boot.Application.RESNAME_APP_NAME;
-import static org.redkale.boot.Application.RESNAME_APP_NODEID;
-
import java.lang.reflect.ParameterizedType;
import java.lang.reflect.Type;
import java.nio.charset.StandardCharsets;
@@ -20,6 +17,8 @@ import java.util.logging.*;
import org.redkale.annotation.*;
import org.redkale.annotation.AutoLoad;
import org.redkale.boot.*;
+import static org.redkale.boot.Application.RESNAME_APP_NAME;
+import static org.redkale.boot.Application.RESNAME_APP_NODEID;
import org.redkale.cluster.HttpRpcClient;
import org.redkale.convert.Convert;
import org.redkale.convert.ConvertFactory;
@@ -414,17 +413,17 @@ public abstract class MessageAgent implements MessageManager {
@ResourceChanged
public abstract void onResourceChange(ResourceEvent[] events);
- //
+ // 新增topic
@Override
- public abstract boolean createTopic(String... topics);
+ public abstract CompletableFuture createTopic(String... topics);
// 删除topic,如果不存在则跳过
@Override
- public abstract boolean deleteTopic(String... topics);
+ public abstract CompletableFuture deleteTopic(String... topics);
// 查询所有topic
@Override
- public abstract List queryTopic();
+ public abstract CompletableFuture> queryTopic();
// ServiceLoader时判断配置是否符合当前实现类
public abstract boolean acceptsConf(AnyValue config);