-
Notifications
You must be signed in to change notification settings - Fork 6k
Add breaking change documentation for BufferedStream.WriteByte implicit flush removal in .NET 10 #49123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…it flush removal Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR documents a breaking change in .NET 10 Preview 4 where BufferedStream.WriteByte
no longer performs an implicit flush when the internal buffer is full, aligning its behavior with other Write
methods in the BufferedStream
class.
Key changes:
- Added comprehensive breaking change documentation explaining the behavioral change and migration guidance
- Created compilable code snippets in both C# and Visual Basic demonstrating the previous behavior and migration path
- Updated the table of contents and index to include the new breaking change entry
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
File | Description |
---|---|
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md | Main documentation file describing the breaking change, previous/new behavior, and migration guidance |
docs/core/compatibility/core-libraries/10.0/snippets/bufferedstream-writebyte-flush/csharp/Program.cs | C# code examples demonstrating the behavioral change and recommended migration |
docs/core/compatibility/core-libraries/10.0/snippets/bufferedstream-writebyte-flush/csharp/BufferedStreamWriteByteFlush.csproj | Project file for C# code snippets |
docs/core/compatibility/core-libraries/10.0/snippets/bufferedstream-writebyte-flush/vb/Program.vb | Visual Basic code examples demonstrating the behavioral change and recommended migration |
docs/core/compatibility/core-libraries/10.0/snippets/bufferedstream-writebyte-flush/vb/BufferedStreamWriteByteFlush.vbproj | Project file for Visual Basic code snippets |
docs/core/compatibility/toc.yml | Added TOC entry for the breaking change under Core .NET libraries |
docs/core/compatibility/10.0.md | Added index table entry for the breaking change |
Summary
This PR adds documentation for a breaking change in .NET 10 Preview 4 where
BufferedStream.WriteByte
no longer performs an implicit flush when the internal buffer is full.Changes
New documentation file:
docs/core/compatibility/core-libraries/10.0/bufferedstream-writebyte-flush.md
WriteByte
would automatically flush the bufferWrite
methodsCode snippets: Created compilable C# and Visual Basic examples demonstrating:
snippets/bufferedstream-writebyte-flush/csharp/
andsnippets/bufferedstream-writebyte-flush/vb/
TOC and index updates:
toc.yml
under Core .NET libraries (alphabetically ordered)10.0.md
index with the breaking change entryContext
This change aligns
BufferedStream.WriteByte
behavior with otherWrite
methods in theBufferedStream
class (Write
andWriteAsync
), which don't perform implicit flushes. The inconsistency could lead to unexpected performance issues or unintended side effects when working with streams sensitive to flush operations.Fixes #496356
References
Original prompt
Fixes #48913
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.
Internal previews