You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello! Recently I encountered a problem with defining mapping for large legacy classes with many nested fields.
Class MapperGenerator in method private Set<FieldMap> addMapMethod(SourceCodeContext code, boolean aToB, ClassMap<?, ?> classMap, StringBuilder logDetails) combines all class map field mappings into one method. So when there are many field mappings and fields have long names there might occur an "Method code too large exception" during initializing generated mapping classes at runtime. The standard limit in JDK for method length is 64k.
I looked up one of the generated mapping class in my code and it's method has almost 7k lines :).
Is there any workaround for this problem?
The text was updated successfully, but these errors were encountered:
Hello! Recently I encountered a problem with defining mapping for large legacy classes with many nested fields.
Class
MapperGenerator
in methodprivate Set<FieldMap> addMapMethod(SourceCodeContext code, boolean aToB, ClassMap<?, ?> classMap, StringBuilder logDetails)
combines all class map field mappings into one method. So when there are many field mappings and fields have long names there might occur an "Method code too large exception" during initializing generated mapping classes at runtime. The standard limit in JDK for method length is 64k.I looked up one of the generated mapping class in my code and it's method has almost 7k lines :).
Is there any workaround for this problem?
The text was updated successfully, but these errors were encountered: