-
Notifications
You must be signed in to change notification settings - Fork 6
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
fix: 27: ReadableStreamingData should implement bulk read methods #129
Conversation
Signed-off-by: Artem Ananev <artem.ananev@swirldslabs.com>
JUnit Test Report 45 files + 2 45 suites +2 3m 30s ⏱️ -36s Results for commit 8d3754f. ± Comparison against base commit 4aa8a08. This pull request removes 3 and adds 26 tests. Note that renamed tests count towards both.
♻️ This comment has been updated with latest results. |
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/ReadableStreamingData.java
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.
I believe we could simplify much of this with a slightly different approach.
Interested in your take on this.
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/ReadableStreamingData.java
Outdated
Show resolved
Hide resolved
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/ReadableStreamingData.java
Outdated
Show resolved
Hide resolved
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/ReadableStreamingData.java
Show resolved
Hide resolved
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/ReadableStreamingData.java
Outdated
Show resolved
Hide resolved
pbj-core/pbj-runtime/src/test/java/com/hedera/pbj/runtime/io/ReadableSequentialTestBase.java
Outdated
Show resolved
Hide resolved
Addressed reviewers' comments Implemented one more method in WriteableStreamingData Removed some unused imports Signed-off-by: Artem Ananev <artem.ananev@swirldslabs.com>
pbj-core/pbj-runtime/src/main/java/com/hedera/pbj/runtime/io/stream/WritableStreamingData.java
Outdated
Show resolved
Hide resolved
Fixed WriteableStreamingData.writeBytes(ByteBuffer) and added a new unit test for it Signed-off-by: Artem Ananev <artem.ananev@swirldslabs.com>
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.
Looks good.
Fix summary:
readBytes()
methods are implemented inReadableStreamingData
in a more efficient way than inherited fromReadableSequentialData
ReadableStreamingData
only now are also used for other implementations ofReadableSequentialData
(e.g.BufferedData
)Fixes: #27
Signed-off-by: Artem Ananev artem.ananev@swirldslabs.com