Should the mirror id be unique in maven

What will happen if i have two mirrors with same id in the settings.xml file?

Which one will be taken into account?

Answers


It won't do anything more than 1 repo. You can even use it to have different mirrors with the same credentials.

But consider that you could did it by yourself ... This is a trivial question which take 1 minutes + build time to test by yourself.

Nevertheless :

<mirrors>
    <mirror>
        <id>mirror.repo.myorg.fr</id>
        <mirrorOf>!tiers-providers-public-snapshots,*</mirrorOf>
        <name>Repository Artifactory for snapshots.</name>
        <url>http://mirror.repo.myorg.fr/artifactory/repo-snapsthot</url>
    </mirror>
    <mirror>
        <id>mirror.repo.myorg.fr</id>
        <mirrorOf>!tiers-providers-public,*</mirrorOf>
        <name>Repository Artifactory for realeases</name>
        <url>http://mirror.repo.myorg.fr/artifactory/repo</url>
    </mirror>
</mirrors>

This is the same machine, but two mirrors for differents purposes. I'm not sure this case would happen, but it is not so far of my own configuration.

I tried it, and it's obviously working.


Need Your Help

MySQL-python installation - wrong architecture - MacOS

python mysql django macos python-2.7

yesterday I've installed new version of python 2.7.5 via installer on MacOS

jQuery Appending content in a list

jquery append

Hi Im working on a project where on clicking an image will generate a summary about the image clicked. There is about 50 images that can be clicked.I want to append the summary in a list and I want...