You could shorten that up a bit by using the p and c namespaces but it gives you the idea. Put your properties in a file named jdbc.properties on the classpath.
Once you have that you can @Autowire in you jdbcTemplate and use that to execute queries.