implemented observer in groovy (removed from javascript)