I am writing with regards to something I have been experimenting with for the last few days - providing a choice of both Spring 3 and Spring 4 to applications running inside Virgo.
Here is a little background. Virgo 3.7.0 is updating Spring to version 4, which is great! And we, at VMware, have been testing running our application on it for some time now, so we are ready to upgrade as soon as it's officially released. However, we do have a lot of 2nd and 3rd party code that runs in our Virgo instance for which it might take more time to migrate to Spring 4. To mitigate that, I have been trying to make our Virgo work with applications written in both Spring 3 and Spring 4 simultaneously.
So, my question is has anyone on the Virgo dev team (or anyone else) ever tried doing that? I couldn't find examples on the forum or anywhere else on the web. If yes, could you please share some experience and possibly a solution? If not, would you be interested in integrating the change in Virgo, once/if I manage to provide such a functionality?
I havenât heard from someone who tried this before. I do know that giamma and his team for example package some 3rd party libraries in
different versions in their product.
Since this seems like a real world problem others might be facing too we are definitely interested in such a functionality.
Currently, I have implemented a custom ApplicationContext that extends Spring'sorg.springframework.osgi.web.context.support.OsgiBundleXmlWebApplicationContext. This application context is to be used by all apps that are still using Spring 3, while others are using Virgo'sorg.eclipse.virgo.web.dm.ServerOsgiBundleXmlWebApplicationContext. The latest issue I am faced with is not having the app-specific resources (html, js, css) loaded by the custom ApplicationContext. Otherwise, the two versions of Spring look to be coexisting quite well.
Letâs create an issue and continue the discussion there. In case you already created some small examples could you attach them to the issue?