Commit Graph

561 Commits

Author SHA1 Message Date
Marius Bogoevici
d2800efd1d Update Spring Cloud Build to 1.2.0.RELEASE 2016-08-24 09:50:25 -04:00
Marius Bogoevici
c90bea99ae Rename 'spring-cloud-stream-docs' to 'spring-cloud-stream-core-docs 2016-08-22 23:55:17 -04:00
Marius Bogoevici
0eae62f113 Add concrete example of using RabbitMQ 2016-08-22 17:00:07 -04:00
Soby Chacko
247f49350e Extract RabbitMQ and Kafka binder documentation
Fixes #629
2016-08-22 16:56:27 -04:00
Marius Bogoevici
bac8877a52 Correct example in the documentation
Fixes #586
2016-08-18 16:07:51 -04:00
Marius Bogoevici
d43f1d42fc Add Javadoc 2016-08-18 12:45:35 -04:00
Marius Bogoevici
c194ae720f Refactor AbstractMessageChannelBinder
- allow the use of the destination reference returned by
`createProducerDestinationIfNecessary` when invoking `createProducerMessageHandler`
2016-08-18 12:26:16 -04:00
Marius Bogoevici
ac443b56bc Move spring-cloud-stream-dependencies to spring-cloud-stream-starters
Fixes #621
2016-08-17 19:42:16 -04:00
Marius Bogoevici
a9dda09d57 Set an explicit context class for the binders
Since this is an internal construct, we can safely ignore
the application settings.
2016-08-17 16:07:15 -04:00
Marius Bogoevici
d76e49b795 Add spring-cloud-stream-tools module
Fixes #618

- Store checkstyle rules in spring-cloud-stream-tools module
2016-08-17 13:07:37 -04:00
Dave Syer
12a34b7bb8 Change repo URLs to https 2016-08-17 17:31:27 +01:00
David Turanski
d175e68093 Fix copy-paste-o 2016-08-16 16:55:40 -04:00
Ilayaperumal Gopinathan
5c510db012 Aggregate application doesn't need binder in its classpath
- BinderTypeRegistry will have empty binder types for aggregate applications
  - Check if `SharedChannelRegistry` bean is in the context, then proceed with no binder type

This resolves #576

Support self contained aggregator app without binder dependency

 - Check if the aggregator application is self contained (with both source and sink applications exist) and if so, avoid having the check to have binder in classpath at BinderFactoryConfiguration
 - Given the aggregator parent context has binder configuration classes via `@EnableBinding`, enable all the auto configuration classes(excluding the binding configuration classes) as a parent for aggregator builder. This will have the aggregator parent to determine if the aggregator app is `selfContained` and set the parent context once all the app configurers are set
 - Add tests
 - Remove unused aggregator application methods
2016-08-11 16:29:46 -04:00
Marius Bogoevici
e462603dea Upgrade to Spring Boot 1.4.1.BUILD-SNAPSHOT 2016-08-07 02:01:44 -04:00
Marius Bogoevici
09503c8bec Reactive types docs
Add library usage info
2016-07-31 21:29:03 -04:00
Vinicius Carvalho
4422b21438 Add Avro serialization and schema management support
- Add schema server implementation
- Add schema client abstraction
- Add schema client implementation for own schema registry server
- Add schema client supporting Confluent schema registry
- Add Avro-based message converter supporting a static schema resource
- Add Avro-based message converter with schema evolution support, via
  schema registry client.
- On serialization, the converter register writer schemas with the schema
  registry server and augment the content type of outbound message with
  schema information.
  On deserialization, the reading converter will fetch the schema from the server
  if not available locally.

Use class information if schema is not specified

In the case of SpecificRecord and Reflective readers/writers, the class information can be used instead

Make subtype prefix configurable and shorten the subject

- Subtype prefix is now configurable and subject is the lowercase schema name
- Enhance/correct javadoc

Refine AbstractAvroMessageConverter

- distinguish between writer and reader schema when reader is created

Add schema registry and schema registry client docs
2016-07-31 21:26:36 -04:00
Soby Chacko
8dd22ebca0 Move calling afterProperties on consumer and producer endpoints from binder implementations to core 2016-07-28 19:00:35 -04:00
Marius Bogoevici
08d65a92bb Initial support for Reactive API
Fixes #520
Fixes #458 (for non-reactive binders)

Adds spring-cloud-stream-reactive module.
Introduces support for declarative @StreamListener and @Input and @Output annotated parameters.
Add StreamListenerArgumentAdapter and StreamListenerResultAdapter for wrapping bindable inputs
and outputs when passing arguments to declarative @StreamListener.
Adds support for using reactive types (Flux/Observable) with traditional binders.
Introduce FluxSender and ObservableSender for handling multiple streaming outputs per method.
Ensure that errors are caught and logged.

Fixing constructor assertions and Javadoc

Addressing PR comments

- rework @Input/@Output parameter validation
- renamed StreamListenerArgumentAdapter to StreamListenerParameterAdapter
- ensure that parameter direction is accounted for in the current adapters
2016-07-26 14:47:03 -04:00
Marius Bogoevici
55b9aa75dd Rework the converter system
Fixes #505

The goals are twofold: to simplify the registration of new converters and
to add some consistency to the conversion process, and align them with the
way converters are used in generic Spring Messaging listeners, by describing
two possible transformations: inbound, message (including contentType)->targetClass,
and outbound payload+headers -> message. The idea is for the two
transformations to match the input and output directions of the bound channels.

List of changes:

- Create and configure input/output channels distinctly - reflected
  in the definitions of `BindableChannelFactory` and `MessageChannelConfigurer`;
- Replace AbstractFromMessageConverter with bidirectional converters;
- Use the channel direction (input/output) to determine whether
  `toMessage` or `fromMessage` will be invoked;
- Use contentType support from `AbstractMessageConverter` to map
  converters to mime types instead;

Making converters more robust

Addressing comments

Convert content type headers to String before serializing

Addressing further PR comments
2016-07-22 17:02:38 -04:00
Marius Bogoevici
bd92af4784 Add AbstractMessageChannelBinder
Handle common aspects of message-channel binders:
- added generic, customizable ReceivingHandler and SendingHandler
- made doBindProducer delegate to a series of template methods
- made doBindConsumer delegate to a series of template methods
- moved partitioning to an interceptor, thus fixing #493

Removed unused manual ack handling
2016-07-18 17:15:49 -04:00
Eric Bottard
7607d781c7 Fix doc typo 2016-07-08 16:42:48 +02:00
Soby Chacko
463de397bd binder moving - cleanup 2016-06-28 22:06:31 -04:00
Gunnar Hillert
af2702e62f gh-580 Include API Docs in Docs Zip 2016-06-23 13:43:09 -10:00
Ilayaperumal Gopinathan
74189942f4 Remove RabbitTestSupport class 2016-06-23 12:34:30 +02:00
Soby Chacko
ccea09f8a9 Remove Kafka specific test rules from core repo 2016-06-21 20:49:46 -04:00
Eric Bottard
97f4b0f5f4 Move binders out of the main repo
Fixes spring-cloud/spring-cloud-stream#546

Fixing merge conflicts
2016-06-21 16:28:48 -04:00
Marius Bogoevici
daf454410c Polishing for GH-570
- Add back old property in deprecated form for backwards compatibility.
2016-06-08 11:20:31 -04:00
Simon Weis
c1f4ba66d3 Fix typo in RabbitBinderConfigurationProperties
Substitute adminAdresses with adminAddresses.
2016-06-08 11:20:31 -04:00
Marius Bogoevici
f8e4df4711 Rabbit Configuration Corrections
Fixes #564

- Correct an issue where if the `cloud` profile is enabled but no Connectors are available,
no `ConnectionFactory` will be created;
- Introduce a property named `spring.cloud.stream.overrideCloudConnectors` that allows
to suppress the use of Cloud connectors in the application and fall back to Spring Boot
configuration. This is provided so that specific binders can be created with arbitrary
connectivity parameters if needed.
- Add documentation.
2016-06-07 17:11:16 -04:00
Dave Syer
9a65728cc6 Migrate to mvn 3.3.9 2016-06-04 09:14:54 +01:00
Ilayaperumal Gopinathan
9207811214 Fix mainApplicationClass for child contexts
- Make sure to set the appropriate mainApplicationClass name for the child applications

This resolves #562
2016-06-03 21:20:14 +05:30
Marius Bogoevici
0076c7b9f5 Update to Spring Integration Kafka 1.3.1.RELEASE 2016-06-02 16:45:40 -04:00
Mark Fisher
4d8ced734b polishing 2016-06-02 13:36:05 -04:00
Marius Bogoevici
6eddac9056 Allow binders to not affect the defaulting process
Fixes #557

Allow for a `defaultCandidate` flag on a binder configuration that, when FALSE,
ensures that the binder does not interfere with the default configuration process.
2016-06-02 13:22:14 -04:00
Marius Bogoevici
53d86f5523 Simplify marshalling of JSON messages
Fixes #558
2016-06-02 18:33:16 +05:30
Marius Bogoevici
99db7dff9b GH-541 Make reconnect time for Kafka/Rabbit configurable 2016-06-01 14:12:26 -04:00
Marius Bogoevici
aef08a28a3 Move tests to AssertJ 2016-06-01 13:10:42 -04:00
Eric Bottard
fbe9bbac7e Fix doc source formatting 2016-06-01 15:40:09 +02:00
Marius Bogoevici
1f3661f4c4 Fix race condition in testDefaultAutoCommitOnErrorWithDlq 2016-05-29 08:51:28 -04:00
Marius Bogoevici
e2f91417c3 Add setting for autoCommitOnError
Fixes #542

- add option for `autoCommitOnError`
- make `autoCommitOnError` follow the state of `enableDlq` - no need to suppress commits if messages will be sent elsewhere
2016-05-28 11:08:31 -04:00
Ilayaperumal Gopinathan
892797c0b0 Clarify channel names in the doc
Fixes #551
2016-05-26 11:53:12 -04:00
Marius Bogoevici
51a451300a Use KafkaBinderConfigurationProperties directly
Fixes #548

- Remove redundant property copying
- Make `socketBufferSize` configurable (it wasn't provided as a configuration option)
2016-05-25 17:59:19 -04:00
Marius Bogoevici
1d0031d356 Use CustomizableThreadFactory for Kafka Binder
Fixes #543

We don't need another ThreadFactory implementation and can use Spring Framework class instead.
2016-05-17 15:03:46 -04:00
Ilayaperumal Gopinathan
48d2888b71 Fix retry consumer properties for Kafka
- Remove `ignored by Kafka` for the retry properties
2016-05-16 16:41:48 +05:30
Ilayaperumal Gopinathan
bcc45b8685 Use random port in StreamListenerTests 2016-05-13 11:44:35 +05:30
Ilayaperumal Gopinathan
33500ae183 Use random server port in ModuleAggregation tests 2016-05-13 11:44:28 +05:30
Marius Bogoevici
18dc0a707d Implement remainder of Spring Boot Checkstyle code rules
Fixes #532

Implements most of the remaining rules from Spring Boot, except JavaDoc + a few additional ones
2016-05-12 19:19:59 -04:00
Marius Bogoevici
bbe5b3ee56 Fix Travis build target 2016-05-12 15:57:07 -04:00
Marius Bogoevici
91958ce53d Travis updates
- Remove use of .settings.xml in favour of Spring profile
- Use external Kafka broker
2016-05-12 15:27:06 -04:00
Dave Syer
49e20d38c2 Re-instate .settings.xml for Travis 2016-05-12 11:34:46 +01:00