如何在Idea中编译构建Spring Framework 5.x
如何在Idea中编译构建Spring Framework 5.x
安装配置Gradle
(略)下载源码:git clone https://github.com/spring-projects/spring-framework.git
按照工程下
import-into-idea.md文件的提示进行操作The following has been tested against IntelliJ IDEA 2016.2.2 ## Steps _Within your locally cloned spring-framework working directory:_ 1. Precompile `spring-oxm` with `./gradlew :spring-oxm:compileTestJava`
2. Import into IntelliJ (File -> New -> Project from Existing Sources -> Navigate to directory -> Select build.gradle)
3. When prompted exclude the `spring-aspects` module (or after the import via File-> Project Structure -> Modules)
4. Code away ## Known issues 1. `spring-core` and `spring-oxm` should be pre-compiled due to repackaged dependencies.
See `*RepackJar` tasks in the build and https://youtrack.jetbrains.com/issue/IDEA-160605).
2. `spring-aspects` does not compile due to references to aspect types unknown to
IntelliJ IDEA. See https://youtrack.jetbrains.com/issue/IDEA-64446 for details. In the meantime, the
'spring-aspects' can be excluded from the project to avoid compilation errors.
3. While JUnit tests pass from the command line with Gradle, some may fail when run from
IntelliJ IDEA. Resolving this is a work in progress. If attempting to run all JUnit tests from within
IntelliJ IDEA, you will likely need to set the following VM options to avoid out of memory errors:
-XX:MaxPermSize=2048m -Xmx2048m -XX:MaxHeapSize=2048m
4. If you invoke "Rebuild Project" in the IDE, you'll have to generate some test
resources of the `spring-oxm` module again (`./gradlew :spring-oxm:compileTestJava`) ## Tips In any case, please do not check in your own generated .iml, .ipr, or .iws files.
You'll notice these files are already intentionally in .gitignore. The same policy goes for eclipse metadata. ## FAQ Q. What about IntelliJ IDEA's own [Gradle support](https://confluence.jetbrains.net/display/IDEADEV/Gradle+integration)? A. Keep an eye on https://youtrack.jetbrains.com/issue/IDEA-53476
按照
steps和Known issues指示进行操作即可,第一次构建可能要下载大量依赖,可能需要花费一些时间,慢的可能需要一到俩小时,需要耐心等待。编译完
spring-core和spring-oxm之后,再去编译spring-context时候,你会发现报错了,有来自.gradle文件的报错,有因为xxx类找不到的报错,这里报出的任何错误,一律通过注释对应的代码进行解决。.gradle文件报错,将对应报错行的构建代码注释掉,xxx类找不到,将对xxx类的引用注释掉
新增
module进行测试
Note: 由于
spring-aspects的实现依赖了aspectj,需要另外引入,所以不调试spring-aspects模块内容的同学,可以直接把这个模块给移除掉。
我这边构建一份最新的工程(2019-11-2 2:26)放在Github上供大家参考
如何在Idea中编译构建Spring Framework 5.x的更多相关文章
- 如何在Windows中编译Linux Unix的代码(采用cygwin)?
来源:http://www.cnblogs.com/rocky_yi/archive/2009/12/08/cygwin.html 作者:rocky_y 很多经典算法往往是用C++在linux下实 ...
- 如何在SAS中重新构建限价指令簿(Limit Order Book):使用HashTable
在之前的一篇日志里(http://blog.csdn.net/u010501526/article/details/8875446),我将重新构建LOB(Limit Order Book)分为了三步 ...
- 如何在vs2015中编译并配置tesseract4.0
1)安装相关软件: 下载ccpan,把路径放到path(右击电脑,选择“属性”,选择左边的“高级系统设置”,选择“环境变量”,找到“系统变量”里面的“path”,点击“编辑”,选择右边的“新建”,输入 ...
- visual c++.net 技术内幕 第6版 附带的程序如何在vs2013中编译成功
看vc++技术内幕时 如果你使用的是比此书的附带项目更新版的vs时千万不要使用这种方法,这些对编译都有影响. 请使用当前新版的vs并输入书中改动的代码就Ok,因为vs会生成合理的mfc代码,养成好的习 ...
- 如何在container中编译dotnet的eShopOnContainers
准备的软件 问题 Image下载问题 以下就是为啥要有最后一个软件(我是使用版): SQLSever for Linux 内存需求 需要编译Image 成功搞定 参考 Welcome to t ...
- 记录5-如何在UltraEdit中编译和运行Java
1点击“高级”,再点击“工具配置” 2点击“插入”,在“菜单项”名称上输入“编译java程序”,在“命令行”里输入“javac %n%e”,在工作目录上填“%p”. 3切换到“输出”项,选择“输出到列 ...
- step6----->往工程中添加spring boot项目------->修改pom.xml使得我的project是基于spring boot的,而非直接基于spring framework
文章内容概述: spring项目组其实有多个projects,如spring IO platform用于管理external dependencies的版本,通过定义BOM(bill of mater ...
- Spring Framework------>version4.3.5.RELAESE----->Reference Documentation学习心得----->使用Spring Framework开发自己的应用程序
1.直接基于spring framework开发自己的应用程序: 1.1参考资料: Spring官网spring-framework.4.3.5.RELAESE的Reference Documenta ...
- Spring Framework 5.0.0.M3中文文档 翻译记录 Part I. Spring框架概览1-2.2
Part I. Spring框架概览 The Spring Framework is a lightweight solution and a potential one-stop-shop for ...
随机推荐
- ppt课件动手动脑实际验证
1关于double精度 源代码:public class Doublejingdu { public static void main(String[] args) { System.out.prin ...
- Scrapy项目 - 实现斗鱼直播网站信息爬取的爬虫设计
要求编写的程序可爬取斗鱼直播网站上的直播信息,如:房间数,直播类别和人气等.熟悉掌握基本的网页和url分析,同时能灵活使用Xmind工具对Python爬虫程序(网络爬虫)流程图进行分析. 一.项目 ...
- idea 环境变量设置编码
1.打开Run/Debug Configuration,选择你的tomcat 2.然后在 Server > VM options 设置为 -Dfile.encoding=UTF-8
- Enum枚举的使用实现
业务中涉及到的状态字段或者简单的选择项的使用. 例如: 1.定义enum枚举类. package com.yjl.enums; import java.util.Objects; public enu ...
- thymeleaf 设置display样式
使用th:style标签: th:style="'display:' + @{(${value} ? 'none' : 'inline-block')} + ''" 其中value ...
- 一文读懂Java GC原理和调优
概述 本文介绍GC基础原理和理论,GC调优方法思路和方法,基于Hotspot jdk1.8,学习之后将了解如何对生产系统出现的GC问题进行排查解决 阅读时长约30分钟,内容主要如下: GC基础原理,涉 ...
- MongoDB 学习笔记之 游标
游标: 游标是查询的接口,可以逐条读取. var mycursor = db.bar.find(); mycursor.hasNext(); mycursor.next(); 示例: var mycu ...
- Nginx internal 指令限制访问图片资源文件
Nginx 的 internal 指令可以用来限制 Web 公共目录下的图片等资源文件被任意用户直接访问.一个明显的使用场景是,对于用户上传的认证图片,属于个人隐私资源,不应该让所有用户都能访问得到, ...
- bootstrap-table 页脚总计(自定义统计总数)
•首先给table添加属性: showFooter: footer js代码如下: //初始化bootstrapTableinitBootstrapTable: function () { var o ...
- Web高性能动画及渲染原理(1)CSS动画和JS动画
目录 一. CSS动画 和 JS动画 1.1 CSS动画 1.2 JS动画 1.3 小结 二. 使用Velocity.js实现动画 示例代码托管在:http://www.github.com/dash ...