深入研究spring 必然少不了研究源码。
首先便是编译源码。源代码地址:https://github.com/spring-projects/spring-framework
将分支切换到稳定版本4.3.x分支,这样做是因为稳定版本出现的bug几率较小。
下面几个是编译安装的命令。
./gradlew install
./gradlew build
将spring 项目转为idea项目,具体可以参考目录下import-into-idea.md文件:
./gradlew cleanIdea
问题1:
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':referencePdf'.
> [Java ](http://lib.csdn.net/base/java)heap space ...
看下错误日志,原来是内存溢出,需要调整 gradlew.bat文件中的 MaxHeapSize 的大小
set GRADLE_OPTS=-XX:MaxPermSize=512m -Xmx512m -XX:MaxHeapSize=512m %GRADLE_OPTS%
问题2:
FAILURE: Build failed with an exception.
* What went wrong:
Failed to capture snapshot of input files for task 'distZip' during up-to-date check.
> java.io.FileNo