Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8174864

SerializedLambda does not preserve markers & bridges

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 8u101, 9
    • core-libs
    • None

      SerializedLambda has fields storing most of the arguments to LambdaMetafactory (sometimes after mapping to a serialization-friendly form). But it does not have fields to store extra interfaces or extra method descriptors, as supported by 'altMetafactory'. As a result, serialization must be a lossy transformation, mapping many function objects to the same serialized form.

      Thus, while LambdaMetafactory promises to support serialization of any legal invocation that uses FLAG_SERIALIZABLE, in practice only the first invocation of a unique serialization key (key=the first 6 arguments) will serialize/deserialize correctly.

            dlsmith Dan Smith
            dlsmith Dan Smith
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: