change log locations, add Dao over HQL
add transaction test