Adding controller and factory.