Solr
  1. Solr
  2. SOLR-2771

Solr modules' tests should not depend on solr-core test classes; move BufferingRequestProcessor from solr-core tests to test-framework so that solr cell can use it

    Details

      Description

      From Steven Rowe in SOLR-2540:

      Both the trunk and the branch_3x Jenkins Maven builds failed last night because the Maven configuration for the solr/contrib/extraction/ module does not depend on solr-core test code, and you just introduced a new solr-core test class BufferingRequestProcessor, as well as test code in Solr Cell that uses this class.

      (BTW, none of the other Solr modules depend on Solr test code in the Maven configuration.)

      Apparently the Ant build system still includes solr-core test classes in the test classpath of the other Solr modules. I think this should be fixed; Solr's test-framework makes this dependency obsolete.

      In the short term, though, can we move the new BufferingRequestProcessor class from solr/core/src/test to solr/test-framework/src/java/? That way, the Maven stuff will work again without having to jump through hoops like publishing a solr-core test jar and making other modules have a test dependency on it (that's the way it worked pre-test-framework).

      1. SOLR-2771.patch
        7 kB
        Jan Høydahl
      2. SOLR-2771.patch
        8 kB
        Jan Høydahl
      3. SOLR-2771-branch_3x.patch
        8 kB
        Jan Høydahl
      4. SOLR-2771-branch_3x.patch
        4 kB
        Steve Rowe
      5. SOLR-2771.patch
        4 kB
        Steve Rowe

        Issue Links

          Activity

          Hide
          Jan Høydahl added a comment -

          Patch for trunk

          Show
          Jan Høydahl added a comment - Patch for trunk
          Hide
          Robert Muir added a comment -
          Apparently the Ant build system still includes solr-core test classes in the test classpath of the other Solr modules. I think this should be fixed; Solr's test-framework makes this dependency obsolete.
          

          +1, i thought we already did this? Maybe it was just with lucene-core test classes...

          Show
          Robert Muir added a comment - Apparently the Ant build system still includes solr-core test classes in the test classpath of the other Solr modules. I think this should be fixed; Solr's test-framework makes this dependency obsolete. +1, i thought we already did this? Maybe it was just with lucene-core test classes...
          Hide
          Jan Høydahl added a comment -

          Planning to commit the two attached patches...
          If you have a patch for the build, we could fix that as well

          Show
          Jan Høydahl added a comment - Planning to commit the two attached patches... If you have a patch for the build, we could fix that as well
          Hide
          Steve Rowe added a comment -

          If you have a patch for the build, we could fix that as well

          I don't yet, but I plan on working on it later today.

          Show
          Steve Rowe added a comment - If you have a patch for the build, we could fix that as well I don't yet, but I plan on working on it later today.
          Hide
          Jan Høydahl added a comment -

          Ok, feel free to extend the existing patch(es)

          Show
          Jan Høydahl added a comment - Ok, feel free to extend the existing patch(es)
          Hide
          Steve Rowe added a comment -

          These patches include a fix for the ant build, so that Solr modules' test.classpath no longer contains the solr-core test classes: I just removed it from the solr.test.base.classpath definition in solr/common-build.xml.

          I also redid the patches so that they depend on the following svn movement script having been run first (to preserve the file history across the move):

          svn --parents move solr/core/src/test/org/apache/solr/handler/BufferingRequestProcessor.java solr/test-framework/src/java/org/apache/solr/update/processor/BufferingRequestProcessor.java
          

          Committing shortly.

          Show
          Steve Rowe added a comment - These patches include a fix for the ant build, so that Solr modules' test.classpath no longer contains the solr-core test classes: I just removed it from the solr.test.base.classpath definition in solr/common-build.xml . I also redid the patches so that they depend on the following svn movement script having been run first (to preserve the file history across the move): svn --parents move solr/core/src/test/org/apache/solr/handler/BufferingRequestProcessor.java solr/test-framework/src/java/org/apache/solr/update/processor/BufferingRequestProcessor.java Committing shortly.
          Hide
          Steve Rowe added a comment -

          Committed to branch_3x and trunk.

          Show
          Steve Rowe added a comment - Committed to branch_3x and trunk.
          Hide
          Uwe Schindler added a comment -

          Bulk close after 3.5 is released

          Show
          Uwe Schindler added a comment - Bulk close after 3.5 is released

            People

            • Assignee:
              Steve Rowe
              Reporter:
              Jan Høydahl
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development