Moved task definition from java to resources