I am new Springs. In Bean tag I found factory-method and factory-bean Attributes. What is the difference between factory-method and factory-bean?
I am using factory-meth
A FactoryBean is used as factory for other beans/objects. It cannot be used as bean itself.
The factory-method
can be used to define the method that should be used to create this bean (instead of calling the constructor). A bean with a factory method can be used as a bean itself.
Spring can create bean instances using many different factory types. This is useful if you want to integrate libraries/legacy classes that are bound to a particular type.