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
I have a very straightforward object I would like to get the size of.
Please note, the object in question is a java record, which is something new from new java version.
public record MyPojo(@JsonProperty(value = "@timestamp") String timestamp
reproducible 100%, i am getting this error:
java.lang.UnsupportedOperationException: can't get field offset on a record class: private final java.lang.String com.MyPojo.timestamp
Caused by: java.lang.UnsupportedOperationException: can't get field offset on a record class: private final java.lang.String com.MyPojo.timestamp
at jdk.unsupported/sun.misc.Unsafe.objectFieldOffset(Unsafe.java:655)
at org.ehcache.sizeof.impl.UnsafeSizeOf.sizeOf(UnsafeSizeOf.java:120)
at org.ehcache.sizeof.SizeOf$CachingSizeOfVisitor.visit(SizeOf.java:127)
at org.ehcache.sizeof.ObjectGraphWalker.walk(ObjectGraphWalker.java:168)
at org.ehcache.sizeof.SizeOf.deepSizeOf(SizeOf.java:74)
Could you please help support record?
Thank you
The text was updated successfully, but these errors were encountered:
Hello team,
I am using this dependency:
I am also using java 21.
I have a very straightforward object I would like to get the size of.
Please note, the object in question is a java record, which is something new from new java version.
reproducible 100%, i am getting this error:
Could you please help support record?
Thank you
The text was updated successfully, but these errors were encountered: