Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-20314

Ignite Java documentation missing required --add-opens

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.15
    • 2.16
    • documentation
    • 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

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            igusev Igor Gusev
            pperalta Patrick Peralta
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment