Fixed problem with spring and jdk1.8.0 compatibility