configure method to controller