I am rather noob at java jars deployment. I have following scenario: I have about 6 projects in eclipse and they are of various types (core project for common interfaces, projects containing osgi bundles, project with tests, project with servlets for web deployment).
I have growing problem of getting anything deployed quickly, today I am faced with OSGi bundle deployments, I want to quickly and reliably package my bundle and deploy it into container. Up to this day i was just doing it stupidly by exporting jar through eclipse and then editing the manifest.
I think the best way (without too much work) would be using one big Ant buildfile with targets that will solve things I need most urgently (createing OSGi bundles now) and then move more build logic, step by step, from eclipse into build file (i understand there is a easy way to run ant targets through eclipse and even replace autoprojectbuild logic of eclipse with custom build file).
So this is my plan:
1) create 1 master build file with everything in src directory (containing all projects)
2) create task for building project with OSGi bundle. Using manifest.txt with handcrafted manifest for my bundle and Copy Paste (via ant task) all jars, needed in this bundle and use Bundle-ClassPath to declare my inner bundle dependencies
3) create JUnit test runners as custom targets
4) create other targets for building various projects
5) finally before release, create big target "dist" to package whole software
So my 2 questions are:
Is this plan of mine good (in terms of development time and reasonable complexity)?
Are there any drawbacks using 1 big buildfile? I read part of Ant in Action book but it looks like multiple build files just causes more complications (it's not easy to declare dependencies between projects. OTH with 1 big file i can use target depends attribute).