GH-8642: Revise executors in the project (#8647)
* GH-8642: Revise executors in the project Fixes https://github.com/spring-projects/spring-integration/issues/8642 * Rework some `Executors.newSingleThreadExecutor()` to `ExecutorServiceAdapter(new SimpleAsyncTaskExecutor())` * Expose `TaskExecutor` setters; deprecate `ExecutorService`-based * Some other code clean up in the effected classes: `LogAccessor`, no `synchronized` in critical blocks * Give a meaningful prefix for default threads in the context of components, e.g. `SubscribableRedisChannel` - `getBeanName() + "-"` * * Fix `PostgresChannelMessageTableSubscriberTests` for `PostgresSubscribableChannel` initialization to let it create its internal `Executor` * Use an `AsyncTaskExecutor` injection instead of `ExecutorServiceAdapter` wrapping * Fix `LockRegistryLeaderInitiatorTests` for `taskExecutor` injection * Bring back `LockRegistryLeaderInitiator.setExecutorService()` as an accident after property auto-renaming
This commit is contained in:
@@ -124,6 +124,8 @@ public class PostgresChannelMessageTableSubscriberTests implements PostgresConta
|
||||
|
||||
this.postgresSubscribableChannel =
|
||||
new PostgresSubscribableChannel(messageStore, groupId, postgresChannelMessageTableSubscriber);
|
||||
this.postgresSubscribableChannel.setBeanName("testPostgresChannel");
|
||||
this.postgresSubscribableChannel.afterPropertiesSet();
|
||||
}
|
||||
|
||||
@AfterEach
|
||||
|
||||
Reference in New Issue
Block a user