examples about how to use thrift to write a program.