Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can Maven's provided scoping, be transitive?

I have an Ancestor dependency has dependent scoped as provided, I need to propagate that scoping to anything that depends on my project.

For example, say I have SomeProjectA which depends on SomeLibraryB. I need to scope SomeLibraryB has provided.

Currently to compile anything that depends on SomeProjectA, has to also set SomeLibraryB has provided. I would rather propagate that scoping, then have any project that depend on mine deal with my project's dependents..

like image 471
Nicholas Marshall Avatar asked Sep 13 '13 19:09

Nicholas Marshall


People also ask

Are provided dependencies transitive?

provided dependencies are available on the compilation classpath (not runtime). They are not transitive, nor are they packaged. runtime. runtime dependencies are required to execute and test the system, but they are not required for compilation.

Which dependency is not transitive?

Database Development Process A table is in 3NF if it is in 2NF and it contains no transitive dependencies; that is, a condition in which an attribute (non-primary-key) is dependent on another attribute (non-primary-key) that is not part of the primary key.

Are runtime dependencies transitive?

Runtime: Such a dependency isn't available in the compile-classpath but is present in the test-classpath as well as the runtime-classpath. It is transitive.


1 Answers

I dont think that is possible. Each project should declare provided dependencies on its own. Propagating that scope would be wrong since you would make an assumption about the deployment that you cant make since you are not responsible for the deployment. The user of your library does that..

like image 149
Manfred Moser Avatar answered Sep 16 '22 23:09

Manfred Moser