How can I report on schema violations for ADT processes or services?

We had a major problem recently where a participant was sending unexpected data. It was not enough to throw an error or warning in the actual trace, but when examining the message in the viewer it did show the following:

Build Map Status = 'ERROR <EnsEDI>ErrMapSegUnrecog: Unrecognized Segment 4:'CON' found after segment 3 (CON)'

How can I query for these or be notified of them?  This caused major ramifications but we did not notice it.  I have Managed Services investigating but I want to cover all my bases.

  • 0
  • 0
  • 219
  • 1
  • 3

Answers

Alex has suggested the best way. You can also suspend these messages so that they can be looked at and resent later. You can send an alert also from any point if you wish while processing the messages. 

 

http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

 

Lastly if you get a lot of these that need to be touched or messages in someway by a real user you could use a workflow in your production. 

 

http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

 

 

For reporting as asked in the heading we have standard mechanisms which where already mentioned.
Of course you might want to be more flexible (less standard). Then you might query the virtual documents in scripting directly and act very flexible on errors.

If there has been tried to build a map (correlation to a schema) with the VDoc method BuildMap() the virtualDocument.BuildMapStatus on that virtualDocument is available. This is how the Message Router decides on map errors.