You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "iverase (via GitHub)" <gi...@apache.org> on 2023/09/26 14:05:23 UTC
[GitHub] [lucene] iverase opened a new pull request, #12594: Add length method to RandomAccessInput
iverase opened a new pull request, #12594:
URL: https://github.com/apache/lucene/pull/12594
Implementation is straight forward as we always have the length of the data when constructing a RandomAccessInput. The only odd thing is that `ByteBuffersDataInput` already has a method called `size()` so I deprecated it in favour of this new one.
closes https://github.com/apache/lucene/issues/12592
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org
[GitHub] [lucene] iverase commented on pull request #12594: Add length method to RandomAccessInput
Posted by "iverase (via GitHub)" <gi...@apache.org>.
iverase commented on PR #12594:
URL: https://github.com/apache/lucene/pull/12594#issuecomment-1736205488
Thanks @jpountz! What it is not clear to me is if adding a method to this interface is considered a breaking change and it can only be introduced in a major release, or if it can be backported to the 9.x line. Any suggestions?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org
[GitHub] [lucene] iverase commented on pull request #12594: Add length method to RandomAccessInput
Posted by "iverase (via GitHub)" <gi...@apache.org>.
iverase commented on PR #12594:
URL: https://github.com/apache/lucene/pull/12594#issuecomment-1736975225
> One suggestion: given that ByteBuffersDataInput already has a size method, why not name the new interface method size as well? The two terms are more or less interchangeable, and that way you don't need to do all the deprecations.
Because IndexInput already defines a method called `length`, so adding a `size` method means that all the IndexInput that implements RandomAccessInput (which there are a few) will have a size and a length method which looks less ideal. But if folks thinks otherwise I don't feel strongly about it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org
[GitHub] [lucene] romseygeek commented on pull request #12594: Add length method to RandomAccessInput
Posted by "romseygeek (via GitHub)" <gi...@apache.org>.
romseygeek commented on PR #12594:
URL: https://github.com/apache/lucene/pull/12594#issuecomment-1736976414
> Because IndexInput already defines a method called length, so adding a size method means that all the IndexInput that implements RandomAccessInput (which there are a few) will have a size and a length method which looks less ideal
Ah right, no your way makes more sense then.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org
[GitHub] [lucene] romseygeek commented on pull request #12594: Add length method to RandomAccessInput
Posted by "romseygeek (via GitHub)" <gi...@apache.org>.
romseygeek commented on PR #12594:
URL: https://github.com/apache/lucene/pull/12594#issuecomment-1736960788
I think it's fine to add simple methods to interfaces like this in point releases. Extending RandomAccessInput would be a pretty expert use of lucene.
One suggestion: given that `ByteBuffersDataInput` already has a `size` method, why not name the new interface method `size` as well? The two terms are more or less interchangeable, and that way you don't need to do all the deprecations.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org
[GitHub] [lucene] iverase merged pull request #12594: Add length method to RandomAccessInput
Posted by "iverase (via GitHub)" <gi...@apache.org>.
iverase merged PR #12594:
URL: https://github.com/apache/lucene/pull/12594
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org