Commit Graph

7003 Commits

Author SHA1 Message Date
Soby Chacko
d43bbc8eda INT-2531: Remove deprecations in XML Adapter after upgrade to Spring 3.1.1
* BeanDefinitionParserDelegate constructor now prefers an Environment. Circumvent this
preference by directly getting BeanDefinitionParserDelegate from the associated ParserContext
2013-03-14 13:47:06 -04:00
Gunnar Hillert
0fc21de170 Merge pull request #765 from garyrussell/INT-2957
* garyrussell-INT-2957:
  INT-2957 Remove Unnecessary AspectJ Dependencies
2013-03-14 10:54:19 -04:00
Gary Russell
c9fc15892a INT-2957 Remove Unnecessary AspectJ Dependencies
Core, JDBC, JMX, JPA each had dependencies for both
weaver and rt jars. weaver is a superset of rt.

Remove dependencies on the rt jar.

Further JDBC, JPA have no dependencies on AspectJ.

Finally, the JMX dependency was compile, when only
testCompile is needed.
2013-03-14 10:08:34 -04:00
Gary Russell
a3ff5bc2e7 Merge pull request #764 from artembilan/INT-2958 2013-03-13 12:06:01 -04:00
Artem Bilan
6ae61a3345 INT-2958: XSD: move 'charset' from common attrs
`charset` for `<object-to-string-transformer>` was placed in the common `inputOutputChannelGroup` attributeGroup.
`charset` wasn't available  within `<chain>`.

* Move 'charset' from `inputOutputChannelGroup` to the new `specialized-transformer-charset-aware-type` complexType
* Add test for 'charset' within `<chain>`

JIRA: https://jira.springsource.org/browse/INT-2958
2013-03-13 12:02:09 -04:00
Gary Russell
834974481a Merge pull request #707 from ghillert/INT-2882 2013-03-12 18:45:43 -04:00
Gunnar Hillert
06831b9e22 INT-2882 Upgrade DocBook Reference Plugin to 0.2.6
For reference see: https://jira.springsource.org/browse/INT-2882

* Verify spacing
* Ensure all source code samples are typed: e.g. <programlisting language="xml">
* Ensure source code fits space in PDF format
2013-03-12 18:45:25 -04:00
Gunnar Hillert
35365990f9 Merge pull request #752 from garyrussell/INT-2932
* garyrussell-INT-2932:
  INT-2932 TCP Connection Events - Doc and Polishing
2013-03-08 10:10:57 -05:00
Gary Russell
d059abf4d1 INT-2932 TCP Connection Events - Doc and Polishing
INT-2932
- Reference Documentation

INT-2941
- Add getter for Throwable
- Add auto-startup to Parser, Endpoint (already in schema)
- Add phase to schema, Parser

(Schema changes are mostly indentation because the element now
extends SmartLifecycleType).
2013-03-07 17:26:32 -05:00
Gary Russell
8b476b2d76 Merge pull request #756 from ghillert/INT-2945 2013-03-05 11:32:57 -05:00
Gunnar Hillert
a099eba9a8 INT-2945 - StoredProc isFunction Property Not Set
For reference see: https://jira.springsource.org/browse/INT-2945

* ensure that for StoredProcedure Inbound Channel Adapter the *isFunction* property is set
* add test

INT-2945 - Code Review - Add Tests
2013-03-05 11:31:42 -05:00
Gary Russell
7b6b740cce INT-2950 Use spring-amqp 1.1.4.RELEASE 2013-03-05 11:00:32 -05:00
Gary Russell
139fabed22 Merge pull request #757 from bijukunjummen/patch-1 2013-03-01 11:48:46 -05:00
Biju Kunjummen
0f6589d894 INT-2947 Update gateway.xml With Sample Link
Very minor change - provided a link to the github
location of the async-gateway sample being referred to

Polished to add some line breaks.
2013-03-01 11:46:33 -05:00
Mark Fisher
9efb70f24e Merge pull request #751 from garyrussell/INT-2937
* INT-2937: Fix Race Condition in MGS Reaper
2013-02-25 14:40:11 -05:00
Gary Russell
eb07178381 INT-2937 Fix Race Condition in MGS Reaper
Groups changed within the same millisecond that they
were selected for reaping can cause aggregators to
emit duplicate messages.

Use the re-fetched group (used to see if the timetamp
changed) instead of the group passed in to forceClose
(the group might have changed since it was selected as
eligible for reaping).

We still retain the last modified check because it
might have been expired using timeoutOnIdle.
2013-02-25 14:36:47 -05:00
Mark Fisher
69fcf5b16a Merge pull request #749 from garyrussell/INT-2936
* INT-2936: Fix TCP Binary DeSerialization with NIO
2013-02-25 13:08:55 -05:00
Gary Russell
f48d175e83 INT-2936 Fix TCP Binary DeSerialization with NIO
Inadvertent sign extension on binary data with bit 7 set
causes early termination of binary deserializers.

The ChannelInputStream (which replaced the piped input
and output streams) failed to mask off the top 24 bits
of "normal" bytes received, causing Deserializers to
believe the stream was closed.

Add a mask of 0xff to bytes read.

Add a test case.
2013-02-25 12:57:17 -05:00
Gary Russell
05cd1694c2 INT-2940 Fix Race Condition in TCP Connection Test
Assertion that server side connection was established could
occur after the connection was established, but before it was
added to the collection.

Add a latch.
2013-02-20 10:44:42 -05:00
Spring Buildmaster
b2be9f643b [artifactory-release] Next development version 2013-02-14 14:29:56 -08:00
Spring Buildmaster
382e1096f4 [artifactory-release] Release version 3.0.0.M1 2013-02-14 14:29:40 -08:00
Gary Russell
c1fe62857b Merge pull request #747 from ferstl/INT-2931 2013-02-14 14:35:06 -05:00
Stefan Ferstl
4585699e62 INT-2931 Fix Router Race Condition
AbstractMessageRouter.getRequiredConversionService() and
IntegrationObjectSupport.getConversionService() try to initialize the
conversion service and may be called from multiple threads. There is
a race condition where this could end up in an uninitialized conversion service
causing NPEs in subsequent method calls.

To solve this issue, the conversion service is initialized with
double-checked locking.

For further details see https://jira.springsource.org/browse/INT-2931

INT-2931 Polishing - Add Test Case

Add a test case that reliably reproduces the issue and verifies
the fix.
2013-02-14 14:32:04 -05:00
Gunnar Hillert
bb5bd1169e Merge pull request #743 from garyrussell/INT-2877
* garyrussell-INT-2877:
  INT-2126 Add TcpConnection Event Publisher
2013-02-14 12:48:23 -05:00
Gary Russell
b045e8c2be INT-2126 Add TcpConnection Event Publisher
Reference: https://jira.springsource.org/browse/INT-2126

* Add TcpConnectionEvent for OPEN, CLOSE, EXCEPTION.
* Add Event Type Enum - Provides type safety for event types.
* Add <int-ip:tcp-connection-event-inbound-channel-adapter />
* Add the ability to filter events (restrict to one or more subclasses)
* Add publishEvent() to TcpConnectionSupport to permit, for example, connection interceptors to publish events via the connection, but the event source can only be the connection used to publish the event.
* Add documentation to Reference Documentation section *What's New*

INT-2871 Provide Mechanism to Find TCP Connections
Reference: https://jira.springsource.org/browse/INT-2871

* Add getOpenConnectionIds() to Abstract Connection Factory
* Add closeConnection(String connectionID)
* Introduce removeClosedConnectionsAndReturnOpenConnectionIds

INT-2877 TCP Extension Improvements
Reference: https://jira.springsource.org/browse/INT-2877

* Make improvements to make extension easier.
* Add setCustomHeaders() to mapper.
* Add mapper to connection factory namespace parser.
* Add plumbing for stateful Deserializers.
* Refactor setting standard headers
* rename setCustomHeaders to supplyCustomHeaders - returning a Map and not exposing the MessageBuilder to subclasses

INT-2872 Remove Deprecated Items in ip Module
Reference: https://jira.springsource.org/browse/INT-2872

* pool-size Attribute
* setScheduler
* TcpSendingMessageHandler.getConnection()
* Deprecated attribute on TCP Connection Factory.
2013-02-14 12:05:08 -05:00
Gunnar Hillert
0374b56ee1 Merge pull request #734 from garyrussell/INT-2853
* garyrussell-INT-2853:
  INT-2853 ObjectToStringTransformer Improvements
2013-02-14 11:05:15 -05:00
Gary Russell
83fc5e449a INT-2853 ObjectToStringTransformer Improvements
* Convert byte[] and char[] to String rather than simply using toString().
* Allow the charset to be configured for byte[] payloads.
* Add tests.
* Add reference documentation updates.
2013-02-14 11:02:48 -05:00
Gunnar Hillert
d8dc140b17 Merge pull request #745 from garyrussell/INT-2929
* garyrussell-INT-2929:
  INT-2929 Fix JMX Occasional Failing Tests
2013-02-14 02:10:56 -05:00
Gary Russell
32ccd988a0 INT-2929 Fix JMX Occasional Failing Tests
ExponentialMovingAverageRateTests are VERY sensitive to
timing, when running on a busy platform.

Add code to skip the assertions if we detect we are
running on a slow machine.
2013-02-14 02:08:53 -05:00
Gunnar Hillert
0ab076ee24 Merge pull request #746 from garyrussell/INT-2906
* garyrussell-INT-2906:
  INT-2906 Upgrade Groovy to 2.1.0
2013-02-14 02:04:07 -05:00
Gary Russell
83e84b0272 INT-2906 Upgrade Groovy to 2.1.0 2013-02-13 16:50:01 -05:00
Mark Fisher
937b38c366 Merge pull request #733 from garyrussell/INT-2900
* INT-2900: Remove Extraneous Debug Log
2013-02-13 14:24:36 -05:00
Gary Russell
5edebb303e INT-2900 Remove Extraneous Debug Log
When referencing a <gateway/> from a <service-activator/>, a debug
log is written with a full stack trace.

This is because all methods on the proxy are considered candidates,
but one method (addAdvice) has multiple parameters and can't be
used to process a message.

Add code to detect a proxy that has no target object; if the Proxy
only has one interface, then use that as the targetClass.
2013-02-13 14:23:20 -05:00
Gunnar Hillert
d765add255 Merge pull request #728 from garyrussell/INT-2911
* garyrussell-INT-2911:
  INT-2911 IO Exceptions Not Logged as ERROR
2013-02-13 12:38:30 -05:00
Gary Russell
84e9c0ec36 INT-2911 IO Exceptions Not Logged as ERROR
TcpNetConnection IO errors were only logged under DEBUG.

* Code was added to suppress the error log when the exception was due to a normal close. This inadvertently suppressed all ERROR logs.
* Capture a local copy of this.noReadErrorOnClose before closing the socket after an exception.
* Add test case to ensure ERROR log is emitted.
2013-02-13 12:34:18 -05:00
Gunnar Hillert
82173d3be6 Merge pull request #739 from garyrussell/INT-2922
* garyrussell-INT-2922:
  INT-2922 Fix TypeConverter Concurrency Issue
2013-02-12 16:55:44 -05:00
Gary Russell
fc8985aee7 INT-2922 Fix TypeConverter Concurrency Issue
During initialization, it is possible for type conversion to fail because a second thread accesses a partially built list of PropertyEditors. This is because getDefaultEditor(Class) is not thread-safe.

* Add a test with mocks and spies to verify concurrent access to the method occurs before the fix, and not after the fix.
* Synchronize the call to getDefaultEditor(), when called from canConvert() and convertValue().
* Only synchronize the call until we have invoked the method at least once.
2013-02-12 16:53:16 -05:00
Gunnar Hillert
7c7dbe65c4 Merge pull request #732 from garyrussell/INT-2823
* garyrussell-INT-2823:
  INT-2823 Add QueueChannelOperations
2013-02-12 15:31:27 -05:00
Gary Russell
e822bfd908 INT-2823 Add QueueChannelOperations
Operations on QueueChannel (clear, getQueueSize etc) are not available
when the IntegrationMBeanExporter is configured because they
are not declared on the PollableChannel interface.

Add an additional interface QueueChannelOperations.

The proxy proxies all interfaces so users can cast the
proxy to QueueChannelOperations to use its methods.
2013-02-12 15:05:01 -05:00
Gary Russell
716b5f7f8e Merge pull request #729 from ghillert/INT-2912 2013-02-12 14:56:25 -05:00
Gunnar Hillert
da817cb754 INT-2912 JdbcMessageStore Add 'region' to Queries
Missing region column in some queries.

For reference see: https://jira.springsource.org/browse/INT-2912

INT-2912 - Code Review
* Eliminate Spring Application Context for Test
* Improve SQL Query

INT-2912 Polishing

Modified testVerifyMessageGroupCount to test size of each
group in each region.
2013-02-12 14:54:46 -05:00
Gary Russell
6eb009fd62 Merge pull request #727 from artembilan/INT-2899 2013-02-12 14:29:29 -05:00
Artem Bilan
8c07856fa1 INT-2899: Remove Redundant Logic from Aggregator
Previously, `AggregatingMessageHandler#setExpireGroupsUponCompletion` had additional logic
for removing complete MessageGroups. It could produce some overhead on application start-up with big persistent `MessageStore`.
This logic played a role to remove empty groups from a `MessageStore`.
Since `AbstractCorrelatingMessageHandler#forceComplete` has an ability to to remove empty groups too,
this logic became redundant.
So, to clean `MessageStore` from empty complete groups, it's sufficient to use a `MessageGroupStoreReaper`.

* Remove logic iterating over the `MessageStore` from `AggregatingMessageHandler#setExpireGroupsUponCompletion`
* Polishing `AggregatorSupportedUseCasesTests.java` to use `store.expireMessageGroups(0)`
* Introduce `empty-group-min-timeout` xml-attribute, populating `AbstractCorrelatingMessageHandler#minimumTimeoutForEmptyGroups`
* Add parser tests for `empty-group-min-timeout` attribute

JIRA: https://jira.springsource.org/browse/INT-2899

INT-2899: Documentation about changes of ACMH

* rename new XSD-attribute to `empty-group-min-timeout`
* add to Reference Manual description about `empty-group-min-timeout`
* add 'What's new' for `empty-group-min-timeout`
* add 2.2-3.0 Migration Guide note

INT-2899 Doc Polishing
2013-02-12 14:27:31 -05:00
Gary Russell
22859bf63e Merge pull request #742 from ghillert/INT-2728 2013-02-12 11:56:51 -05:00
Gunnar Hillert
731b338c84 INT-2728 Stored Proc Fix Missing Schema Attribute
INT-2728 - Stored Proc - Add 'return-value-required' attribute

* For Stored Procedure Inbound Channel Adapter: Add 'return-value-required' attribute
* Add tests

For reference: https://jira.springsource.org/browse/INT-2728

INT-2878 Polishing

Add a default false assertion to the parser tests.
2013-02-12 11:51:52 -05:00
Gary Russell
bc51c86a21 Merge pull request #744 from ghillert/INT-2919 2013-02-12 11:05:53 -05:00
Gunnar Hillert
e2cc2326f1 INT-2919 - Upgrade Spring Data Gemfire to 1.2.2.RELEASE
For reference: https://jira.springsource.org/browse/INT-2919
2013-02-12 11:00:08 -05:00
Gary Russell
c60b7afa38 Merge pull request #722 from artembilan/INT-2888 2013-02-12 10:52:41 -05:00
Artem Bilan
77fae8844a INT-2888 Fix MapToObjectTransformerParser CL Issue
In the parent-child environment configuration that relies on class names may produce
a `ClassNotFoundException`.

* remove usage of `ClassLoader` in the `MapToObjectTransformerParser` and allow to use the `ConversionService` from application context
* remove deprecation from `MapToObjectTransformer`
* refactor `MapToObjectTransformer` to use `IntegrationObjectSupport#getConversionService()`
* remove fallback to the `beanFactory#getConversionService()` in the `ExpressionUtils`

JIRA: https://jira.springsource.org/browse/INT-2888

INT-2928: Do Not Fallback to BF's ConversionService

* Polishing according PR's comments
* Important note about `conversionService` & `integrationConversionService` beans
* Link a JIRA about elimination of `BeanFactory`'s `ConversionService` usage
* Add a note to the 2.2-3.0 Migration Guide

JIRA: https://jira.springsource.org/browse/INT-2928

INT-2888 Doc Polishing
2013-02-12 10:51:36 -05:00
Gunnar Hillert
e994c4dab3 Merge pull request #735 from sobychacko/INT-2526
* sobychacko-INT-2526:
  INT-2526 - Remove additional deprecations in Core
  INT-2526: Remove deprecations in Core after upgrade to Spring 3.1.1
2013-02-11 23:45:20 -05:00