Ron said: > *If a JAR does not contain all of the dependencies that it needs, a > person using that JAR must have some way to know what is missing and what > version is required. > They will only find out at run-time that this jar depends on a missing > dependency when the loader crashes. > The documentation of the utility will have to have big red sentences > describing each of the missing dependencies. > This will make it much harder for the IDE to help the programmer. Now the > IDE can detect version conflicts based on references in the POM and can let > the developer resolve them.* >
I never said to skip the provided dependencies at all. What I suggested was to remove the 'provided' option from the <scope> element in order to limit the POM creator to specify the requirements of the artifact only, and not hints of how his artifact and its dependencies are going to be assembled or deployed. Instead of 'provided' he has to use 'compile' or 'runtime'. This way the POM will contain all the necessary information needed but no more. Who determines what to assembly and/or how to deploy should be entirely the assembly module (the one with EAR packaging type by example). There is where the decisions on what to include in the assembly and how to deploy must be taken, and not before.
