You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Adriano Crestani (JIRA)" <ji...@apache.org> on 2011/01/13 17:33:45 UTC

[jira] Created: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Change contrib QP API that uses CharSequence as string identifier
-----------------------------------------------------------------

                 Key: LUCENE-2867
                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
             Project: Lucene - Java
          Issue Type: Improvement
          Components: contrib/*
    Affects Versions: 3.0.3
            Reporter: Adriano Crestani
            Priority: Minor
             Fix For: 3.0.4


There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Updated: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Adriano Crestani (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adriano Crestani updated LUCENE-2867:
-------------------------------------

    Attachment: lucene_2867_adriano_crestani_2011_01_13.patch

Here is the patch that deprecates methods using CharSequence. Can someone please review if I did the API deprecation correctly?

I was thinking initially that deprecated methods would be removed on version 4, I'm not sure anymore. Will it be removed on 4 or 3.1?

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Resolved: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Adriano Crestani (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adriano Crestani resolved LUCENE-2867.
--------------------------------------

    Resolution: Fixed
      Assignee: Adriano Crestani

Thanks for reviewing the patch Simon!

The patch was applied on revision 1059436

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Adriano Crestani (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12982394#action_12982394 ] 

Adriano Crestani commented on LUCENE-2867:
------------------------------------------

Hi Simon,

bq. Usually we put changes into trunk first and then move them to the branches though.

Thanks for letting me know about the correct procedure, I will follow it next time. I'm planning to open another JIRA to commit the changes agains the trunk soon.

bq. Now this issues has been closed / resolved and it has not been committed to trunk and neither to 3.0.4 as stated in the FixVersion? Now I am confused...

My misunderstanding here, at first, I thought 3x_branch was the next release 3.0.4, I just realized that 3.0.4 is the 3.0 version with bug fixes and 3x_branch is the code for next 3 version (3.1?). So I still need to propagate the API changes to 3.0 branch and trunk (4.0).

Now I'm confused about what is the main difference between 3.0.x and 3.x. Can any API changes go in 3.0.4 or just bug fixes?

Thanks,
Adriano Crestani

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Simon Willnauer (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12981640#action_12981640 ] 

Simon Willnauer commented on LUCENE-2867:
-----------------------------------------

bq. Here is the patch that deprecates methods using CharSequence. Can someone please review if I did the API deprecation correctly?
those comments and annotations look good!

bq. I was thinking initially that deprecated methods would be removed on version 4, I'm not sure anymore. Will it be removed on 4 or 3.1?
you should drop those methods from 4.0 code if you want to deprecate. Since this is a contrib you don't necessarily need to deprecate so you could alo drop them from 3.1 or even from 3.0.x

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Robert Muir (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12982397#action_12982397 ] 

Robert Muir commented on LUCENE-2867:
-------------------------------------

Hi Adriano, the 3.x is the dev branch for minor release like 3.1, 3.2, ...

3.0.x and 2.9.x are bug fix release branches, but in my opinion some of the
issues surrounding using CharSequence in a HashSet/Map could be considered bugs.


> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Adriano Crestani (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12982407#action_12982407 ] 

Adriano Crestani commented on LUCENE-2867:
------------------------------------------

Hi Robert,

bq. 3.0.x and 2.9.x are bug fix release branches, but in my opinion some of the
issues surrounding using CharSequence in a HashSet/Map could be considered bugs.

API changes are not required to fix the CharSequence bug, so I'm not sure if I should be adding and deprecating API methods on 2.9.x and 3.0.x.

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] Commented: (LUCENE-2867) Change contrib QP API that uses CharSequence as string identifier

Posted by "Simon Willnauer (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-2867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12982237#action_12982237 ] 

Simon Willnauer commented on LUCENE-2867:
-----------------------------------------

bq. Thanks for reviewing the patch Simon!

you are welcome... I saw your commit and I wonder why you committed into branches/branch_3x but not in trunk first and then backport? Usually we put changes into trunk first and then move them to the branches though. Now this issues has been closed / resolved and it has not been committed to trunk and neither to 3.0.4 as stated in the FixVersion? Now I am confused...

So 4.0 changes go into trunk:
http://svn.apache.org/repos/asf/lucene/dev/trunk/

Changes for 3.x go here
http://svn.apache.org/repos/asf/lucene/dev/branches/branch_3x/

And eventually you deprecations can go here to be in 3.0.4 if that gets released at all...
http://svn.apache.org/repos/asf/lucene/java/branches/lucene_3_0/

and / or here:

http://svn.apache.org/repos/asf/lucene/java/branches/lucene_2_9/

does that make sense?

> Change contrib QP API that uses CharSequence as string identifier
> -----------------------------------------------------------------
>
>                 Key: LUCENE-2867
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2867
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: contrib/*
>    Affects Versions: 3.0.3
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.0.4
>
>         Attachments: lucene_2867_adriano_crestani_2011_01_13.patch
>
>
> There are some API methods on contrib queryparser that expects CharSequence as identifier. This is wrong, since it may lead to incorrect or mislead behavior, as shown on LUCENE-2855. To avoid this problem, these APIs will be changed and enforce the use of String instead of CharSequence on version 4. This patch already deprecate the old API methods and add new substitute methods that uses only String.

-- 
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org