added a service layer; incremental
make the code worser and worser