Replies: 2 comments
-
The file reader has a minimum file size setting. Or read raw, check size and discard if to small. You can also serialize the raw message in try catch and discard (ie don't process it) regardless if size is bad. I'd do that in a filter or transformer. |
Beta Was this translation helpful? Give feedback.
-
If you're trying to discard the file entirely and not create a message from it, the only place to do that is during batch processing. The default hl7 batch handler might do what you want. The next place you can discard the message is the source filter. One option is to do what @pacmano1 suggested and change your inbound type to Raw, then try to manually serialize in the source filter, and filter the message if it throws an exception. The other option leaving your source connector data type as HL7 is to try to serialize in the preprocessor or attachment handler, and if it throws an exception, replace the message with a minimal known message that will properly serialize and filter based on that. The difference between doing it in the preprocessor and the attachment handler is that the preprocessor will show the raw content as blank and the processed content as the replacement message, where the attachment handler will show the raw content as the replacement message with no processed content. |
Beta Was this translation helpful? Give feedback.
-
We have a channel with a filereader source where we occasionally get empty files. These throw this error:
ER7Serializer error
ERROR MESSAGE: Error converting ER7 to XML
org.xml.sax.SAXException: Unable to parse message. It is NULL or too short.
Is there any way to stop these in the preprocessor or attachment handler?
Beta Was this translation helpful? Give feedback.
All reactions