Commit Graph

46 Commits

Author SHA1 Message Date
GitHub Actions Bot
180d4e55e8 Next development version 4.0.1-SNAPSHOT / 2022.0.1-SNAPSHOT 2023-10-27 21:14:16 -05:00
Artem Bilan
cf9d8cd79c GH-500: Workaround for non-serializable header (#503)
Fixes https://github.com/spring-cloud/stream-applications/issues/500

When `listeners` are provided for `DefaultKafkaConsumerFactory`,
the target `KafkaConsumer` instance is proxied.
The `java.lang.reflect.Proxy` is `Serializable`,
but the value it is wrapping is not.
When the `MessageHeaders` is serialized (e.g. into persistent `MessageStore`),
it checks for `Serializable` type only on top-level object of the header.
Therefore, the `Proxy` is passing condition, but eventually we fail
with `NotSerializableException`, since the proxied object is not like that

* Remove `kafka_consumer` from a message before it reaches an aggregator
with its logic to serialize message into the store

This is a workaround until Spring for Apache Kafka is released
with the fix: https://github.com/spring-projects/spring-kafka/pull/2822
2023-09-22 15:02:02 -05:00
GitHub Actions Bot
21079bdc54 Next development version 4.0.0-SNAPSHOT / 2022.0.0-SNAPSHOT 2023-07-21 12:40:45 +00:00
GitHub Actions Bot
4a595f2284 Release 4.0.0-RC2 / 2022.0.0-RC2 2023-07-21 12:40:08 +00:00
GitHub Actions Bot
c7548ae4e3 Next development version 4.0.0-SNAPSHOT / 2022.0.0-SNAPSHOT 2023-07-20 14:56:01 +00:00
GitHub Actions Bot
5eade0d669 Release 4.0.0-RC2 / 2022.0.0-RC2 2023-07-20 14:55:34 +00:00
GitHub Actions Bot
bcdb881fac Next development version 4.0.0-SNAPSHOT 2023-06-14 04:47:46 +00:00
GitHub Actions Bot
358be92abd Release 4.0.0-RC1 2023-06-14 04:47:29 +00:00
Corneil du Plessis
0c0673552a Restore change for Mongo Tests. 2023-06-08 23:56:57 +02:00
Corneil du Plessis
a54d602d5c [Update] Spring Boot to 3.1.0 2023-06-08 18:47:25 +02:00
abilan
5ecec94121 GH-275: Mention ComponentCustomizer in READMEs
Fixes https://github.com/spring-cloud/stream-applications/issues/275

Many functions make use of `ComponentCustomizer` ot let end-user
to provide any custom configuration for target component used by the function.
First of all for use-case which are not covered by standard configuration
properties and secondly for those options which cannot be represented
as a configuration option.

* Add a sentence to READMEs of those functions which make use of `ComponentCustomizer`
with an expected generic argument type
* Add README into `rabbit-supplier` where it is fully missed at the moment
2023-06-05 22:21:01 -04:00
Artem Bilan
745d270dde GH-441: Add JsonBytesToMap function (#461)
Add `JsonBytesToMap` function to allow conversion between byte[] and JSON Map.

Fixes https://github.com/spring-cloud/stream-applications/issues/441

* Introduce a `JsonBytesToMap` as a part of a `payload-converter-function` module
which is auto-discovered by Spring Cloud Function scanning algorithm - the `functions` package.
* Add a `payload-converter-function` as dependency into an `aggregator-function`
* Compose `jsonBytesToMap|aggregatorFunction` for the `aggregator-processor`
* Verify a `JsonBytesToMap` function in action with an `AggregatorProcessorTests`
* Mentioned such a payload conversion in the `aggregator-processor` README
2023-05-30 18:25:27 -05:00
GitHub Actions Bot
e52419e35b Next development version 4.0.0-SNAPSHOT 2023-05-25 11:30:37 +00:00
GitHub Actions Bot
17288d84b8 Release 4.0.0-M2 2023-05-25 11:30:19 +00:00
abilan
53d122fa15 Disable DefaultAggregatorTests 2023-05-02 17:12:36 -04:00
Corneil du Plessis
9adb9c9256 Fix header filter test. Improve aggregator-filter test configuration. 2023-04-06 12:21:08 +02:00
Corneil du Plessis
c02126911a Added logging to aggregator. 2023-02-14 16:59:41 +02:00
Corneil du Plessis
f0aed8d40a Remove assertion for list 2023-02-09 12:29:59 +02:00
Corneil du Plessis
f01e6383e5 Remove assertion for list 2023-02-09 11:39:33 +02:00
Corneil du Plessis
202de585ad Increase timeout for DefaultAggregatorTests 2023-02-07 21:40:28 +02:00
Corneil du Plessis
5b6ded7358 Added xmpp to the documentation.
Fixing remaining versions.

Updates #429
2023-02-02 18:51:01 +02:00
Corneil du Plessis
b5c9652946 Upodated aggregator RedisMessageStoreAggregatorTests to use RedisTestContainerSupport. 2023-01-11 16:20:14 +02:00
Corneil du Plessis
50bc4d3ad8 Added TODOs update versions. 2023-01-06 16:49:14 +02:00
Corneil du Plessis
7469320c91 [GitHub Actions] Improve dependencies for main. Provide for building impacted dependencies for a PR. 2022-11-07 15:56:07 +02:00
Artem Bilan
6cdc80c204 GH-373: Re-enable aggregator tests (#377)
Fixes https://github.com/spring-cloud/stream-applications/issues/373

The fix in Spring Integration has made it into the latest SNAPSHOT.
See more info in the linked issue

* Update to the latest Testcontainers: it does not require credential for pull command any more
* Remove obsolete `MessageStoreType.GEMFIRE`
* Add `<doclint>syntax</doclint>` to ignore missed javadocs on public methods
2022-10-19 14:09:32 -05:00
Chris Bono
ea800682b2 [SB3 Update] Agg function use MongoDB testcontainers
- Disable tests
2022-10-16 23:52:42 -05:00
Corneil du Plessis
c64b259d91 [SB3 Update] Remove Apache Geode (#345)
- Also update SFTP usage
2022-10-07 08:22:57 -05:00
Chris Bono
790daf0d91 Convert to Autoconfiguration.imports 2022-10-02 10:58:48 -05:00
Chris Bono
87df01dc00 Remove ${revision} from pom.xml files 2022-10-02 10:58:48 -05:00
Chris Bono
85106dd122 Initial support for SB3/SF6
- Main branch builds successfully (with tests skipped)

See #326
2022-09-22 17:46:11 -05:00
Artem Bilan
910f116332 GH-276 Apply ComponentCustomizer in other modules (#284)
* GH-276 Apply ComponentCustomizer in other modules

Fixes https://github.com/spring-cloud/stream-applications/issues/276

Some changes are straightforward as just a `ComponentCustomizer<?>`
injection and its optional usage for the target component customization.
Other changes are more drastic since it is better to use `proxyBeanMethods = false`,
so some direct bean method calls had to be reworked to the bean method argument
injections

* Fix some deprecations from Project Reactor
* Remove `UpdatingMongoDbMessageSource` since `MongoDbMessageSource`
supports now an `update` option in Spring Integration

NOTE: The `ZeroMqSupplierConfiguration` has its own customizer already
like `Consumer<ZMQ.Socket>`, so it can be revised to a more broader solution,
but in the future version.

Some modules just does not make sense to modify for more advance customization
since all their configuration is covered with plain configuration properties.
See `splitter-function` or `wavefront-consumer`

* * Use `ObjectProvider<WebClientCustomizer>` for `HttpRequestFunctionConfiguration`
instead of our own `ComponentCustomizer`.
Although this has to be revised in favor of fully auto-configured `WebClient.Builder`.
Even that `maximumBufferSize` is included into codecs configuration properties.
* The `MongoDbMessageSource` has now an `update` option in Spring Integration
therefore remove redundant already `UpdatingMongoDbMessageSource`
and populate `this.properties.getUpdateExpression()` directly ot the
`MongoDbMessageSource` bean
* Modify supplier configurations to avoid manual starts for endpoints on
reactive `Publisher` subscriptions.
Spring Integration provides now a `toReactivePublisher(true)` operator
to have all the endpoints stopped on start, but started automatically
when subscription happens to the provided `Publisher`
* Update Copyright to the current year for all the affected classes
* Use `@Nullable` instead of `ObjectProvider` in the `AggregatorFunctionConfiguration`
dependency injection for consistency
* Fix `LogConsumerConfiguration` to not have a `log()` in the end - it is not terminal
in Spring Integration anymore.
Use recommended `nullChannel()` terminating operator for use-cases like this.

* * Remove `beanName` from `ComponentCustomizer` contract

Co-authored-by: Chris Bono <cbono@vmware.com>
2022-07-15 19:36:21 -05:00
Chris Bono
50d75ef1e7 GH-271: Remove duplication from pom.xml files
This proposal fixes many build warnings and is a general cleanup of the pom.xml files.

* Remove duplicate `dependency` entries  from pom.xml files
* Remove duplicate `repository` entries from pom.xml files
* Replace deprecated use of `receive(long)` in `HttpSourceTests`
* Reduce logging for Twitter integration tests

Fixes #271
2022-05-26 13:57:44 -04:00
Artem Bilan
89cd8812c3 GH-195: Introduce ComponentCustomizer (#273)
Fixes #195 

* Introduce a `ComponentCustomizer` contract to be exposed in
the end-user configuration for particular bean type
* introduce a `@CustomizationAware` annotation to mark a component 
as customizable
* Introduce a `ComponentCustomizationBeanPostProcessor` as an auto-configured
bean to apply `ComponentCustomizer` to a matching `@CustomizationAware` (if any)
* Use `@CustomizationAware` in the `FileSupplierConfiguration`
and demonstrate `ComponentCustomizer` feature in its tests
* Move `config-common` to functions parent to make the mentioned auto-configuration
available for all the functions
* Remove some other duplicated dependencies from the affected poms
2022-05-24 20:55:11 -05:00
Chris Bono
77a63f39fd Polish "GH-248: Exclude Geode SSL config"
* Add comments in tests about geode ssl flag verification
2022-04-06 00:06:58 -05:00
Artem Bilan
10ac6a45cb GH-248: Exclude Geode SSL config
Fixes https://github.com/spring-cloud/stream-applications/issues/248

The Geode SSL auto-config is done via `SslAutoConfiguration.SslEnvironmentPostProcessor`
which cannot be excluded as an auto-config.

* Set `SslAutoConfiguration.SECURITY_SSL_ENVIRONMENT_POST_PROCESSOR_ENABLED_PROPERTY`
to `false` from the `ExcludeStoresAutoConfigurationEnvironmentPostProcessor`
when the store type is not Geode
2022-04-06 00:01:35 -05:00
Chris Bono
3af4e8cfe0 Upgrade Geode to support Spring Boot 2.6.3
* Fix Geode integration tests
* Upgrade spring-geode-starter -> 1.6.3
* Upgrade apachegeode/geode -> 1.14.3
* Upgrade spring-data-geode-test -> 0.0.28
2022-01-28 12:13:01 -05:00
Artem Bilan
361c0866b9 * Use spring.mongodb.embedded.version=3.5.5 - aligned with Spring Boot 2022-01-25 09:37:14 -05:00
Artem Bilan
de92924f66 Restore embedded MongoDb tests 2022-01-24 11:30:33 -05:00
Soby Chacko
db61080499 Temporarily disabling a few tests 2022-01-21 17:52:10 -05:00
Artem Bilan
e1987527cf Change doOnSubscribe to doOnRequest
The `aggregatorFunction` has a flaw subscribing and emitting
data from a source `Flux` too early: from a `doOnSubscribe()`
callback which is really called *before* the real subscription is
registered in the target `Publisher`

Change the logic to the `doOnRequest()` which happens already
after subscription is registered in the `Publisher`

**Cherry-pick to `2020.0.x`**
2022-01-20 18:34:21 -05:00
Artem Bilan
daebf0f786 Limit aggregator tests for 10 seconds to wait 2021-04-07 12:02:02 -04:00
Soby Chacko
d0a0df5a44 Restructuing with maven revision feature
Preserving the maven revision feature from the previous commit,
but perform a bit more restructuring the hierarchy.
2020-10-13 15:17:52 -04:00
Daniel Frey
724c4ace5f Refactor hardcoded versions in functions submodule branches
This is so they can be updated in a minimal amount of places and leverage the maven hierarchy to propagate them where appropriate.
While working with SNAPSHOT releases of Spring Boot, Spring Integration, and Spring Cloud, it required touching every pom.xml file
in order to reflect the use of the SNAPSHOT. After this change, it will only be required to change the property in the top
functions pom.xml and the versions will reflect to all submodules.

Maven introduced the ability use a key property, revision to propagate this information to the <parent> declarations in each pom.

This was enabled in Maven 3.5+
https://maven.apache.org/maven-ci-friendly.html
2020-10-13 15:15:59 -04:00
Soby Chacko
86f0ca0c07 Next version updates
Functions: 1.0.0-SNAPSHOT
  Core Apps: 3.0.0-SNAPSHOT
  Apps: 3.0.0-SNAPSHOT
  Aggregate Next:2020.0.0-SNAPSHOT
2020-09-29 18:28:20 -04:00
Soby Chacko
e1d29f8d24 Functions: Release - 1.0.0-M3 2020-09-29 14:59:33 -04:00
Artem Bilan
4463c1afb6 Add Aggregator function & processor
* Have all the required dependencies in class path which give us a `MessageGroupStore` implementation
* Disable all their auto-configurations in the `ExcludeStoresAutoConfigurationEnvironmentPostProcessor`
* Enable only those which are configured by the `aggregator.messageStoreType` property
* Implement a fully reactive function around an aggregator making an interaction via a pair of `FluxMessageChannel`
* Fix checkstyle issues
* Change the app generator maven plugin to new coordinates
2020-08-20 15:54:51 -04:00