Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.15
-
None
Description
As indicated in IGNITE-17658, --add-opens=java.base/java.lang.invoke=ALL-UNNAMED is required to serialize lambdas.
However this flag is not included in the Java 17 section of the Ignite Java Quick Start guide: https://ignite.apache.org/docs/latest/quick-start/java
Please add this so that Ignite users that require serialization of lambdas (such as scan query filters and entry processors) don't run into this problem:
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.lang.Class java.lang.invoke.SerializedLambda.capturingClass accessible: module java.base does not "opens java.lang.invoke" to unnamed module @41a4555e at java.base/java.lang.reflect.AccessibleObject.throwInaccessibleObjectException(AccessibleObject.java:387) at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:363) at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:311) at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:181) at java.base/java.lang.reflect.Field.setAccessible(Field.java:175) at org.apache.ignite.internal.binary.BinaryClassDescriptor.<init>(BinaryClassDescriptor.java:354) at org.apache.ignite.internal.binary.BinaryClassDescriptor.<init>(BinaryClassDescriptor.java:156) at org.apache.ignite.internal.binary.BinaryContext.createDescriptorForClass(BinaryContext.java:675) at org.apache.ignite.internal.binary.BinaryContext.descriptorForClass(BinaryContext.java:633) at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:182) at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:165) at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal0(BinaryWriterExImpl.java:227) at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:165) at org.apache.ignite.internal.binary.BinaryWriterExImpl.marshal(BinaryWriterExImpl.java:152) at org.apache.ignite.internal.binary.GridBinaryMarshaller.marshal(GridBinaryMarshaller.java:254) at org.apache.ignite.internal.binary.BinaryMarshaller.marshal0(BinaryMarshaller.java:84) at org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller.marshal(AbstractNodeNameAwareMarshaller.java:56) at org.apache.ignite.internal.util.IgniteUtils.marshal(IgniteUtils.java:10873) ... 22 more
Attachments
Issue Links
- links to