INT-2798 Rename Redis Store Adapters
Polishing

Renaming and Repackaging.

INT-2798 Add More Tests

Add more tests for Store Outbound Adapter.

INT-2798 Polishing

More tests - zset increment/overwrite with Map payload.
           - use different value for simple overwrite.
Merge pull request #674 from markfisher/INT-2798
INT-2821 Find Existing Mails if No RECENT Support

Previously, if an IMAP server supports IDLE, but not
RECENT, no existing messages were retrieved until a new
message arrived.

INT-2821 Polishing - Fix Race Condition

Use searchForMessages() when server doesn't support RECENT.

Simply skipping the first idle() doesn't work
because receive() closes the folder, there was a race condition
where a new message could arrive between the previous receive()
and folder.open() in waitForMessages().

Updated mock test so that first call to waitForMessages() finds
messages and does not idle(), and subsequent calls does not
find messages and goes to idle().

Also tested in the debugger against gmail which (at the time of
writing) does not support RECENT.
Merge pull request #678 from garyrussell/INT-2821

* INT-2821: Find Existing Mails if No RECENT Support
INT-2820 Shutdown Default Idle Executor

The default executor for sending messages from the IMAP IDLE
channel adapter is a single threaded thread pool.

If the default executor is used (no executor injected), shut
it down when the adapter is stopped.

INT-2820 Polishing

If using the default sendingTaskExecutor, create a new one
when restarted.

Add test to restart adapter after stop.

INT-2820 Polishing

Review comments; protect for null sendingTaskExecutor.
Merge pull request #679 from garyrussell/INT-2820

* INT-2820: Shutdown Default Idle Executor
INT-2827 Fix Amqp Gateway Tests

Use a unique channel for each gateway in
AmqpOutboundGatewayParserTests.
Merge pull request #681 from garyrussell/INT-2827

* INT-2827: Fix Amqp Gateway Tests
INT-2815 Refactor AbstractPollingEndpoint

Recent changes to APE were sub-optimal because the subclasses
had to call back into the parent abstract class.

Deprecate doPoll() on APE.

Introduce a temporary intermediate abstract class that supports
transaction synchronization.

This class will be deprecated in 3.0.0 when its methods will
be pulled up into APE.

INT-2815 Polishing

Make ATSPE package visibility.

Add helpers to enable early migration to 3.0 structure.

INT-2815 Polishing

Fix javadoc to emphasize that doPoll() will no longer
be overridable in 3.0.

Rename doReceive() to receiveMessage() to match more closely
with handleMessage().

INT-2815 Polishing

Fix message in UnsupportedOperationException.
Merge pull request #677 from garyrussell/INT-2815a

* INT-2815a: Refactor AbstractPollingEndpoint
INT-2674 - Add JdbcChannelMessageStore
INT-2674 - Added slow/failing JDBC Message Store Tests

INT-2674 - Code Review Changes

INT-2674 - Add support for HSQL

INT-2674 - Add documentation
* Refactor Test Cases
* Code Review Changes

INT-2674 - Code Review Changes

INT-2674 - Code Review Changes

INT-2674 - Renamed classes

INT-2674 - Code Review Changes
Merge pull request #676 from ghillert/INT-2674
INT-2686 MessageGroupQueue Optimization

INT-2826 - Minimize calls to MessageGroupQueue.size() when infinite capacity
For reference see: https://jira.springsource.org/browse/INT-2826

INT-2826 - Code Review Changes
Merge pull request #680 from ghillert/INT-2826
INT-2828 Remove Package Tangle

* Remove Class Tangle in JPA
* tcp.connection
* tcp.connection.support
* Add Comment to MessageGroupCallback
  - Comment that it is moving into MGS in 3.0.
  - Convert DOS newlines to Unix.

For reference see: https://jira.springsource.org/browse/INT-2828
Merge pull request #682 from garyrussell/INT-2828

* garyrussell-INT-2828:
  INT-2828 Remove Package Tangle
[artifactory-release] Release version 2.2.0.RC3
[artifactory-release] Next development version
INT-2839 Fix TCP Caching Connections with Gateways

Using the CachingClientConnectionFactory with a gateway
doesn't work. The Listener (gateway) was not being set up
properly by the wrapper. Instead, the actualListener in the
wrapped connection was set to null. This caused the connection
to "close" itself (return to the pool) immediately after the send.

In addition, even with the actualListener set up to properly
reference the gateway, it still wouldn't work because the
gateway can't correlate the reply (the cached connectionId is
prefixed with "cached:" so the gateway can't find the reply.

Further, when onMessage() returned, it caused the reader loop
to end.

Fixes:

1. Properly set up the cached connection with the real listener
so that ultimately the underlying connection sees there is an
actualListener and so doesn't close itself after the send.
2. Override getListener() on the cached connection to return the
real listener.
3. Override onMessage() in order to fix up the connection id in
the message, and return true (intercepted) so the connection doesn't
close itself (terminate the reader thread).
4. close() (return to the pool) after invoking the gateway's
onMessage().
5. Add test cases to verify proper operation including an assertion
that the pooled connection is reused.

This is made a little more complex by the tangle between
connections and connection interceptors; mainly because single-use
connections close themselves after use. This will be addressed in
3.0 (INT-2829) making connection interceptors simpler.
Merge pull request #686 from garyrussell/INT-2839

* INT-2839: Fix TCP Caching Connections with Gateways