diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3130dd126..cc5031abd 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -9,6 +9,7 @@
* 【core 】 新增WatchServer(issue#440@Github)
* 【core 】 ReflectUtil.getFieldValue支持static(issue#662@Github)
* 【core 】 改进Bean判断和注入逻辑:支持public字段注入(issue#I1689L@Gitee)
+* 【extra】 新增SpringUtil
### Bug修复
diff --git a/hutool-extra/pom.xml b/hutool-extra/pom.xml
index 2842d1ca5..a7a81e2ab 100644
--- a/hutool-extra/pom.xml
+++ b/hutool-extra/pom.xml
@@ -206,5 +206,24 @@
3.0.2
true
+
+
+ org.springframework.boot
+ spring-boot-starter
+ 2.2.2.RELEASE
+ true
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ 2.2.2.RELEASE
+ test
+
+
+ ch.qos.logback
+ logback-classic
+ 1.2.3
+ test
+
diff --git a/hutool-extra/src/main/java/cn/hutool/extra/spring/SpringUtil.java b/hutool-extra/src/main/java/cn/hutool/extra/spring/SpringUtil.java
new file mode 100644
index 000000000..c3b840fcb
--- /dev/null
+++ b/hutool-extra/src/main/java/cn/hutool/extra/spring/SpringUtil.java
@@ -0,0 +1,78 @@
+package cn.hutool.extra.spring;
+
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+import org.springframework.stereotype.Component;
+
+/**
+ * Spring(Spring boot)工具封装,包括:
+ *
+ *
+ * 1、Spring IOC容器中的bean对象获取
+ *
+ *
+ * @author loolly
+ * @since 5.1.0
+ */
+@Component
+public class SpringUtil implements ApplicationContextAware {
+
+ private static ApplicationContext applicationContext;
+
+ @SuppressWarnings("NullableProblems")
+ @Override
+ public void setApplicationContext(ApplicationContext applicationContext) {
+ if (SpringUtil.applicationContext == null) {
+ SpringUtil.applicationContext = applicationContext;
+ }
+ }
+
+ /**
+ * 获取applicationContext
+ *
+ * @return ApplicationContext
+ */
+ public static ApplicationContext getApplicationContext() {
+ return applicationContext;
+ }
+
+ //通过name获取 Bean.
+
+ /**
+ * 通过name获取 Bean
+ * @param name Bean名称
+ * @return Bean
+ */
+ public static T getBean(String name) {
+ //noinspection unchecked
+ return (T) applicationContext.getBean(name);
+ }
+
+ /**
+ * 通过class获取Bean
+ *
+ * @param Bean类型
+ * @param clazz Bean类
+ * @return Bean对象
+ */
+ public static T getBean(Class clazz) {
+ return applicationContext.getBean(clazz);
+ }
+
+ /**
+ * 通过name,以及Clazz返回指定的Bean
+ *
+ * @param bean类型
+ * @param name Bean名称
+ * @param clazz bean类型
+ * @return Bean对象
+ */
+ public static T getBean(String name, Class clazz) {
+ return applicationContext.getBean(name, clazz);
+ }
+
+}
+
+
+
+
diff --git a/hutool-extra/src/test/java/cn/hutool/extra/spring/SpringUtilTest.java b/hutool-extra/src/test/java/cn/hutool/extra/spring/SpringUtilTest.java
new file mode 100644
index 000000000..639f7b325
--- /dev/null
+++ b/hutool-extra/src/test/java/cn/hutool/extra/spring/SpringUtilTest.java
@@ -0,0 +1,35 @@
+package cn.hutool.extra.spring;
+
+import lombok.Data;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.context.annotation.Bean;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@SpringBootTest(classes = {SpringUtil.class, SpringUtilTest.Demo2.class})
+public class SpringUtilTest {
+
+ @Test
+ public void getBeanTest(){
+ final Demo2 testDemo = SpringUtil.getBean("testDemo");
+ Assert.assertEquals(12345, testDemo.getId());
+ Assert.assertEquals("test", testDemo.getName());
+ }
+
+ @Data
+ public static class Demo2{
+ private long id;
+ private String name;
+
+ @Bean(name="testDemo")
+ public Demo2 generateDemo() {
+ Demo2 demo = new Demo2();
+ demo.setId(12345);
+ demo.setName("test");
+ return demo;
+ }
+ }
+}