You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by "NightOwl888 (via GitHub)" <gi...@apache.org> on 2024/10/22 14:51:11 UTC
[I] Task: Fix serialization tests and deprecate (rather than exclude) serialization support to match the BCL [lucenenet]
NightOwl888 opened a new issue, #983:
URL: https://github.com/apache/lucenenet/issues/983
### Is there an existing issue for this?
- [X] I have searched the existing issues
### Task description
.NET 8.0 broke running binary serialization in tests. So, when we added tests for .NET 8.0, we originally compiled out the APIs and tests for serializing and de-serializing.
In J2N and ICU4N (in particular the former) the problem of getting the serialization tests to run was addressed by [putting a task in the `tests/Directory.Build.targets` file]() to update the `.runtime.config` file for the test project. Then we did a similar deprecation of the *serialization APIs only*, while leaving the deserialization APIs non-deprecated, which was how it was done in the BCL.
However, unlike the BCL, we ended up doing this for all target frameworks to ensure users are aware that using binary serialization (even on older target frameworks) is highly discouraged in the modern era. This is primarily to prevent .NET Framework users from considering it for new applications before they migrate to .NET Core. In addition to adding the `[Obsolete]` attribute, the `[EditorBrowsable(EditorBrowsableState.Never)]` attribute was added to prevent users from seeing these APIs in the IDE.
So, we should do a similar deprecation here, rather than forcing users who may be using serialization to either stay on `net6.0` or rip out their serialization code so they can migrate their app to `net8.0`. They will still get a warning, but it is no longer a blocker. This of only applies to classes that have de-serialization constructors or implement `ISerializable` or `IDeserializationCallback`.
--
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.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Task: Fix serialization tests and deprecate (rather than exclude) serialization support to match the BCL [lucenenet]
Posted by "paulirwin (via GitHub)" <gi...@apache.org>.
paulirwin closed issue #983: Task: Fix serialization tests and deprecate (rather than exclude) serialization support to match the BCL
URL: https://github.com/apache/lucenenet/issues/983
--
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
Re: [I] Task: Fix serialization tests and deprecate (rather than exclude) serialization support to match the BCL [lucenenet]
Posted by "paulirwin (via GitHub)" <gi...@apache.org>.
paulirwin closed issue #983: Task: Fix serialization tests and deprecate (rather than exclude) serialization support to match the BCL
URL: https://github.com/apache/lucenenet/issues/983
--
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