genLog doesn't need lock
update example