• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Annotations Autowired Vs XML based

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

We are seeing an issue slowly in our project as we are using Annotation based implementation and this is leading the Server to take up more time to bring up the application.

When we are with the Regular XML based implementation, there is a consistency in the startup of the timings.

But as we cannot migrate the whole XML based to Annotations, the newer requirements are being implemented using Annotation based and some cases where we had to use a mix n match of both XML based and Annotation based.

We ran into an one issue where the server was not starting up at all and going an infinite loop on one of the linux machine, but working up fine in Windows. So we removed those Annotation beans and the Server was started without any issues.

I heard that Annotation beans will look into the dependencies even the Spring is not loaded fully (i.e, while the Server is at the Startup itself) and XML based on the otherway.

So, can one of you suggest on how to identify the beans which is causing circular dependency by enabling some logging properties or any other tools that will help on this.

thanks in advance
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Venky,
That's an interesting problem. Maybe use the SpringBeanAutowiringInterceptor to log each beans load. And then look at the log to see where it goes recrusive.
 
Venky RamVr
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Jeanne,

I'm using the below log4j property and going to check on this

log4j.logger.org.springframework.beans.factory.annotation=DEBUG,INFO, TRACE

Hope this might give some info
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic