add controller factory