chaokunyang opened a new issue, #2287:
URL: https://github.com/apache/fury/issues/2287
### Feature Request
### Feature Request
Currently all xlang serialization don't support codegen:
```java
@Data
public static class Foo {
public Integer f1;
public String f2;
public List<String> f3;
public Map<String, Integer> f4;
public Bar f5;
}
@Data
public static class Bar {
public Integer f1;
public String f2;
}
@Test
public void testMetaSharedBasic() {
Fory fory =
Fory.builder()
.withLanguage(Language.XLANG)
.withCodegen(false)
.withCompatibleMode(CompatibleMode.COMPATIBLE)
.build();
fory.register(Foo.class, "example.foo");
fory.register(Bar.class, "example.bar");
serDeCheck(fory, Bar.create());
serDeCheck(fory, Foo.create());
}
```
we should support it for better performance:
```java
@Test
public void testMetaSharedBasic() {
Fory fory =
Fory.builder()
.withLanguage(Language.XLANG)
.withCodegen(true)
.withCompatibleMode(CompatibleMode.COMPATIBLE)
.build();
fory.register(Foo.class, "example.foo");
fory.register(Bar.class, "example.bar");
serDeCheck(fory, Bar.create());
serDeCheck(fory, Foo.create());
}
```
### Is your feature request related to a problem? Please describe
_No response_
### Describe the solution you'd like
We need to change:
- BaseObjectCodecBuilder.java
- ObjectCodecBuilder.java
- MetaSharedCodecBuilder.java
### Describe alternatives you've considered
_No response_
### Additional context
_No response_
### Is your feature request related to a problem? Please describe
_No response_
### Describe the solution you'd like
_No response_
### Describe alternatives you've considered
_No response_
### Additional context
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]