thanks for the answer!
i will try that...would it be also a good approach to implement one filter for all whitelist handling (email, fax, sms)? then reading the whitelists there and setting the new messageheaders?
something like that?
@
PHP Code:
Named("outgoingMessageFilter")
public class OutgoingMessageFilter implements MessageSelector {
/**
* Implement a whitelist handling for all outgoing messages!
*
* @see org.springframework.integration.core.MessageSelector#accept(org.springframework.integration.Message)
*/
@Override
public boolean accept(Message<?> message) {
MessageHeaders headers = message.getHeaders();
List<String> emailSubscribers = headers.get(CustomHeaders.EMAIL_SUBSCRIBERS, List.class);
//handle and set new emails subscribers
List<String> faxSubscribers = headers.get(CustomHeaders.FAX_SUBSCRIBERS, List.class);
//handle and set new fax subscribers
List<String> iphonePushSubscribers = headers.get(CustomHeaders.IPHONEPUSH_SUBSCRIBERS, List.class);
//handle and set new iphone push subscribers
return false;
}
}
regards
angela