Mirth

  •  
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Created 2.2.2 tag
Created 2.2.2 tag
MIRTH-2581: Fixed bug that caused JavaScriptAttachmentDialog to call setSaveEnabled(true) during editing, instead of when the OK button is pressed.
MIRTH-2581: Fixed bug that caused JavaScriptAttachmentDialog to call setSaveEnabled(true) during editing, instead of when the OK button is pressed.
MIRTH-2580: Fixed bug that caused incorrect response data to be stored when a NativeJavaObject is returned from the postprocessor. The getPostprocessorResponse method was calling result.toString() whe…
MIRTH-2580: Fixed bug that caused incorrect response data to be stored when a NativeJavaObject is returned from the postprocessor. The getPostprocessorResponse method was calling result.toString() when it should have been calling object.toString().
MIRTH-2579: Fixed bug that caused destination connectors to be incorrectly cloned when channel validation fails.
MIRTH-2579: Fixed bug that caused destination connectors to be incorrectly cloned when channel validation fails.
MIRTH-2578: Changed keepConnectionOpen and receiveTimeout in TcpReceiverProperties to stay in line with the default behaviour from 2.x.
MIRTH-2578: Changed keepConnectionOpen and receiveTimeout in TcpReceiverProperties to stay in line with the default behaviour from 2.x.
MIRTH-2577: Added validation to TcpListener to prevent max connections being set to zero.
MIRTH-2577: Added validation to TcpListener to prevent max connections being set to zero.
MIRTH-2576: Fixed alignment of MLLP Retry Count text field.
MIRTH-2576: Fixed alignment of MLLP Retry Count text field.
MIRTH-2573: Updated PollConnector termination logic so that it only attempts to interrupt the poll() thread when the channel is halted. The terminated boolean has been changed to an AtomicBoolean to a…
MIRTH-2573: Updated PollConnector termination logic so that it only attempts to interrupt the poll() thread when the channel is halted. The terminated boolean has been changed to an AtomicBoolean to account for possible get/set race conditions. Channel's halt() method has also been updated to halt each connector before submitting the HaltTask. This is because although each dispatch thread is being interrupted beforehand, it doesn't interrupt threads that haven't yet gotten to Channel.dispatchRawMessage. PollConnector.isTerminated has been made public, and the database receiver delegates have been updated to use the terminated flag to determine whether to keep retrying or not.
MIRTH-2573: Fixed bug that caused polling connectors to not get interrupted during a channel stop/halt. If the connector is stuck in the poll() method and has not yet submitted a message to dispatchRa…
MIRTH-2573: Fixed bug that caused polling connectors to not get interrupted during a channel stop/halt. If the connector is stuck in the poll() method and has not yet submitted a message to dispatchRawMessage, there previously was no way to ensure that the thread was interrupted. However now the PollConnectorTask holds a reference to the thread calling poll(), and the thread gets interrupted whenever terminate() gets called.
Added null check around all jmxConnection.close() statements in case an exception is thrown while creating the JMX connection.…
Added null check around all jmxConnection.close() statements in case an exception is thrown while creating the JMX connection.

Issue: MIRTH-2244

MIRTH-2574: Added start()/stop() methods to DatabaseReceiverDelegate, and moved the connection initialization/disposal of the query delegate to those methods. Also modified DatabaseReceiver to call de…
MIRTH-2574: Added start()/stop() methods to DatabaseReceiverDelegate, and moved the connection initialization/disposal of the query delegate to those methods. Also modified DatabaseReceiver to call delegate.start()/stop() in the appropriate places. DatabaseReceiverScript hasn't changed other then implementing the new methods as no-OPs.
MIRTH-2454, MIRTH-2455: Changed poll() methods of the query/script delegates to use an inline loop rather than recursion, and added a retry interval to the database receiver.
MIRTH-2454, MIRTH-2455: Changed poll() methods of the query/script delegates to use an inline loop rather than recursion, and added a retry interval to the database receiver.
MIRTH-2559: Added a ResponseValidator to the DataType plugin. The response validator is an interface with a single method: validate(response, connectorMessage). A Response object is passed in, where t…
MIRTH-2559: Added a ResponseValidator to the DataType plugin. The response validator is an interface with a single method: validate(response, connectorMessage). A Response object is passed in, where the validator can perform custom logic to set the status / status message / error message.

An HL7v2ResponseValidator has been added, which takes in a response with HL7 v2.x data (either ER7 or XML) and checks MSA.1 against the ACK codes supplied in the response validation properties. Like the generation properties, a Velocity replacer is run on the properties before validation occurs.

The getAutoResponder method on DataTypeServerPlugin has been modified so that it's no longer abstract; now only the HL7 v2.x plugin needs to override it.

TcpDispatcher has been updated to use the response validator of the response inbound data type, rather than validating HL7 data manually.

  1. … 7 more files in changeset.
MIRTH-2558: Added automatic gzip compression/decompression to the HTTP connectors. On the HTTP receiver side, if a client request comes in with Content-Encoding:gzip, the payload will be uncompressed …
MIRTH-2558: Added automatic gzip compression/decompression to the HTTP connectors. On the HTTP receiver side, if a client request comes in with Content-Encoding:gzip, the payload will be uncompressed before dispatching to the channel. If the client request comes in with Accept-Encoding:gzip, the response will be compressed before sending data back. On the HTTP dispatcher side, if Content-Encoding:gzip is specified in the connector settings, the payload will be compressed before being sent to the remote server. If the resulting response comes back with Content-Encoding:gzip, the dispatcher will uncompress the data before storing it in the Response object.
MIRTH-2515: Fixed bug that caused postprocessor errors to update the server log twice.
MIRTH-2515: Fixed bug that caused postprocessor errors to update the server log twice.
Fixed adding the same content type multiple times to the message browser advanced filter overwriting all but the most recent search string.…
Fixed adding the same content type multiple times to the message browser advanced filter overwriting all but the most recent search string.

Fixed searches on destination raw content incorrectly using the source raw instead of source encoded

MIRTH-2570

Issue: MIRTH-2448

    • -61
    • +28
    /trunk/server/dbconf/oracle/oracle-message.xml
    • -61
    • +28
    /trunk/server/dbconf/derby/derby-message.xml
    • -61
    • +28
    /trunk/server/dbconf/mysql/mysql-message.xml
Fixed message import to import custom meta data…
Fixed message import to import custom meta data

Issue: MIRTH-2526

The following fields are now included in the Message Browser quick search:…
The following fields are now included in the Message Browser quick search:

Message ID

Connector Name

Custom meta-data columns (string-type only)

Issue: MIRTH-2528

    • -3
    • +11
    /trunk/server/dbconf/oracle/oracle-message.xml
    • -3
    • +11
    /trunk/server/dbconf/derby/derby-message.xml
    • -2
    • +10
    /trunk/server/dbconf/mysql/mysql-message.xml
MIRTH-2565: Optimized Channel.dispatchRawMessage so that it doesn't need to instantiate and execute a Callable for every message. …
MIRTH-2565: Optimized Channel.dispatchRawMessage so that it doesn't need to instantiate and execute a Callable for every message.

MessageTask is gone; now the logic for creating the source RECEIVED message and processing/queuing is back in Channel. To handle synchronization, we switched the process lock from a wait/notify AtomicBoolean to a Semaphore. The semaphore is initialized with one permit and is fair, meaning that multiple threads trying to acquire a lock in Channel.dispatchRawMessage will be able to do so in order. In addition, a semaphore can be acquired/released on separate threads, whereas a ReentrantLock cannot be.

The channel executor is now gone. To handle cancellation/halting, we now also keep a set of threads on the channel itself. This set represents all threads that are currently processing through Channel.dispatchRawMessage (but doesn't include threads that are in the finishDispatch portion of the lifecycle, even though in most cases that will still be the same thread). Before the process lock is obtained, the thread is added to the set.

When the channel is halted, each thread currently in the set will be interrupted manually. This means that no changes need to be made to the process methods in Channel, DestinationConnector, etc.; the ThreadUtils.checkInterruptedStatus() will still work the same way. When the channel is stopped, a shuttingDown boolean is set to true, meaning that no new threads will be able to be added to the set (if any attempt to, a ChannelException will be thrown). The stop method also obtains and releases the process lock. This is done because even if there are no threads in the dispatchThreads set, there may still be threads processing through SourceConnector.finishDispatch. To prevent deadlocks, we need to obtain the lock to ensure that everything has completed.

Also, the DispatchResult is now instantiated in the finally block, to ensure that the correct value for lockAcquired is used. Because it's possible (though incorrect) for a receiver to call finishDispatch multiple times, we added a protected setLockAcquired method to DispatchResult. In finishDispatch when the lock gets released, the dispatch result is updated accordingly, to ensure that the semaphore's permits don't get incorrectly incremented.

MIRTH-2564: Optimized Channel.process so that the last destination chain is always called directly, rather than being submitted to an executor. The channel constructs a list of only enabled chains (th…
MIRTH-2564: Optimized Channel.process so that the last destination chain is always called directly, rather than being submitted to an executor. The channel constructs a list of only enabled chains (those which have at least one enabled destination connector), and then iterates through the list, submitting each one but the last to the destination chain executor. Then it invokes the call() method on the last chain manually, and gets the Future results for all the other chains as normal.
MIRTH-2563: Optimized transformWithoutSerializing for both HL7 v2.x and NCPDP. ER7Serializer now stores a string array of delimiters (the full inbound delimiter string split by "|"), and iterates thro…
MIRTH-2563: Optimized transformWithoutSerializing for both HL7 v2.x and NCPDP. ER7Serializer now stores a string array of delimiters (the full inbound delimiter string split by "|"), and iterates through the array, checking where each one is contained in the message. If any of them happen to be contained, then the matcher.replaceAll result is returned. In NCPDPSerializer, the inbound delimiter is always singular, so we just do a replace(String, String) call instead.
MIRTH-2562: The response content is no longer serialized all the time; now it is only serialized when the content is actually going to be stored. Also, the interrupt check in the process method has be…
MIRTH-2562: The response content is no longer serialized all the time; now it is only serialized when the content is actually going to be stored. Also, the interrupt check in the process method has been moved outside the conditional so that it checks the interrupt flag for every send attempt, rather than just the first attempt.
MIRTH-2561: Optimized the pre/postprocessors so that they don't instantiate and execute a Callable every time. Instead, a check is done in JavaScriptUtil to determine whether or not the script needs t…
MIRTH-2561: Optimized the pre/postprocessors so that they don't instantiate and execute a Callable every time. Instead, a check is done in JavaScriptUtil to determine whether or not the script needs to run. Only if it is needed will it submit the JavaScriptTask. The postprocessor methods in JSU have been de-normalized to mimic the preprocessor. Also, the scope is no longer always created; now it's created "as needed" for both the global and channel script portions.
MIRTH-2567, MIRTH-2568: Modified TcpReceiver so that it wraps the response output stream in a BufferedOutputStream once, at the same time the stream handler is being created. Also moved the remoteSide…
MIRTH-2567, MIRTH-2568: Modified TcpReceiver so that it wraps the response output stream in a BufferedOutputStream once, at the same time the stream handler is being created. Also moved the remoteSideHasClosed check to the catch clause in sendResponse, so it doesn't have to do the check every time.
The destination queue will now check the message's properties type against the the destination connector's properties type. If they do not match, the message will error and be removed from the queue. …
The destination queue will now check the message's properties type against the the destination connector's properties type. If they do not match, the message will error and be removed from the queue. This is to prevent a ClassCastException later on when the connector attempts to send the message.

Issue: MIRTH-2365

MIRTH-2463: Fixed deadlock issue when a "Remove All Messages" task is run on a stopping channel.
MIRTH-2463: Fixed deadlock issue when a "Remove All Messages" task is run on a stopping channel.
MIRTH-2459: Paused channels now remain paused after a "Remove All Messages" task runs. The PAUSED and PAUSING states are now also used by the channel itself. Before, the Paused status was inferred by …
MIRTH-2459: Paused channels now remain paused after a "Remove All Messages" task runs. The PAUSED and PAUSING states are now also used by the channel itself. Before, the Paused status was inferred by looking at each connector status individually. However now the engine controller just uses the status directly from the channel. The PauseTask and ResumeTask now correctly update the channel status, including setting the state to PAUSING before attempting to stop the source connector. This means that a pausing channel can be halted, just like starting or stopping channels.

The StartTask now also takes a boolean in the constructor, indicating whether or not to start the source connector. DonkeyMessageController then uses the prior state of a channel to determine this. If a channel is being restarted and the prior state was PAUSED or PAUSING, the channel will be started except for the source connector. Recovery will still occur in this case.

Replaced use of the "string_agg" aggregate function in the message browser in Postgres with the "array_agg" function, which is supported by Postgres >= 8.4. The former is only available in >= 9.0.…
Replaced use of the "string_agg" aggregate function in the message browser in Postgres with the "array_agg" function, which is supported by Postgres >= 8.4. The former is only available in >= 9.0.

Tested and verified that there are no other obvious problems that occur when using Postgres 8.4.

Mirth Connect 3.0 now supports Postgres >= 8.4

Issue: MIRTH-2341

Fixed exception that occurred when the pruner was not running…
Fixed exception that occurred when the pruner was not running

Issue: MIRTH-2539

MIRTH-2566: Fixed bug that caused a question mark to always get appended to HTTP requests, even if no query parameters are specified.
MIRTH-2566: Fixed bug that caused a question mark to always get appended to HTTP requests, even if no query parameters are specified.