adopt to use config file