ESSENTIALS-393: switch default template to freemarker, and fix a few warnings encountered during testing.