7 Replies Latest reply on Oct 11, 2013 9:36 AM by rhusar

    Infinispan does not build after clone

    zds

      So, I cloned Infinispan project, switched to tag 5.2.7.Final and.. it does not compile. I pasted the settings.xml listed on the web to the project root, and it still does not compile:

       

      The error:

      [ERROR] BUILD ERROR

      [INFO] ------------------------------------------------------------------------

      [INFO] Failed to resolve dependencies for one or more projects in the reactor. Reason: Unable to get dependency information: Unable to read the metadata file for artifact 'org.jboss.solder:solder-impl:jar': POM 'org.jboss.seam:seam-bom' not found in repository: Unable to download the artifact from any repository

       

       

        org.jboss.seam:seam-bom:pom:3.1.0.Final

       

       

      from the specified remote repositories:

        central (http://repo1.maven.org/maven2)

       

       

      for project org.jboss.seam:seam-bom

        org.jboss.solder:solder-impl:jar:3.1.0.Final

       

       

      from the specified remote repositories:

        central (http://repo1.maven.org/maven2),

        jboss-public-repository (https://repository.jboss.org/nexus/content/groups/public)

       

       

      Path to dependency:

        1) org.infinispan:infinispan-cdi:bundle:5.2.7.Final

       

       

      The "How to contribute" page does not give any commands you need to run to set up the environment; it only lists various repositories.

       

      If you want people to contribute, the project needs to compile with a single command line command after clone. And even if it needs several commands, you need to list the *exact* commands next to each other on one single page. I am not interested in learning crappy build tools, I am interested in patching the actual code.

       

      In addition, the first Google hit for "contribute to Infinispan" is deprecated, and does not contain direct link to the replacement page: Contributing to Infinispan - Infinispan 6.0 - Project Documentation Editor

      These two together make it look like that Red Hat don't really *want* people to contribute. "You are free to contribute, but if you are not Red Hat employee, we'll make it painful enough to make you change plans".

       

      TL;DR: Infinispan project lacks "run these commands and it builds" page. Or even better, a build system that works straight out of the git clone.

        • 1. Re: Infinispan does not build after clone
          sannegrinovero

          So, I cloned Infinispan project, switched to tag 5.2.7.Final and.. it does not compile. I pasted the settings.xml listed on the web to the project root, and it still does not compile:

          [...]

          I'm sorry to hear that, but no other repositories should be needed. I just wiped my local cache, reset my settings.xml to contain just the jboss-public-repository and it seems to build fine.

          I think you either had a networking problem or maybe Nexus was having trouble, as I see the artifact there: https://repository.jboss.org/nexus/index.html#nexus-search;gav~org.jboss.seam~seam-bom~3.1.0.Final~~

           

           

          In addition, the first Google hit for "contribute to Infinispan" is deprecated, and does not contain direct link to the replacement page: Contributing to Infinispan - Infinispan 6.0 - Project Documentation Editor

          So Google is wrong :-)

          Seriously, there is a need for an intermediate page so that you can choose which version, since the build strategy might evolve over time, so I think the link there is correct; do you think we should add a shortcut to http://infinispan.org/docs/6.0.x/contributing/contributing.html ? I suspect it would be outdated soon.

          BTW since you seem interested to build an older version, the information written there should work fine.

           

          These two together make it look like that Red Hat don't really *want* people to contribute. "You are free to contribute, but if you are not Red Hat employee, we'll make it painful enough to make you change plans".

          Point taken :-( Sadly documentation could always be better, and technical problems happen. So feel free to blame the team by I don't think Mr. Red Hat wanted that. Generally speaking though, we don't make it a secret that we want you to contribute on the latest versions.

          [...] Or even better, a build system that works straight out of the git clone.

          It exists in master, you're working on an old codebase. Many improvements are there, many of these annoying painpoints that you are listing have already been fixed...

          • 2. Re: Infinispan does not build after clone
            nadirx

            Jari,

             

            while I understand your pain, trust me: all the artifacts for building Infinispan 5.2.x are either in central or in the JBoss nexus repo.

             

            https://repository.jboss.org/nexus/content/groups/public/org/jboss/seam/seam-bom/3.1.0.Final/seam-bom-3.1.0.Final.pom

             

             

            So the best thing to do is to remove the local directory where maven has stored the potentially broken artifact(s):

             

            rm -rf $HOME/.m2/repository/org/jboss/seam/

             

            Then run mvn clean package again: it should re-download the missing bits.

            • 3. Re: Infinispan does not build after clone
              zds

              OK, so, the rm command did not help. I was working with 5.3.0.Final, as that was the version packaged with the latest Wildfly (8.0.0.Alpha4) at the time of writing. Now, Wildfly 8.0.0.Beta1 landed, so lacking 6.0.0.CR1 tag on the infinispan project I switched to the master. And then I got an useful error message: My maven was 2.something, whereas the project required 3.0.3 or later.

               

              I upgraded my maven, and at least it's still compiling, instead of giving up early on..

               

              It might very well be that the problem was the old version of maven, but for some reason there was no complaints earlier; I would expect maven itself refuse to work if the project uses pom.xml:s for some newer version (or if they are the, then just work).

              • 4. Re: Infinispan does not build after clone
                sannegrinovero
                1 of 1 people found this helpful
                • 5. Re: Infinispan does not build after clone
                  zds

                  Oops.. I didn't know git pull did not bring me the new remote tags automatically. Thank you!

                  • 6. Re: Infinispan does not build after clone
                    zds

                    After upgrading to Maven 3, infinispan builds as long as I disable tests like this: mvn -Dmaven.test.skip=true install

                     

                    This might be close enough for my purposes.

                     

                    The failing tests are these:

                    [testng-ConditionalOperationsConcurrentWriteSkewTest] Test testReplace(org.infinispan.api.ConditionalOperationsConcurrentWriteSkewTest) failed.

                    [testng-NonTxStateTransferOverwritingValue2Test] Test testBackupOwnerJoiningDuringRemove(org.infinispan.distribution.rehash.NonTxStateTransferOverwritingValue2Test) failed.

                     

                    Here's the environment info:

                    ~~~~~~~~~~~~~~~~~~~~~~~~~ ENVIRONMENT INFO ~~~~~~~~~~~~~~~~~~~~~~~~~~

                    jgroups.bind_addr = 127.0.0.1

                    java.runtime.version = 1.7.0_40-b43

                    java.runtime.name =Java(TM) SE Runtime Environment

                    java.vm.version = 24.0-b56

                    java.vm.vendor = Oracle Corporation

                    os.name = Linux

                    os.version = 3.8.0-31-generic

                    sun.arch.data.model = 64

                    sun.cpu.endian = little

                    protocol.stack = null

                    infinispan.test.jgroups.protocol = tcp

                    infinispan.unsafe.allow_jdk8_chm = true

                    java.net.preferIPv4Stack = true

                    java.net.preferIPv6Stack = null

                    log4.configuration = null

                    MAVEN_OPTS = null

                    ~~~~~~~~~~~~~~~~~~~~~~~~~ ENVIRONMENT INFO ~~~~~~~~~~~~~~~~~~~~~~~~~~

                    • 7. Re: Infinispan does not build after clone
                      rhusar

                      After upgrading to Maven 3, infinispan builds as long as I disable tests like this: mvn -Dmaven.test.skip=true install

                      Ouch. To disable tests always use -DskipTests unless you have a reason to use something else (I remember some ISPN versions would not even build with ^ because it would not generate test artefacts needed later in the build...).

                       

                      Read on http://maven.apache.org/surefire/maven-surefire-plugin/examples/skipping-test.html