解决:Parameter 0 of constructor in xxx required a bean of type ‘xxx‘ that could not be found.

运行报错:

Parameter 0 of constructor in com.xxx.Crawler required a bean of type 'java.lang.String' that could not be found.

修复方案:
添加一个默认的无参构造器在类中,如:

public Crawler(){
    super("logs", false);
}

你可能感兴趣的:(问题排错,java)