You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Michael McCandless (JIRA)" <ji...@apache.org> on 2010/12/21 19:40:04 UTC
[jira] Created: (LUCENE-2828) SimilarityDelegator broke back-compat
for subclasses overriding lengthNorm
SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
--------------------------------------------------------------------------
Key: LUCENE-2828
URL: https://issues.apache.org/jira/browse/LUCENE-2828
Project: Lucene - Java
Issue Type: Bug
Affects Versions: 3.0.3, 3.0.2, 3.0.1, 3.0, 2.9.4, 2.9.3, 2.9.2, 2.9.1, 2.9
Reporter: Michael McCandless
In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
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-2828) SimilarityDelegator broke
back-compat for subclasses overriding lengthNorm
Posted by "Simon Willnauer (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-2828?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13149173#comment-13149173 ]
Simon Willnauer commented on LUCENE-2828:
-----------------------------------------
I think we can close this now - I don't see another 2.9 / 3.0 release happening?
> SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
> --------------------------------------------------------------------------
>
> Key: LUCENE-2828
> URL: https://issues.apache.org/jira/browse/LUCENE-2828
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 3.0, 3.0.1, 3.0.2, 3.0.3
> Reporter: Michael McCandless
> Fix For: 2.9.5, 3.0.4
>
> Attachments: LUCENE-2828.patch
>
>
> In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
> But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
> Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] Updated: (LUCENE-2828) SimilarityDelegator broke back-compat
for subclasses overriding lengthNorm
Posted by "Michael McCandless (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-2828?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael McCandless updated LUCENE-2828:
---------------------------------------
Fix Version/s: 3.0.4
2.9.5
> SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
> --------------------------------------------------------------------------
>
> Key: LUCENE-2828
> URL: https://issues.apache.org/jira/browse/LUCENE-2828
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 3.0, 3.0.1, 3.0.2, 3.0.3
> Reporter: Michael McCandless
> Fix For: 2.9.5, 3.0.4
>
> Attachments: LUCENE-2828.patch
>
>
> In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
> But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
> Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
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-2828) SimilarityDelegator broke
back-compat for subclasses overriding lengthNorm
Posted by "Michael McCandless (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-2828?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12979178#action_12979178 ]
Michael McCandless commented on LUCENE-2828:
--------------------------------------------
We won't fix this for 3.x or 4.0, since we've deprecated SimilarityDelegator, and forced hard cutover from Sim.lengthNorm -> Sim.computeNorm (LUCENE-2854).
But I'll leave this open in case we do another 2.9/3.0 release.
> SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
> --------------------------------------------------------------------------
>
> Key: LUCENE-2828
> URL: https://issues.apache.org/jira/browse/LUCENE-2828
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 3.0, 3.0.1, 3.0.2, 3.0.3
> Reporter: Michael McCandless
> Fix For: 2.9.5, 3.0.4
>
> Attachments: LUCENE-2828.patch
>
>
> In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
> But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
> Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
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-2828) SimilarityDelegator broke
back-compat for subclasses overriding lengthNorm
Posted by "Robert Muir (Resolved) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-2828?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Robert Muir resolved LUCENE-2828.
---------------------------------
Resolution: Won't Fix
Assignee: Robert Muir
> SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
> --------------------------------------------------------------------------
>
> Key: LUCENE-2828
> URL: https://issues.apache.org/jira/browse/LUCENE-2828
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 3.0, 3.0.1, 3.0.2, 3.0.3
> Reporter: Michael McCandless
> Assignee: Robert Muir
> Fix For: 2.9.5, 3.0.4
>
> Attachments: LUCENE-2828.patch
>
>
> In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
> But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
> Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] Updated: (LUCENE-2828) SimilarityDelegator broke back-compat
for subclasses overriding lengthNorm
Posted by "Michael McCandless (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-2828?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael McCandless updated LUCENE-2828:
---------------------------------------
Attachment: LUCENE-2828.patch
Patch w/ test case showing the failure.
> SimilarityDelegator broke back-compat for subclasses overriding lengthNorm
> --------------------------------------------------------------------------
>
> Key: LUCENE-2828
> URL: https://issues.apache.org/jira/browse/LUCENE-2828
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 3.0, 3.0.1, 3.0.2, 3.0.3
> Reporter: Michael McCandless
> Attachments: LUCENE-2828.patch
>
>
> In LUCENE-1420, we added Similarity.computeNorm to let the norm computation have access to the raw information (length, boost, etc.).
> But this class broke back compat with SimilarityDelegator. We did add computeNorm there, but, it's impl just forwards to the delegee's computeNorm. In the case where a subclass of SimilarityDelegator overrides lengthNorm, that method will no longer be invoked.
> Not quite sure how to fix this since, somehow, we have to determine whether the delegee's impl of computeNorm should be favored over the subclasses impl of the "legacy" lengthNorm.
--
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