EL1008E: Property or field 'SnsBodyBuilder' cannot be found
bikerp opened this issue · 1 comments
bikerp commented
Version: 2.5.4
I'm trying to setup SNS Channel Outbound Adapter using provided example https://github.com/spring-projects/spring-integration-aws#outbound-channel-adapter-2 but I always get this error:
EL1008E: Property or field 'SnsBodyBuilder' cannot be found on object of type 'org.springframework.messaging.support.GenericMessage' - maybe not public or not valid?
Can anybody help?
artembilan commented
That is an error in the docs.
Has to be like this:
String bodyExpression = "T(SnsBodyBuilder).withDefault(payload).forProtocols(payload.substring(0, 140), 'sms')";
The withDefault()
is a static
method therefore we have to use a T
operation for its type to get access to it and call.
Will fix shortly.