Skip to content

Commit

Permalink
update fury to 0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
wenshao committed May 11, 2024
1 parent ec566bd commit fd68be8
Show file tree
Hide file tree
Showing 15 changed files with 36 additions and 36 deletions.
4 changes: 2 additions & 2 deletions benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@
<artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>org.furyio</groupId>
<groupId>org.apache.fury</groupId>
<artifactId>fury-core</artifactId>
<version>0.4.1</version>
<version>0.5.0</version>
</dependency>
<dependency>
<groupId>org.msgpack</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
import com.alibaba.fastjson2.benchmark.along.vo.HarmDTO;
import com.alibaba.fastjson2.benchmark.along.vo.SkillCategory;
import com.alibaba.fastjson2.benchmark.along.vo.SkillFire_S2C_Msg;
import io.fury.Fury;
import io.fury.config.Language;
import org.apache.commons.io.IOUtils;
import org.apache.fury.Fury;
import org.apache.fury.config.Language;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.infra.Blackhole;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
import com.alibaba.fastjson2.JSONReader;
import com.alibaba.fastjson2.JSONWriter;
import com.alibaba.fastjson2.benchmark.along.vo.SkillFire_S2C_Msg;
import io.fury.Fury;
import io.fury.config.Language;
import org.apache.commons.io.IOUtils;
import org.apache.fury.Fury;
import org.apache.fury.config.Language;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.infra.Blackhole;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ public class EishayFuryCompatibleParse {
static byte[] jsonbBytes;
static byte[] furyCompatibleBytes;

static io.fury.ThreadSafeFury furyCompatible = io.fury.Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
static org.apache.fury.ThreadSafeFury furyCompatible = org.apache.fury.Fury.builder()
.withLanguage(org.apache.fury.config.Language.JAVA)
.withRefTracking(true)
.requireClassRegistration(false)
.withCompatibleMode(io.fury.config.CompatibleMode.COMPATIBLE)
.withCompatibleMode(org.apache.fury.config.CompatibleMode.COMPATIBLE)
.buildThreadSafeFury();

static {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

import com.alibaba.fastjson2.*;
import com.alibaba.fastjson2.benchmark.eishay.vo.MediaContent;
import io.fury.Fury;
import io.fury.ThreadSafeFury;
import org.apache.commons.io.IOUtils;
import org.apache.fury.Fury;
import org.apache.fury.ThreadSafeFury;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.infra.Blackhole;
Expand Down Expand Up @@ -33,10 +33,10 @@ public class EishayFuryCompatibleWrite {
);

static ThreadSafeFury furyCompatible = Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
.withLanguage(org.apache.fury.config.Language.JAVA)
.withRefTracking(true)
.requireClassRegistration(false)
.withCompatibleMode(io.fury.config.CompatibleMode.COMPATIBLE)
.withCompatibleMode(org.apache.fury.config.CompatibleMode.COMPATIBLE)
.buildThreadSafeFury();

static {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ public class EishayFuryParse {
static byte[] jsonbBytes;
static byte[] furyBytes;

static io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
static org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
.withLanguage(org.apache.fury.config.Language.JAVA)
.requireClassRegistration(false)
.withRefTracking(true)
.buildThreadSafeFury();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ public class EishayFuryParseNoneCache {
static byte[][] furyBytes = new byte[COUNT][];
static int index;

static io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
static org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
.withLanguage(org.apache.fury.config.Language.JAVA)
.withRefTracking(true)
.withClassLoader(classLoader)
.buildThreadSafeFury();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
public class EishayFuryWrite {
static MediaContent object;

static io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
static org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
.withLanguage(org.apache.fury.config.Language.JAVA)
.requireClassRegistration(false)
.withRefTracking(true)
.buildThreadSafeFury();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ public class EishayFuryWriteNoneCache {
static final Object[] objects = new Object[classes.length];
static int index;

static io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
.withLanguage(io.fury.config.Language.JAVA)
static org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
.withLanguage(org.apache.fury.config.Language.JAVA)
.withRefTracking(true)
.buildThreadSafeFury();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
import com.esotericsoftware.kryo.Kryo;
import com.esotericsoftware.kryo.io.Input;
import com.esotericsoftware.kryo.io.Output;
import io.fury.Fury;
import io.fury.config.Language;
import org.apache.commons.io.IOUtils;
import org.apache.fury.Fury;
import org.apache.fury.config.Language;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.infra.Blackhole;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
import com.alibaba.fastjson2.benchmark.protobuf.MediaContentTransform;
import com.esotericsoftware.kryo.Kryo;
import com.esotericsoftware.kryo.io.Output;
import io.fury.Fury;
import io.fury.config.Language;
import org.apache.commons.io.IOUtils;
import org.apache.fury.Fury;
import org.apache.fury.config.Language;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.infra.Blackhole;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,8 @@ public LinkedHashMap<String, byte[]> genCodes(int count) throws Exception {
}

public byte[][] genFuryBytes(int count) throws Exception {
// io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
// .withLanguage(io.fury.Language.JAVA)
// org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
// .withLanguage(org.apache.fury.Language.JAVA)
// .withReferenceTracking(true)
// .disableSecureMode()
// .buildThreadSafeFury();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ public class BigDecimal20 {

static byte[] hessianBytes;

// static io.fury.ThreadSafeFury furyCompatible = io.fury.Fury.builder()
// .withLanguage(io.fury.Language.JAVA)
// static org.apache.fury.ThreadSafeFury furyCompatible = org.apache.fury.Fury.builder()
// .withLanguage(org.apache.fury.Language.JAVA)
// .withReferenceTracking(true)
// .disableSecureMode()
// .withCompatibleMode(io.fury.serializers.CompatibleMode.COMPATIBLE)
// .withCompatibleMode(org.apache.fury.serializers.CompatibleMode.COMPATIBLE)
// .buildThreadSafeFury();
// static byte[] furyCompatibleBytes;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ public class KryoTest {
Kryo kryo = new Kryo();
Output output = new Output(1024, -1);
//
// static io.fury.ThreadSafeFury fury = io.fury.Fury.builder()
// .withLanguage(io.fury.Language.JAVA)
// static org.apache.fury.ThreadSafeFury fury = org.apache.fury.Fury.builder()
// .withLanguage(org.apache.fury.Language.JAVA)
// .withReferenceTracking(true)
// .disableSecureMode()
// .withCompatibleMode(io.fury.serializers.CompatibleMode.COMPATIBLE)
// .withCompatibleMode(org.apache.fury.serializers.CompatibleMode.COMPATIBLE)
// .buildThreadSafeFury();

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ public static void main(String[] args) throws Exception {

MediaContent mediaContent = JSON.parseObject(str, MediaContent.class);
//
// io.fury.ThreadSafeFury furyCompatible = io.fury.Fury.builder()
// .withLanguage(io.fury.Language.JAVA)
// org.apache.fury.ThreadSafeFury furyCompatible = org.apache.fury.Fury.builder()
// .withLanguage(org.apache.fury.Language.JAVA)
// .withReferenceTracking(true)
// .disableSecureMode()
// .withCompatibleMode(io.fury.serializers.CompatibleMode.COMPATIBLE)
// .withCompatibleMode(org.apache.fury.serializers.CompatibleMode.COMPATIBLE)
// .buildThreadSafeFury();
//
// byte[] furyBytes = furyCompatible.serialize(mediaContent);
Expand Down

0 comments on commit fd68be8

Please sign in to comment.