From dab9eca38c56ecdbc9a130e8b8da0882a397ea81 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=BC=A0=E8=85=BE?= <3467447354@qq.com>
Date: Mon, 29 Jul 2024 20:49:37 +0800
Subject: [PATCH] =?UTF-8?q?=E5=88=9D=E5=A7=8B=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.gitignore | 38 ++++++++++++++++++
.idea/.gitignore | 8 ++++
.idea/encodings.xml | 7 ++++
.idea/misc.xml | 14 +++++++
.idea/vcs.xml | 6 +++
pom.xml | 39 +++++++++++++++++++
.../java/com/muyu/rabbit/RabbitConfig.java | 32 +++++++++++++++
...ot.autoconfigure.AutoConfiguration.imports | 1 +
8 files changed, 145 insertions(+)
create mode 100644 .gitignore
create mode 100644 .idea/.gitignore
create mode 100644 .idea/encodings.xml
create mode 100644 .idea/misc.xml
create mode 100644 .idea/vcs.xml
create mode 100644 pom.xml
create mode 100644 src/main/java/com/muyu/rabbit/RabbitConfig.java
create mode 100644 src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..5ff6309
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,38 @@
+target/
+!.mvn/wrapper/maven-wrapper.jar
+!**/src/main/**/target/
+!**/src/test/**/target/
+
+### IntelliJ IDEA ###
+.idea/modules.xml
+.idea/jarRepositories.xml
+.idea/compiler.xml
+.idea/libraries/
+*.iws
+*.iml
+*.ipr
+
+### Eclipse ###
+.apt_generated
+.classpath
+.factorypath
+.project
+.settings
+.springBeans
+.sts4-cache
+
+### NetBeans ###
+/nbproject/private/
+/nbbuild/
+/dist/
+/nbdist/
+/.nb-gradle/
+build/
+!**/src/main/**/build/
+!**/src/test/**/build/
+
+### VS Code ###
+.vscode/
+
+### Mac OS ###
+.DS_Store
\ No newline at end of file
diff --git a/.idea/.gitignore b/.idea/.gitignore
new file mode 100644
index 0000000..13566b8
--- /dev/null
+++ b/.idea/.gitignore
@@ -0,0 +1,8 @@
+# Default ignored files
+/shelf/
+/workspace.xml
+# Editor-based HTTP Client requests
+/httpRequests/
+# Datasource local storage ignored files
+/dataSources/
+/dataSources.local.xml
diff --git a/.idea/encodings.xml b/.idea/encodings.xml
new file mode 100644
index 0000000..aa00ffa
--- /dev/null
+++ b/.idea/encodings.xml
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/misc.xml b/.idea/misc.xml
new file mode 100644
index 0000000..82dbec8
--- /dev/null
+++ b/.idea/misc.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
new file mode 100644
index 0000000..94a25f7
--- /dev/null
+++ b/.idea/vcs.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
new file mode 100644
index 0000000..628c3e3
--- /dev/null
+++ b/pom.xml
@@ -0,0 +1,39 @@
+
+
+ 4.0.0
+
+ com.bwie
+ cloud-common-rabbit
+ 1.0-SNAPSHOT
+
+
+ com.muyu
+ cloud-common
+ 3.6.3
+
+
+
+ 17
+ 17
+ UTF-8
+
+
+
+
+ com.muyu
+ cloud-common-core
+
+
+ org.springframework.boot
+ spring-boot-starter-amqp
+
+
+ org.springframework
+ spring-context
+ 6.1.8
+
+
+
+
diff --git a/src/main/java/com/muyu/rabbit/RabbitConfig.java b/src/main/java/com/muyu/rabbit/RabbitConfig.java
new file mode 100644
index 0000000..1ffd3d8
--- /dev/null
+++ b/src/main/java/com/muyu/rabbit/RabbitConfig.java
@@ -0,0 +1,32 @@
+package com.muyu.rabbit;
+
+import jakarta.annotation.PostConstruct;
+import lombok.AllArgsConstructor;
+import lombok.extern.log4j.Log4j2;
+import org.springframework.amqp.core.AmqpAdmin;
+import org.springframework.amqp.core.AmqpTemplate;
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * @Author:张腾
+ * @Package:com.muyu.rabbit
+ * @Project:cloud-common-rabbit
+ * @name:RabbitConfig
+ * @Date:2024/7/29 20:29
+ */
+@Configuration
+@AllArgsConstructor
+@Log4j2
+public class RabbitConfig {
+
+ private final AmqpAdmin amqpAdmin;
+
+ private final AmqpTemplate amqpTemplate;
+
+
+ @PostConstruct
+ public void init(){
+ log.info("rabbitMQ启动成功");
+ }
+
+}
diff --git a/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports b/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
new file mode 100644
index 0000000..58d8702
--- /dev/null
+++ b/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
@@ -0,0 +1 @@
+com.muyu.rabbit.RabbitConfig