Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-5099

QueryNode should have the ability to detach from its node parent

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.6.2, 4.3.1
    • Fix Version/s: 4.7
    • Component/s: core/queryparser
    • Labels:
      None

      Description

      QueryNodeProcessorImpl should always return the root of the tree after processing, so it needs to make the parent is set to null before returning. Otherwise, the previous parent is leaked and never removed.

        Activity

        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1560246 from Adriano Crestani in branch 'dev/branches/branch_4x'
        [ https://svn.apache.org/r1560246 ]

        LUCENE-5099 - QueryNode should have the ability to detach from its node parent

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1560246 from Adriano Crestani in branch 'dev/branches/branch_4x' [ https://svn.apache.org/r1560246 ] LUCENE-5099 - QueryNode should have the ability to detach from its node parent
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1560245 from Adriano Crestani in branch 'dev/trunk'
        [ https://svn.apache.org/r1560245 ]

        LUCENE-5099 - QueryNode should have the ability to detach from its node parent

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1560245 from Adriano Crestani in branch 'dev/trunk' [ https://svn.apache.org/r1560245 ] LUCENE-5099 - QueryNode should have the ability to detach from its node parent
        Hide
        adriano_crestani Adriano Crestani added a comment -

        These are the proposed changes. I will commit in a couple of days if there are no objections.

        Show
        adriano_crestani Adriano Crestani added a comment - These are the proposed changes. I will commit in a couple of days if there are no objections.
        Hide
        adriano_crestani Adriano Crestani added a comment -

        After some investigation, I reached the conclusion that QueryNodeProcessorImpl should never take the decision of detaching the returned processed node from its parent. It should be up to the processor implementor logic or to the processor user to take that decision. For that reason, I have renamed this JIRA.

        Instead, we should add a method to QueryNode so the processor implementor or user could detach nodes from their parents.

        Show
        adriano_crestani Adriano Crestani added a comment - After some investigation, I reached the conclusion that QueryNodeProcessorImpl should never take the decision of detaching the returned processed node from its parent. It should be up to the processor implementor logic or to the processor user to take that decision. For that reason, I have renamed this JIRA. Instead, we should add a method to QueryNode so the processor implementor or user could detach nodes from their parents.

          People

          • Assignee:
            adriano_crestani Adriano Crestani
            Reporter:
            adriano_crestani Adriano Crestani
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development