Skip to content

Commit

Permalink
MID-7484: prepareAndSendMessage still respects provided transport name
Browse files Browse the repository at this point in the history
In the future transport.getName() will be enough, but not yet with
legacy transport names using key:whatever convention.
  • Loading branch information
virgo47 committed Feb 23, 2022
1 parent f526d24 commit fbc2d07
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ private int prepareAndSendMessages(E event, N notifierConfig, VariablesMap varia
int sentMessages = 0;
for (RecipientExpressionResultType recipient : recipients) {
sentMessages += prepareAndSendMessage(event,
notifierConfig, variables, transport, recipient, task, result);
notifierConfig, variables, transport, transportName, recipient, task, result);
}
return sentMessages;
} catch (Throwable t) {
Expand All @@ -155,9 +155,12 @@ private int prepareAndSendMessages(E event, N notifierConfig, VariablesMap varia
}

private int prepareAndSendMessage(E event, N notifierConfig, VariablesMap variables,
Transport<?> transport, RecipientExpressionResultType recipient, Task task, OperationResult result)
Transport<?> transport, @Deprecated String transportName,
RecipientExpressionResultType recipient, Task task, OperationResult result)
throws SchemaException {
String transportName = transport.getName();
// TODO this is what we want in 4.6, parameter must go
// But this will also mean rewriting existing tests from legacy to new transport style.
// String transportName = transport.getName();

String address = recipient.getAddress();
if (address == null) {
Expand Down

0 comments on commit fbc2d07

Please sign in to comment.