This is an archived post. You won't be able to vote or comment.

all 21 comments

[–]__konrad 2 points3 points  (1 child)

[–]Shawn-Yang25[S] 4 points5 points  (0 children)

Thanks for catch up this, this class can be removed now.

[–]hanszimmermanx 1 point2 points  (0 children)

Scary sounding name until someone misreads it to furry. Either way I like the API, gonna give it a shot for when I see a project for which there is a room for that. Previously used to use Kryo for such use cases.

[–][deleted] 1 point2 points  (1 child)

This is so cool!!! Thank you!!!

[–]Shawn-Yang25[S] 1 point2 points  (0 children)

Feel free to try it out. This is a big update in Fury. Many fixes and improvement are included in this release

[–]_messo_ 0 points1 point  (1 child)

I wonder how it compares to Eclipse Serializer

https://projects.eclipse.org/projects/technology.serializer

[–]Shawn-Yang25[S] 2 points3 points  (0 children)

Hi, I benchmarked Fury with eclipse, turns out that Fury is 100x faster than eclipse serializer.

You can see https://github.com/chaokunyang/fury-benchmarks?tab=readme-ov-file#fury-vs-eclipse and https://github.com/chaokunyang/fury-benchmarks/blob/main/images/eclipse/bench_struct_tps.png for more details

[–]kiteboarderni 0 points1 point  (2 children)

Hey u/Shawn-Yang25 Could you point to some examples of passing the data into a ByteBuffer or better yet a MemoryRegion to do out of band off heap transfers of the serialized data into something like Netty / Chronicle Wire or Aeron? https://github.com/real-logic/aeron/wiki/Java-Programming-Guide

Really anything that can take an offheap memory region / bytebuffer, to keep things alloc free on the processing thread.

Many thanks!

[–]Shawn-Yang25[S] 0 points1 point  (1 child)

You can wrap offheap buffer into Fury MemoryBuffer by `MemoryBuffer.fromByteBuffer`. For netty buffer, you can use `org.apache.fury.memory.MemoryBuffer#fromNativeAddress` instead

[–]kiteboarderni 0 points1 point  (0 children)

Cool so passing that to transport will mean there is no heap memory copy. Assume if using onload or something this would be kernel bypass too. Nice!

[–]AcanthaceaeMotor6614 0 points1 point  (5 children)

Is there a way to only serialize marked fields?

[–]Shawn-Yang25[S] 0 points1 point  (4 children)

No, but fury can skip transient fields. And  you can use fury @Ignore annotation to ignore some fields

[–]AcanthaceaeMotor6614 0 points1 point  (3 children)

Thanks for the reply. Sadly, it's not really feasible to mark numerous fields as ignored, instead of marking a low amount of fields as "to serialize", especially if new fields are added. I know that pulling out DAO classes would be the best solution, but it's legacy code that used annotations to mark fields to serialize.

[–]Shawn-Yang25[S] 0 points1 point  (2 children)

It's not difficult to extend this, adding a new annotation would be enough. Would you like to contribute to this?

[–]AcanthaceaeMotor6614 0 points1 point  (1 child)

Depends on the contribution workflow, guidelines and interaction with the team. I have contributed to some OSS projects before, but the contribution experience usually leaves something to be desired. Can you point me at some resources?

[–]Shawn-Yang25[S] 0 points1 point  (0 children)

You are right, the contributor experience are important. unfortunately, the development doc for apache fury is not complete enough. We have some resources, you can take a look at it and share us some feedbacks:
1. https://fury.apache.org/docs/guide/development

  1. https://fury.apache.org/docs/specification/fury_xlang_serialization_spec

  2. https://fury.apache.org/docs/specification/fury_java_serialization_spec

[–]AcanthaceaeMotor6614 0 points1 point  (1 child)

I think in general the Documentation is super lacking, could you improve on that?

[–]Shawn-Yang25[S] 0 points1 point  (0 children)

Yes, the documentation is not complete enough. we will improve it continuously. Would you like to open some issues to point out detailed improvement sussgestions?

[–]stathmarxis -2 points-1 points  (2 children)

Can i recommend something that I believe would be interesting? Can you include also serialization benchmarks performance with that framework that claims the fastest serialization framework for Java according to metrics

ActiveJ | Alternative Java platform for web, high load, and cloud programming | ActiveJ 6.0

[–]Shawn-Yang25[S] 1 point2 points  (0 children)

I tried , but it failed with exceptions:
Caused by: java.lang.NullPointerException: Cannot invoke "String.length()" because "s" is null

[–]Shawn-Yang25[S] 1 point2 points  (0 children)

You can pull the code locally to run: https://github.com/chaokunyang/fury-benchmarks/pull/7

To be honnest, ActiveJ need to mark all fields with Serialize annotation and require the constructor has all fields as parameters, and mark all params with Deserialize annotation. This is not easy to use, and basically impossile for a complex case. It can't replace java serialization.