Template for using java spring