Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

create a start up class using sprong framework

 
manish gupta
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I want a class which create a new thread and this class I want to be a startup class in spring framework.

will appriciate you reply.

Thanks in adwance.

Manish
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not entirely sure what you're asking, but you may just need an ApplicationListener bean that looks for ContextStarted or ContextRefreshedEvents (my names might be a bit off; this is from memory).
 
manish gupta
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Devid ,

Thanks for reply.

My question is how we can configure any java class as astartup class using springframework?

with regards
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If they're beans, make them application event listeners, and listen for the events I already mentioned... I'm not sure what else you need to know.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic