Skip to content

feat: Add Protobuf protocol support for structured binary file parsing#14

Merged
TinyZzh merged 1 commit intomasterfrom
dev-ai
Feb 15, 2026
Merged

feat: Add Protobuf protocol support for structured binary file parsing#14
TinyZzh merged 1 commit intomasterfrom
dev-ai

Conversation

@TinyZzh
Copy link
Owner

@TinyZzh TinyZzh commented Feb 15, 2026

  • Implement ProtobufStructHandler for parsing .protobuf files
  • Add protobuf dependency (com.google.protobuf:protobuf-java:4.29.2)
  • Register handler in SPI configuration
  • Add FILE_PROTOBUF extension constant to FileExtensionMatcher
  • Update module-info.java with protobuf module requirement
  • Generate PersonProto test class for descriptor testing
  • Add comprehensive test suite with 33 test cases
  • Achieve 100% instruction and branch coverage

Features:

  • Support for startOrder and endOrder configuration
  • Dynamic message parsing using protobuf descriptors
  • Handle empty messages and parse errors gracefully
  • Convert protobuf messages to StructImpl with proper field mapping
  • Support for repeated fields (comma-separated values)

- Implement ProtobufStructHandler for parsing .protobuf files
- Add protobuf dependency (com.google.protobuf:protobuf-java:4.29.2)
- Register handler in SPI configuration
- Add FILE_PROTOBUF extension constant to FileExtensionMatcher
- Update module-info.java with protobuf module requirement
- Generate PersonProto test class for descriptor testing
- Add comprehensive test suite with 33 test cases
- Achieve 100% instruction and branch coverage

Features:
- Support for startOrder and endOrder configuration
- Dynamic message parsing using protobuf descriptors
- Handle empty messages and parse errors gracefully
- Convert protobuf messages to StructImpl with proper field mapping
- Support for repeated fields (comma-separated values)
@codecov
Copy link

codecov bot commented Feb 15, 2026

Codecov Report

❌ Patch coverage is 95.55556% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.35%. Comparing base (a42aa92) to head (7b9e90c).
⚠️ Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
...org/struct/core/handler/ProtobufStructHandler.java 95.55% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master      #14      +/-   ##
============================================
+ Coverage     84.83%   85.35%   +0.52%     
- Complexity      782      809      +27     
============================================
  Files            65       66       +1     
  Lines          2327     2417      +90     
  Branches        394      412      +18     
============================================
+ Hits           1974     2063      +89     
- Misses          181      185       +4     
+ Partials        172      169       -3     
Flag Coverage Δ
unittests 85.35% <95.55%> (+0.52%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TinyZzh TinyZzh merged commit dcc2145 into master Feb 15, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant