Add @Component to the class....example below: @Component public class Customers{ // code of choice goes here }