Read the post on CodeProject: (link soon) or on my blog: http://en.morzel.net/post/2015/02/18/OoB-Controlling-gun-turret-with-Spring-Boot-REST-service-(JavaArduino).aspx
This code was created over 6 years ago so it's likely that some of dependencies might be outdated...
This fork: https://github.com/JoeBanjo5050/blog-post-spring-arduino might contain usueful updates.