Mirth Connect message replay is how failed messages get a second run, and Mirth Connect keeps no separate dead letter queue for them. Failed messages stay in the channel with a status on each connector, and reprocess is the replay path.
It is written for interface engineers and integration leads who run HL7 feeds in production. You get what each status means, how to find the failing connector, when to overwrite, and how to replay a batch without double-sending.
How does Mirth Connect message replay work without a dead letter queue?
Mirth Connect message replay works through reprocess, not a dead letter queue. Failed messages stay in the channel with a status per connector: ERROR for a failed process, QUEUED for waiting or retrying, FILTERED for a filter reject. Agnotic Technologies reads that status, fixes the cause, then reprocesses, excluding any destination that already returned an AA.
Reprocessing Connect failures?
We read ERROR, QUEUED and FILTERED, then reprocess without undoing an AA already sent.
Connect source statuses include Received, Filtered, Transformed and Error. Destination statuses include Filtered, Sent, Queued and Error. Filtered means a filter rejected the message. Queued means not yet dispatched or waiting to retry. Error means processing failed.
Reprocess always runs the Source Connector first. You may overwrite the existing message or create a new one, and you may exclude destinations. Reprocess does not un-send an ACK the destination already accepted.
- FILTERED: fix the filter or the payload. Do not blast reprocess if the filter is still wrong.
- QUEUED: wait or inspect send attempts. Do not duplicate a destination that is still retrying.
- ERROR: read the error column. Reprocess after the script or destination is fixed.
- AA already sent: do not reprocess that destination. The ACK stands.
HL7 Version 2 uses ACK messages so a receiving system can accept or reject a message. An application accept (AA) is not undone by replaying the original message later.
In practice, ERROR on a destination is where a message broker would put a dead letter. The difference is that each Mirth message keeps its connector history in the message browser, and a replay starts again at the source connector.
What are the common mistakes with Mirth Connect message replay?
The most damaging mistake is resending a destination that already recorded SENT with an application accept. Agnotic excludes that destination in the reprocess dialog on every run.
- Mistake: reprocessing a whole message when only one destination failed.
- Mistake: reprocessing before the script, filter or receiver is fixed.
- Mistake: reprocessing QUEUED messages that would have sent on their own.
- Mistake: overwriting on a clinical channel and losing the record of what failed.
- Mistake: forgetting that the source connector runs again, filters included.
How do you find which connector failed?
Open the message and read each connector row on its own. A single message has a source row and one row per destination, and each row carries its own status.
A lab result can be SENT to the EHR destination and ERROR on an archive destination at the same moment. Calling that whole message failed and reprocessing it would hand the EHR a second copy.
- Source row: whether the message was received, filtered, transformed or failed on the way in.
- Destination rows: one per destination, each with its own outcome.
- Error column: the exception or response that caused the ERROR state.
- Response: what the receiving system answered, including its ACK.
Agnotic puts the destination name in every alert, so the on-call engineer opens the right row first instead of scanning the whole message.
Which cause sits behind each status?
Each status has a few usual causes, and the fix follows the cause rather than the label. Read the error text or the filter before choosing any action.
- FILTERED on purpose: the filter dropped a message type the receiver does not want. No action.
- FILTERED by mistake: a rule became too strict after a change. Fix the rule, then reprocess only the affected range.
- ERROR in a script: a transformer threw an exception on an unexpected field. Fix the script and test it with the failed message.
- ERROR from the receiver: connection refused or a rejecting ACK. Fix the cause on that side first.
- QUEUED and growing: the receiver is down or slow. Let the queue drain once it recovers.
When the error text does not make the cause clear, export the failed message and run it through a copy of the channel in a test environment. Guessing in production adds new failures to old ones.
Which settings decide whether a failure lands in ERROR or QUEUED?
Destination queuing decides it. With queuing on, a failed send waits in QUEUED and retries; with queuing off, the same failure lands in ERROR straight away.
Neither choice is wrong, but each needs a different watch. Queued failures clear themselves when the receiver returns, so the risk is a silent backlog. Immediate errors need someone to reprocess them, so the risk is a pile nobody clears.
- Queue on: suits receivers with planned downtime, such as a nightly maintenance window.
- Queue off: suits feeds where a late message is worse than a visible failure.
- Retry interval: agree it with the receiver's owner so retries do not hammer a struggling system.
- Record the choice: per destination, so the on-call engineer knows which status to expect.
How should a rejecting ACK be handled?
A rejecting ACK means the receiver read the message and refused it, so resending the same content gets refused again. Fix the data or the mapping, then reprocess.
Agnotic configures the destination to read the ACK and mark the connector ERROR when the receiver rejects. Without that check, a reject can sit under a SENT status where nobody looks.
Keep the receiver's error text in the response column. It usually names the segment or field that failed, which turns a vague failure into a specific mapping fix.
When should reprocess overwrite, and when should it create a new message?
Create a new message when the failed attempt should stay as evidence, and overwrite only when the original has no value once fixed. The choice is made in the reprocess dialog on every run.
- New message: the failed original stays in the browser with its error, and the fixed run gets its own id.
- Overwrite: the failed processing is replaced, which keeps the browser tidy but loses the record of what failed.
- Either way: the source connector runs again, so source filters and transformers apply to the replay.
Agnotic defaults to new messages on clinical channels. Overwrite is kept for test channels and noisy feeds where the client has agreed the failed copy has no audit value.
How do you reprocess a batch without double-sending?
Select by status, destination and time range, exclude every destination that already shows SENT, and run a small sample first. Check the receiver for duplicates before the full batch.
- Step 1, fix the cause and confirm the fix with one failed message.
- Step 2, search for ERROR on the affected destination within the failure window.
- Step 3, reprocess a handful, excluding destinations already SENT.
- Step 4, confirm in the receiving system that each one arrived once.
- Step 5, run the rest of the batch and recount ERROR for that window.
Ask whether the receiver rejects duplicates by message control id. If it does not, double-sending creates duplicate results in a chart, which is worse than a short delay.
For a long window, split the batch by hour and confirm each hour before starting the next. A problem found early then touches a small slice, not the whole range.
What should happen to a QUEUED backlog when the receiver returns?
Let it drain. QUEUED messages send on their own once the receiver accepts connections again, and reprocessing them as well creates duplicates.
Watch the queue count fall and the oldest queued time move forward. If the count stops falling, read the latest queue error before touching anything.
- Order: if the receiver needs messages in sequence, keep the destination queue single-threaded.
- Age: a very old queued message, such as an outdated schedule update, may no longer be wanted. Ask the receiver before it goes.
- Volume: a large backlog can flood the receiver. Agree a pace with its owner.
Once the queue is empty, compare the receiver's message count for the outage window with Connect's SENT count for the same window.
A worked example: a lab result feed after a mapping change
A worked example: a hospital changes a lab code mapping in a transformer. Results to the EHR destination start failing with a script error, while the archive destination still records SENT.
The next working day the interface team fixes the transformer and tests it against one failed message. They then search ERROR on the EHR destination for the window since the change.
They reprocess a sample as new messages, excluding the archive destination. The EHR team confirms each result appeared once in the chart.
The rest of the batch runs, ERROR for that window returns to zero, and the failed originals stay in the browser as the record of what happened.
The team also adds a sample message carrying the new lab code to the channel's test set, so the next mapping change runs against it before deployment.
Who may reprocess, and what should be recorded?
Limit reprocessing to the people who own the interface, and record every run outside Connect as well. A replay changes what a clinical system received, so it deserves the same care as a code change.
- Who: the engineer who ran it and the person who approved it.
- What: the channel, status filter, time range and message count.
- Options: new or overwrite, and which destinations were excluded.
- Check: the receiver's confirmation that the messages arrived once.
Agnotic keeps this record in the client's change log next to the deployment that caused the failure. Reading the two together shows which kinds of change tend to cause replays.
How do you know the status counts are healthy?
Healthy channels show ERROR near zero, QUEUED that drains within the time the receiver owner expects, and FILTERED that stays steady. A sudden change in any of the three is the signal to look.
- ERROR per destination per day: alert on the first one after a deployment.
- Oldest QUEUED message: alert when it passes the agreed age.
- FILTERED share: a jump usually means a filter or an upstream format changed.
Connect alerts can notify on errors. The queue age and filtered checks usually need a scheduled query or a dashboard the interface team reviews.
How can Agnotic help with failed message replay?
Agnotic sets up status alerts per destination, ACK checks, queue settings and a written replay runbook, then runs or supervises reprocessing after incidents. Every replay is filtered by status, excludes destinations that already returned an AA, and ends with a recount.
Status first, then reprocess
FILTERED, QUEUED, ERROR. An AA already sent is not undone.
Related reading on Agnotic
HL7 reprocessing as a pattern, in-flight recovery after failover, and more HL7 reading.


