How to develop OSGI with IntelliJ?


  1. How to develop OSGI application using IntelliJ?
  2. Can you provide any tutorials showing IntelliJ support?
  3. Is there a “live reload” or “rebuild all bundles with modified classes”?
  4. Can I attach outside Apache Felix to InteliJ in order to deploy newly created bundles to the local server?


Current situation:

My company is joining a big project with different vendors already on-board. The project is being developed using OSGI bundles. It is a multi-module maven project using blueprint for DI and maven-bundle-plugin for manifest generation. Customer provided us with OSGI server (Apache Felix) along with configuration files needed to run application. My team is using Ultimate version of Intelij

The problem is that I have no idea how to develop in OSGI environment. I would like for Intelij to figure out on its own which files have been changed and based on that build bundle jars and deploy them to server running locally. For smaller projects it would be ok to just rebuild whole project after each change but due to size of this project it’s not possible, too long.

Configuration of the application is provided outside of jars/bundles so I think it rolls out the possibility of using built-in Felix for development even if IntelliJ where to provide such functionality. At this moment my team won’t be developing new bundles so I am interested in support of modifying existing bundles much more than the support of creating new ones.

I have basic understanding of OSGI. Please post any resources that can be of help. I am aware of OSMORC plugin but I don’t really understand what benefits it gives. I read as well about Bndtools but the tool seems intended for Eclipse much more than IntleiJ. Please help. My team is happy with InteliJ and we would hate to be forced to go back to Eclipse.