implement #5.
the validations of transactional_function is now availabled.