Fixes for Groovy upgrade