Use Spring Cloud Stream 1.0.2.RELEASE for samples

- switch to RabbitMQ binder
This commit is contained in:
Marius Bogoevici
2016-06-15 09:46:14 -04:00
parent 597db957bf
commit 03e0a6b153
15 changed files with 84 additions and 90 deletions

View File

@@ -41,10 +41,9 @@ public class TimeSource {
@Autowired
private TimeSourceOptionsMetadata options;
@Bean
@InboundChannelAdapter(value = Source.OUTPUT, poller = @Poller(fixedDelay = "${fixedDelay}", maxMessagesPerPoll = "1"))
public MessageSource<String> timerMessageSource() {
return () -> new GenericMessage<>(new SimpleDateFormat(this.options.getFormat()).format(new Date()));
@InboundChannelAdapter(value = Source.OUTPUT)
public String timerMessageSource() {
return new SimpleDateFormat(this.options.getFormat()).format(new Date());
}
}