Я использую реализацию 'com.fasterxml.jackson.core:jackson-databind:2.9.8'
, и когда я включаю minify, я получаю эти ошибки
2019-06-27 20:23:11.172 28675-29539/? W/System.err: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: No serializer found for class com.example.tst.a.b.b and no properties discovered to create BeanSerializer (to avoid exception, disable SerializationFeature.FAIL_ON_EMPTY_BEANS)
2019-06-27 20:23:11.172 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.SerializerProvider.reportBadDefinition(SerializerProvider.java:1191)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.DatabindContext.reportBadDefinition(DatabindContext.java:313)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ser.impl.UnknownSerializer.failForEmpty(UnknownSerializer.java:71)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ser.impl.UnknownSerializer.serialize(UnknownSerializer.java:33)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ser.DefaultSerializerProvider._serialize(DefaultSerializerProvider.java:480)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ser.DefaultSerializerProvider.serializeValue(DefaultSerializerProvider.java:319)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ObjectMapper._configAndWriteValue(ObjectMapper.java:3905)
2019-06-27 20:23:11.173 28675-29539/? W/System.err: at com.fasterxml.jackson.databind.ObjectMapper.writeValueAsString(ObjectMapper.java:3219)
это то, что я добавляю правила ProGuard, но это не решает мою проблему
-keepattributes *Annotation*,EnclosingMethod,Signature
-keep class com.fasterxml.** { *; }
-keepclassmembers class ** extends com.fasterxml.jackson.databind.ser.std.** {
public <init>(...);
}
-keepclassmembers class ** extends com.fasterxml.jackson.databind.deser.std.** {
public <init>(...);
}
-keepattributes *Annotation*,EnclosingMethod,Signature
-keepnames class com.fasterxml.jackson.** { *; }
-dontwarn com.fasterxml.jackson.databind.**
-keep class org.codehaus.** { *; }
-keepclassmembers public final enum org.codehaus.jackson.annotate.JsonAutoDetect$Visibility {
public static final org.codehaus.jackson.annotate.JsonAutoDetect$Visibility *; }
-keep public class your.class.** {
*;
}
-dontwarn com.fasterxml.jackson.databind.