fixed #3539, update sample code and articles for 3.0