fix codes merged accidentally.
wire spring bean instead of creating an instance manually