update sample to version 0.3.1