-
Notifications
You must be signed in to change notification settings - Fork 271
test(benchmark): add msgpack serialization/deserialization to benchmark #2242
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
Conversation
ObjectType must be MEDIA_CONTENT or SAMPLE.
import org.apache.fury.benchmark.state.ObjectType; | ||
import org.apache.fury.benchmark.state.ProtoBuffersState; | ||
import org.apache.fury.benchmark.state.ProtostuffState; | ||
import org.apache.fury.benchmark.state.*; |
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.
could you use mvn spotless:apply
to format code? if it doesn't optimize imports, change it manualy
we do not use *
for import
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.
return mediaContent; | ||
} | ||
|
||
private static void packMedia(MessagePacker messagePacker, Media media) throws IOException { |
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.
Is there an automatic way to serialize it ? This is basically a manually-written serializer. We are benchmarking with the serializer you written instead of msgpack itself. We only use the msgpack protocol
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.
If there is no automatic way, maybe we could add some comments in this class and the benchmark readme
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.
The msgpack's official provides msgpack-jackson lib, but the performance is relatively poor. So, generate a basic handwritten code using qwen3(LLM). Then modify it.
1. add description of msgpack to README.md. 2. optimize imports
manually written code
ObjectType must be MEDIA_CONTENT or SAMPLE.
What does this PR do?
add msgpack serialization/deserialization to benchmark
Related issues
no
Does this PR introduce any user-facing change?
no
Benchmark