sample code of spring framework and random java code