Hi Mirza,

If set failure timeout to -1, it will not retry?

Failure Timeout is -1 = retry forever (no time limit) It will keep retrying until it gets a response.

:?E=S or E=S is same? 

:?E -- it looks at the value in MSA:1 and evaluates it by HL7 acknowledgment class. Ex: 'AE' or 'CE'
It is only for HL7 messages.

E - it is a standard Error code, E only when dealing with non-HL7 or custom reply codes.

what the ( :? ) means?

“Match by class of HL7 acknowledgment code, not exact value.”
It looks at MSA:1 in the response and groups codes by meaning.

:?A - matches AA or CA values (Accept)
:?E - matches AE or CE values (Error)
:?R - matches AR or CR values (Reject)

Thanks,

Hi,

Here is the sample code

 Set DCJson= {"name":"Janko","surname":"Hrasko","colors":["blue","green","yellow"]}
  
  Set formatter=##class(%JSON.Formatter).%New()
  Set sc=formatter.FormatToString(DCJson,.tJsonStr)
  Set newMsg = ##class(Ens.StreamContainer).%New()
  Set newMsg.Stream = ##class(%Stream.GlobalCharacter).%New()
  do newMsg.Stream.Write(tJsonStr)
  newMsg.Stream.Read()
 

Output:

{
  "name":"Janko",
  "surname":"Hrasko",
  "colors":[
    "blue",
    "green",
    "yellow"
  ]
}

Thanks,

Hi,

The HeaderId and Target are required parameters for tihs method.

ClassMethod ResendDuplicatedMessage(pOriginalHeaderId As %String, Output pNewHeaderId As %String, pNewTarget As %String, pNewBody As %RegisteredObject, pNewSource As %String, pHeadOfQueue As %Boolean) As %Status
 

Can try like  Set tSC = ##class(Ens.MessageHeader).ResendDuplicatedMessage(context.tId,,context.pNewTarget)

Thanks,