Why does Spring's @Configurable sometimes work and sometimes not?

前端 未结 6 1528
感情败类
感情败类 2020-12-16 18:05

I\'m trying to use automatic dependency injection via Spring\'s @Configurable annotation w/ @Resource on the fields needing injection. This involved some setup, like passing

6条回答
  •  猫巷女王i
    2020-12-16 19:00

    When the injection doesn't work, for whatever reason, there is no way for code to do any dependency check, so there is now error thrown.

    Otherwise I can't see anything here that would indicate the random failure. Can you extract a simplified example to check?

提交回复
热议问题