Class PayloadDeserializingTransformer

All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, ExpressionCapable, NamedComponent, GenericTransformer<org.springframework.messaging.Message<?>,​org.springframework.messaging.Message<?>>, Transformer

public class PayloadDeserializingTransformer
extends PayloadTypeConvertingTransformer<byte[],​java.lang.Object>
Transformer that deserializes the inbound byte array payload to an object by delegating to a Converter<byte[], Object>. Default delegate is a AllowListDeserializingConverter using Java serialization.

The byte array payload must be a result of equivalent serialization.

Since:
1.0.1
  • Constructor Details

  • Method Details

    • setDeserializer

      public void setDeserializer​(org.springframework.core.serializer.Deserializer<java.lang.Object> deserializer)
    • setAllowedPatterns

      public void setAllowedPatterns​(java.lang.String... patterns)
      When using a AllowListDeserializingConverter (the default) add patterns for packages/classes that are allowed to be deserialized. A class can be fully qualified or a wildcard '*' is allowed at the beginning or end of the class name. Examples: com.foo.*, *.MyClass.
      Parameters:
      patterns - the patterns.
      Since:
      5.4