Solr
  1. Solr
  2. SOLR-697

Update Lucene jar before 1.3 release (was: Lucene TimeLimitCollector)

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.3
    • Fix Version/s: 1.3
    • Component/s: update
    • Labels:
      None

      Description

      When instantiating a SolrCore using the Solr API, a Lucene exception is thrown

      {{
      org.apache.solr.core.SolrResourceLoader createClassLoader
      INFO: Reusing parent classloader
      Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/lucene/search/TimeLimitedCollector$TimeExceededException
      at org.apache.solr.core.SolrConfig.<init>(SolrConfig.java:132)
      at org.apache.solr.core.SolrConfig.<init>(SolrConfig.java:101)
      ...
      }}

      Updating the lucene-core-2.4-dev.jar that is included in the nightly to a more current snapshot resolves the problem (tested with Lucene r685576).

        Activity

        Hide
        Lars Kotthoff added a comment -

        I can't reproduce this using the Lucene jars from Solr trunk. Also if I unjar lucene-core-2.4-dev.jar I can see the class file org/apache/lucene/search/TimeLimitedCollector$TimeExceededException.class. Did your servlet container perhaps not deploy the Lucene jars with the application?

        Show
        Lars Kotthoff added a comment - I can't reproduce this using the Lucene jars from Solr trunk. Also if I unjar lucene-core-2.4-dev.jar I can see the class file org/apache/lucene/search/TimeLimitedCollector$TimeExceededException.class. Did your servlet container perhaps not deploy the Lucene jars with the application?
        Hide
        Shalin Shekhar Mangar added a comment -

        I can see the TimeLimitedCollector and TimeExceededException classes in the lucene-core-2.4-dev.jar which is checked in to the repository.

        Can you please check your classpath again?

        Show
        Shalin Shekhar Mangar added a comment - I can see the TimeLimitedCollector and TimeExceededException classes in the lucene-core-2.4-dev.jar which is checked in to the repository. Can you please check your classpath again?
        Hide
        Wayne Graham added a comment -

        I was seeing the class file in the classpath, which made this a little difficult to track down.

        When I was going through the debugging, I found this (http://www.nabble.com/TimeExceededException-td18754724.html) where Yonik suggested an old Lucene jar that was laying around. I grabbed the trunk and replaced the file and the problem went away. I didn't go much further than that in trying to figure out what was causing the issue.

        I'm not sure when the snapshot was taken for Solr, but there was a bug that fixed intermittent failures of TestTimeLimitedCollector (LUCENE-1238) which may be a contributing cause.

        Show
        Wayne Graham added a comment - I was seeing the class file in the classpath, which made this a little difficult to track down. When I was going through the debugging, I found this ( http://www.nabble.com/TimeExceededException-td18754724.html ) where Yonik suggested an old Lucene jar that was laying around. I grabbed the trunk and replaced the file and the problem went away. I didn't go much further than that in trying to figure out what was causing the issue. I'm not sure when the snapshot was taken for Solr, but there was a bug that fixed intermittent failures of TestTimeLimitedCollector ( LUCENE-1238 ) which may be a contributing cause.
        Hide
        Otis Gospodnetic added a comment -

        It's a little hard to understand the last comment. Are you saying you were using some old Solr snapshot when you saw the error (possibly even with some old Lucene jar), and now that you are using Solr trunk everything works?
        Please confirm and if so, we'll close this issue.

        Show
        Otis Gospodnetic added a comment - It's a little hard to understand the last comment. Are you saying you were using some old Solr snapshot when you saw the error (possibly even with some old Lucene jar), and now that you are using Solr trunk everything works? Please confirm and if so, we'll close this issue.
        Hide
        Wayne Graham added a comment -

        Sorry for the confusion...

        I was using Solr nightly (2008-08-13) and was having the issue. I grabbed the Lucene trunk at r685576 and replaced the lucene-core-2.4-dev.jar from the Lucene trunk in the Solr lib folder and the exception went away.

        Show
        Wayne Graham added a comment - Sorry for the confusion... I was using Solr nightly (2008-08-13) and was having the issue. I grabbed the Lucene trunk at r685576 and replaced the lucene-core-2.4-dev.jar from the Lucene trunk in the Solr lib folder and the exception went away.
        Hide
        Lars Kotthoff added a comment -

        Otis, hang on. I think Wayne is saying that the error occurs when using Solr trunk as it is, but when he replaces the Lucene jar checked in with Solr with a Lucene jar he built himself from Lucene trunk, it's fine. In that case we probably need to replace the Lucene jars checked in with Solr. Wayne, is this correct?

        Show
        Lars Kotthoff added a comment - Otis, hang on. I think Wayne is saying that the error occurs when using Solr trunk as it is, but when he replaces the Lucene jar checked in with Solr with a Lucene jar he built himself from Lucene trunk, it's fine. In that case we probably need to replace the Lucene jars checked in with Solr. Wayne, is this correct?
        Hide
        Wayne Graham added a comment -

        Lars, yes you are correct. The Lucene jars in the Solr trunk appear to be causing the issue I was experiencing. If someone could commit a newer version of the Lucene jars into the trunk, it would fix at least this issue. So far, the new Lucene jars haven't broken anything else (at least that I've noticed).

        Show
        Wayne Graham added a comment - Lars, yes you are correct. The Lucene jars in the Solr trunk appear to be causing the issue I was experiencing. If someone could commit a newer version of the Lucene jars into the trunk, it would fix at least this issue. So far, the new Lucene jars haven't broken anything else (at least that I've noticed).
        Hide
        Otis Gospodnetic added a comment -

        Ahaaa!

        Show
        Otis Gospodnetic added a comment - Ahaaa!
        Hide
        Lars Kotthoff added a comment -

        Can we update the jars rather sooner than later (i.e. now) so that people get a chance to test everything before the 1.3 release?

        Show
        Lars Kotthoff added a comment - Can we update the jars rather sooner than later (i.e. now) so that people get a chance to test everything before the 1.3 release?
        Hide
        Yonik Seeley added a comment -

        Resolving... I just updated the lucene jars.

        Show
        Yonik Seeley added a comment - Resolving... I just updated the lucene jars.
        Hide
        Lars Kotthoff added a comment -

        Wayne, can you verify that the issue is fixed please?

        Show
        Lars Kotthoff added a comment - Wayne, can you verify that the issue is fixed please?
        Hide
        Wayne Graham added a comment -

        Lars,

        I just tested my code against last night's build and the problem has been resolved.

        Thanks Yonik!

        Show
        Wayne Graham added a comment - Lars, I just tested my code against last night's build and the problem has been resolved. Thanks Yonik!

          People

          • Assignee:
            Unassigned
            Reporter:
            Wayne Graham
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development