Created
May 18, 2018 19:43
-
-
Save odedia/2a7547e15b446d91819c04ab6b1909c1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @RestController | |
| @Slf4j | |
| class BeerNamesController { | |
| @Output(Source.OUTPUT) | |
| @Autowired | |
| private MessageChannel messageChannel; | |
| @Autowired | |
| RestTemplate restTemplate; | |
| @PostMapping("/beer-me-up") | |
| public void write(@RequestBody BeerDTO beer){ | |
| log.info("Beer is {}", beer); | |
| this.messageChannel.send(MessageBuilder.withPayload(beer.getName()).build()); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment