Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

OSGI : Exporting services defined by @Service annotation

 
Craig Taylor
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If I have a class defined as :

.


how can I define my osgi bundle to pick up and export all services with the @Service annotation?
 
Craig Taylor
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In search of a solution to my problem I've written a service activator which is essentially just :



however, I'm getting a statement that the context has not yet been initialized. From the servicemix logs it appears that the context has already been loaded, or at least, a significant chunk has.

I guess the question now boils down to : How can I delay activation of the ServiceActivator until the application context has finished?

Thanks,
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic