ch16
tojson
thread and control