java - What is the difference between declaring @Autowired and declaring bean in the application context -


i build spring project1 of module1 jar file, added jar file dependency in module2 of project2, module2 added in project3. now, while starting tomcat service getting error nosuchbeandefinitionexception module1 class object.

while checking module2 code found injected module1 class object using @autowired annotation, including bean declaration in xml (<bean id="object" class="claspackage"/>. issue has been fixed. unable find root cause this, how bean functionality got differs?


Comments

Popular posts from this blog

Email notification in google apps script -

c++ - Difference between pre and post decrement in recursive function argument -

javascript - IE11 incompatibility with jQuery's 'readonly'? -