The "Response Received" tab can, for example, be populated when a Web Service destination node sets an ACK message. This same functionality and behavior is available via scripting, as follows:
message.setAckMessage('some ACK message');
There is an undocumented code wizard function that returns the message's ACK message or null, if there is no ACK message (NOTE: this method will be documented beginning with QIE version 24.2.1):
message.getAckMessage();
When a destination node sets an ACK message and there already is a previously-set ACK message, a warning is logged to the channel's status log stating something like:
Discarded prior ACK: some previous ACK message
This same functionality can be achieved using these two ACK message functions inside a custom script, for example:
var priorAckMessageOrNull = message.getAckMessage();
if (priorAckMessageOrNull != null) {
qie.warn(
'Discarded prior ACK:\n\n' +
new java.lang.String(priorAckMessageOrNull)
);
}
message.setAckMessage('new ACK message');
NOTE: the setter takes either a String or a byte array. The getter returns only a byte array. As seen in the preceding example, a quick way to turn that byte array into a string is to create a new java.lang.String instance by passing in the return value of message.getAckMessage()
.