You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by GitBox <gi...@apache.org> on 2022/11/07 10:25:25 UTC

[GitHub] [lucenenet] NightOwl888 opened a new pull request, #749: BREAKING: Lucene.Net.Index.IndexWriter: Fixed Dispose(waitForMerges) vs Dispose(disposing)

NightOwl888 opened a new pull request, #749:
URL: https://github.com/apache/lucenenet/pull/749

   See #265.
   
   Fixed `Dispose()` overloads so there is no method signature conflict between the public `Dispose(waitForMerges)` method and the protected `Dispose(disposing)` method which is meant for end users to override. This was done by adding a `protected virtual void Dispose(bool disposing, bool waitForMerges)` overload and removing `virtual` from the public `Dispose(bool waitForMerges)` overload.
   
   This may break some existing code that either
   
   1. Subclasses `IndexWriter` and overrides the `public virtual void Dispose(bool disposing)` method. Instead, the subclass should override `protected virtual void Dispose(bool disposing, bool waitForMerges)`.
   2. Subclasses `IndexWriter` and implements a finalizer, in which case the call should now call `Dispose(disposing: false, waitForMerges: true)`. Previously, finalizers were not supported because there was no `Dispose()` overload to call to pass the `disposing` parameter.
   


-- 
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: dev-unsubscribe@lucenenet.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [lucenenet] NightOwl888 merged pull request #749: BREAKING: Lucene.Net.Index.IndexWriter: Fixed Dispose(waitForMerges) vs Dispose(disposing)

Posted by GitBox <gi...@apache.org>.
NightOwl888 merged PR #749:
URL: https://github.com/apache/lucenenet/pull/749


-- 
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: dev-unsubscribe@lucenenet.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org