What will happen if I don't specify a version for a Maven dependency? -


i have seen in project maven dependency specified following,

        <dependency>             <groupid>org.apache.poi</groupid>             <artifactid>poi</artifactid>         </dependency> 

there no version defined in dependency, happen if don't give version name , why given above.

would 1 explain reason please.

i don't think can in ordinary dependency section of poject. case know allowed when inherit parent project <dependencymanagement> section, used coordinate dependency versions across set of projects. can use "shorthand" definition, without version. still have version, inherits dependency defined in parent project.

there other places in pom can drop version well, not directly relevant including dependencies (like plugins/exludes etc).


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

javascript - Clean way to programmatically use CSS transitions from JS? -

android - send complex objects as post php java -