Why mutiple local jar under a same maven groupId, artifactId and version?












1















I'm modifying the version of a jar config from 1.0.28 to 1.0.29-SNAPSHOT in my pom.xml for updating it. But I've found two jars in my local repository folder. Specially, the central repository is maintained by my company.



The maven version I've used is 2.2.1, and the version of jdk is 1.8.0_151



<dependency>
<groupId>com.my.company</groupId>
<artifactId>common</artifactId>
<version>1.0.29-SNAPSHOT</version>
</dependency>


I only need common-1.0.29-SNAPSHOT.jar. But I don't know why there is common-1.0.29-20181228.142316-1.jar here.



This is the file list on my computer:



-rw-r--r--    1    staff    staff    255     Dec    29    10:04    _remoterepositories
-rw-r--r-- 1 staff staff 371 Jan 2 09:53 maven-metadata-centralxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:53 maven-metadata-centralxmlsha1
-rw-r--r-- 1 staff staff 1002 Jan 2 09:51 maven-metadata-mirror-allxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:51 maven-metadata-mirror-allxmlsha1
-rw-r--r-- 1 staff staff 191 Jan 2 09:51 resolver-statusproperties
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-20181228142316-1jar
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1jarsha1
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-20181228142316-1pom
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1pomsha1
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-SNAPSHOTjar
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-SNAPSHOTpom









share|improve this question

























  • Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

    – khmarbaise
    Jan 2 at 7:54
















1















I'm modifying the version of a jar config from 1.0.28 to 1.0.29-SNAPSHOT in my pom.xml for updating it. But I've found two jars in my local repository folder. Specially, the central repository is maintained by my company.



The maven version I've used is 2.2.1, and the version of jdk is 1.8.0_151



<dependency>
<groupId>com.my.company</groupId>
<artifactId>common</artifactId>
<version>1.0.29-SNAPSHOT</version>
</dependency>


I only need common-1.0.29-SNAPSHOT.jar. But I don't know why there is common-1.0.29-20181228.142316-1.jar here.



This is the file list on my computer:



-rw-r--r--    1    staff    staff    255     Dec    29    10:04    _remoterepositories
-rw-r--r-- 1 staff staff 371 Jan 2 09:53 maven-metadata-centralxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:53 maven-metadata-centralxmlsha1
-rw-r--r-- 1 staff staff 1002 Jan 2 09:51 maven-metadata-mirror-allxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:51 maven-metadata-mirror-allxmlsha1
-rw-r--r-- 1 staff staff 191 Jan 2 09:51 resolver-statusproperties
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-20181228142316-1jar
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1jarsha1
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-20181228142316-1pom
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1pomsha1
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-SNAPSHOTjar
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-SNAPSHOTpom









share|improve this question

























  • Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

    – khmarbaise
    Jan 2 at 7:54














1












1








1








I'm modifying the version of a jar config from 1.0.28 to 1.0.29-SNAPSHOT in my pom.xml for updating it. But I've found two jars in my local repository folder. Specially, the central repository is maintained by my company.



The maven version I've used is 2.2.1, and the version of jdk is 1.8.0_151



<dependency>
<groupId>com.my.company</groupId>
<artifactId>common</artifactId>
<version>1.0.29-SNAPSHOT</version>
</dependency>


I only need common-1.0.29-SNAPSHOT.jar. But I don't know why there is common-1.0.29-20181228.142316-1.jar here.



This is the file list on my computer:



-rw-r--r--    1    staff    staff    255     Dec    29    10:04    _remoterepositories
-rw-r--r-- 1 staff staff 371 Jan 2 09:53 maven-metadata-centralxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:53 maven-metadata-centralxmlsha1
-rw-r--r-- 1 staff staff 1002 Jan 2 09:51 maven-metadata-mirror-allxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:51 maven-metadata-mirror-allxmlsha1
-rw-r--r-- 1 staff staff 191 Jan 2 09:51 resolver-statusproperties
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-20181228142316-1jar
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1jarsha1
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-20181228142316-1pom
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1pomsha1
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-SNAPSHOTjar
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-SNAPSHOTpom









share|improve this question
















I'm modifying the version of a jar config from 1.0.28 to 1.0.29-SNAPSHOT in my pom.xml for updating it. But I've found two jars in my local repository folder. Specially, the central repository is maintained by my company.



The maven version I've used is 2.2.1, and the version of jdk is 1.8.0_151



<dependency>
<groupId>com.my.company</groupId>
<artifactId>common</artifactId>
<version>1.0.29-SNAPSHOT</version>
</dependency>


I only need common-1.0.29-SNAPSHOT.jar. But I don't know why there is common-1.0.29-20181228.142316-1.jar here.



This is the file list on my computer:



-rw-r--r--    1    staff    staff    255     Dec    29    10:04    _remoterepositories
-rw-r--r-- 1 staff staff 371 Jan 2 09:53 maven-metadata-centralxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:53 maven-metadata-centralxmlsha1
-rw-r--r-- 1 staff staff 1002 Jan 2 09:51 maven-metadata-mirror-allxml
-rw-r--r-- 1 staff staff 41 Jan 2 09:51 maven-metadata-mirror-allxmlsha1
-rw-r--r-- 1 staff staff 191 Jan 2 09:51 resolver-statusproperties
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-20181228142316-1jar
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1jarsha1
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-20181228142316-1pom
-rw-r--r-- 1 staff staff 40 Dec 29 10:04 common-1029-20181228142316-1pomsha1
-rw-r--r-- 1 staff staff 48058 Dec 29 10:04 common-1029-SNAPSHOTjar
-rw-r--r-- 1 staff staff 7801 Dec 29 10:04 common-1029-SNAPSHOTpom






maven






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jan 2 at 5:49









Ankur Aggarwal

1,64922631




1,64922631










asked Jan 2 at 2:55









CamelCamel

215




215













  • Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

    – khmarbaise
    Jan 2 at 7:54



















  • Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

    – khmarbaise
    Jan 2 at 7:54

















Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

– khmarbaise
Jan 2 at 7:54





Really using Maven 2? Please upgrade as soon as possible to Maven 3.6.0...Maven 2 is End Of Live

– khmarbaise
Jan 2 at 7:54












1 Answer
1






active

oldest

votes


















0














This is how Maven keeps track of what -SNAPSHOT actually means in the local repository. It is the timestamp for (if I recall correctly) when the artifact was installed.



A guess could be that a copy is kept in case an install process does not succeed for rollback.






share|improve this answer























    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54000730%2fwhy-mutiple-local-jar-under-a-same-maven-groupid-artifactid-and-version%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    This is how Maven keeps track of what -SNAPSHOT actually means in the local repository. It is the timestamp for (if I recall correctly) when the artifact was installed.



    A guess could be that a copy is kept in case an install process does not succeed for rollback.






    share|improve this answer




























      0














      This is how Maven keeps track of what -SNAPSHOT actually means in the local repository. It is the timestamp for (if I recall correctly) when the artifact was installed.



      A guess could be that a copy is kept in case an install process does not succeed for rollback.






      share|improve this answer


























        0












        0








        0







        This is how Maven keeps track of what -SNAPSHOT actually means in the local repository. It is the timestamp for (if I recall correctly) when the artifact was installed.



        A guess could be that a copy is kept in case an install process does not succeed for rollback.






        share|improve this answer













        This is how Maven keeps track of what -SNAPSHOT actually means in the local repository. It is the timestamp for (if I recall correctly) when the artifact was installed.



        A guess could be that a copy is kept in case an install process does not succeed for rollback.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Jan 2 at 4:50









        Thorbjørn Ravn AndersenThorbjørn Ravn Andersen

        58k24149289




        58k24149289
































            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54000730%2fwhy-mutiple-local-jar-under-a-same-maven-groupid-artifactid-and-version%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Mossoró

            Error while reading .h5 file using the rhdf5 package in R

            Pushsharp Apns notification error: 'InvalidToken'