some work on method dispatcher
fixed small issue in generating env. variables