-
Notifications
You must be signed in to change notification settings - Fork 655
Description
Is your feature request related to a problem? Please describe.
I have a use case where one of our services need to propagate PossDupFlag and OrigSendingTime to a third party. Using Session.send makes this impossible as these fields are removed from the message header.
Describe the solution you'd like
It will be great to have an overloaded method that will allow sending the message as-is without removing any field. Something like:
public boolean send(Message message, boolean sendRaw);
Describe alternatives you've considered
Alternatively, sendRaw method can be made public in Session. At the moment I have to use reflection to invoke sendRaw which is pretty hacky:
Method method = targetSession.getClass().getDeclaredMethod("sendRaw", Message.class, int.class);
method.setAccessible(true);
if (!(boolean) method.invoke(targetSession, message, 0)) {
Or fork the project and maintain a patch version in our dependency management server.
Metadata
Metadata
Assignees
Labels
No labels