[jira] Created: (LUCENE-1079) DocValues cleanup: constructor & getInnerArray()

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (LUCENE-1079) DocValues cleanup: constructor & getInnerArray()

JIRA jira@apache.org
DocValues cleanup: constructor & getInnerArray()
------------------------------------------------

                 Key: LUCENE-1079
                 URL: https://issues.apache.org/jira/browse/LUCENE-1079
             Project: Lucene - Java
          Issue Type: Improvement
          Components: Search
    Affects Versions: 2.3
            Reporter: Doron Cohen
            Assignee: Doron Cohen
            Priority: Minor
             Fix For: 2.3


DocValues constructor taking a numDocs parameter is not very clean.
Get rid of this.

Also, it's optional getInnerArray() method is not very clean.
This is necessary for better testing, but currently tests will fail if it is not implemented.
Modify it to throw UnSupportedOp exception (rather than returning an empty array).
Modify tests to not fail but just warn if the tested iml does not override it.

These changes should make it easier to implement DocValues for other ValueSource's, e.g. above payloads, with or without caching.


--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (LUCENE-1079) DocValues cleanup: constructor & getInnerArray()

JIRA jira@apache.org

     [ https://issues.apache.org/jira/browse/LUCENE-1079?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Doron Cohen updated LUCENE-1079:
--------------------------------

    Attachment: lucene-1079-func-doc-values-cleanup.patch

In this patch:

* default getInnerArray throws (UnsupportedOperationException
* only warn if tested DocValues.getInnerArray() throws this exception but other than that test passes
* constructor does not need numDocs arg
* optional iteration on values to compute average etc. just loops until catching ArrayIndexOutOfBoundsException.

All search.function tests pass.

> DocValues cleanup: constructor & getInnerArray()
> ------------------------------------------------
>
>                 Key: LUCENE-1079
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1079
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: Search
>    Affects Versions: 2.3
>            Reporter: Doron Cohen
>            Assignee: Doron Cohen
>            Priority: Minor
>             Fix For: 2.3
>
>         Attachments: lucene-1079-func-doc-values-cleanup.patch
>
>
> DocValues constructor taking a numDocs parameter is not very clean.
> Get rid of this.
> Also, it's optional getInnerArray() method is not very clean.
> This is necessary for better testing, but currently tests will fail if it is not implemented.
> Modify it to throw UnSupportedOp exception (rather than returning an empty array).
> Modify tests to not fail but just warn if the tested iml does not override it.
> These changes should make it easier to implement DocValues for other ValueSource's, e.g. above payloads, with or without caching.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[jira] Resolved: (LUCENE-1079) DocValues cleanup: constructor & getInnerArray()

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

     [ https://issues.apache.org/jira/browse/LUCENE-1079?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Doron Cohen resolved LUCENE-1079.
---------------------------------

       Resolution: Fixed
    Lucene Fields: [Patch Available]  (was: [Patch Available, New])

Committed.

> DocValues cleanup: constructor & getInnerArray()
> ------------------------------------------------
>
>                 Key: LUCENE-1079
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1079
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: Search
>    Affects Versions: 2.3
>            Reporter: Doron Cohen
>            Assignee: Doron Cohen
>            Priority: Minor
>             Fix For: 2.3
>
>         Attachments: lucene-1079-func-doc-values-cleanup.patch
>
>
> DocValues constructor taking a numDocs parameter is not very clean.
> Get rid of this.
> Also, it's optional getInnerArray() method is not very clean.
> This is necessary for better testing, but currently tests will fail if it is not implemented.
> Modify it to throw UnSupportedOp exception (rather than returning an empty array).
> Modify tests to not fail but just warn if the tested iml does not override it.
> These changes should make it easier to implement DocValues for other ValueSource's, e.g. above payloads, with or without caching.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]