Spring Java Configuration这个项目提供了一种通过java代码来装配bean

NoSuchKey