rbeckman-nextgen / test-mc

test-migration
1 stars 0 forks source link

Batch processing doesn't correctly skip header rows for delimited data types if the record delimiter is more than one character #3737

Closed rbeckman-nextgen closed 4 years ago

rbeckman-nextgen commented 4 years ago

Tested this with a channel with Delimited Text as the inbound data type and Process Batch enabled.

Test settings: -Record Delimiter: !@# -Number of Header Records: 2 -Process Batch: Yes

Test message: {code}A!@#B!@#C!@#D!@#E!@#{code}

Result: {code} Message 1: @#C!@# Message 2: D!@# Message 3: E!@# {code}

Expected Result: {code} Message 1: C!@# Message 2: D!@# Message 3: E!@# {code}

Imported Issue. Original Details: Reporter: leilanim Created: 2015-10-12T12:06:16.000-0700

rbeckman-nextgen commented 4 years ago

Batch processing now correctly accounts for multi-character record delimiters.

Imported Comment. Original Details: Author: leilanim Created: 2015-10-12T12:50:34.000-0700

rbeckman-nextgen commented 4 years ago

Server(s) and URLs Used: Run Mirth Connect on local OSX Yosemite 10.10 Version(s)/Build(s) to reproduce failure: mirthconnect-3.3.0.7801.b1804 Version(s)/Build(s) to verify fixes: mirthconnect-3.3.1.7844.b85 How Tested (list tests run):

Run Mirth Connect

Create new Channel with default Source = Channel Reader

* Source Settings > Process Batch = Yes

* Destination Connector = Javascript Writer

{code}return logger.info("Batch processing raw data = " + connectorMessage.getRawData());{code}

* Channel Properties > Set Data Types > (see screenshot “DelimitedTextProperties”)

Set Inbound & Outbound = Delimited Text Record Delimiter = !@# *** Number of Header Records: 2

* Save and deploy channel

Send message to channel and record the result

{code}A!@#B!@#C!@#D!@#E!@#{code}

Verified Fixed: In MC330, the result is {code}INFO 2015-10-13 10:23:46,056 [pool-4-thread-4] js-connector: Batch processing raw data = @#C INFO 2015-10-13 10:23:46,107 [pool-4-thread-4] js-connector: Batch processing raw data = D INFO 2015-10-13 10:23:46,146 [pool-4-thread-4] js-connector: Batch processing raw data = E{code}

In MC331, the result is {code}INFO 2015-10-13 10:23:03,773 [pool-4-thread-2] js-connector: Batch processing raw data = C INFO 2015-10-13 10:23:03,802 [pool-4-thread-2] js-connector: Batch processing raw data = D INFO 2015-10-13 10:23:03,819 [pool-4-thread-2] js-connector: Batch processing raw data = E{code}

Additional Info: Also tested with different number of header record and different text record delimited (multiple characters)

Imported Comment. Original Details: Author: minht Created: 2015-10-13T11:38:25.000-0700

rbeckman-nextgen commented 4 years ago

Verified batch processing with header row working correctly at mirthconnect-3.3.1.7844.b85

Imported Comment. Original Details: Author: minht Created: 2015-10-13T12:49:06.000-0700