Fixed a lot of checkstyle warnings'
This commit is contained in:
@@ -31,6 +31,7 @@ public class SampleBackground {
|
||||
|
||||
@Autowired
|
||||
private Tracer tracer;
|
||||
|
||||
private Random random = new Random();
|
||||
|
||||
@Async
|
||||
|
||||
@@ -26,7 +26,7 @@ import org.springframework.integration.annotation.MessagingGateway;
|
||||
@MessagingGateway
|
||||
public interface SampleRequestResponse {
|
||||
|
||||
@Gateway(requestChannel="xform")
|
||||
@Gateway(requestChannel = "xform")
|
||||
String send(String input);
|
||||
|
||||
}
|
||||
|
||||
@@ -30,20 +30,27 @@ import org.springframework.web.client.RestTemplate;
|
||||
* @author Dave Syer
|
||||
*
|
||||
*/
|
||||
@MessageEndpoint public class SampleService implements
|
||||
ApplicationListener<ServletWebServerInitializedEvent> {
|
||||
@MessageEndpoint
|
||||
public class SampleService
|
||||
implements ApplicationListener<ServletWebServerInitializedEvent> {
|
||||
|
||||
private static final Log log = LogFactory.getLog(SampleService.class);
|
||||
|
||||
@Autowired private RestTemplate restTemplate;
|
||||
@Autowired
|
||||
private RestTemplate restTemplate;
|
||||
|
||||
private int port;
|
||||
|
||||
@ServiceActivator(inputChannel="messages")
|
||||
@ServiceActivator(inputChannel = "messages")
|
||||
public void log(Message<?> message) {
|
||||
log.info("Received: " + message);
|
||||
this.restTemplate.getForObject("http://localhost:" + this.port + "/foo", String.class);
|
||||
this.restTemplate.getForObject("http://localhost:" + this.port + "/foo",
|
||||
String.class);
|
||||
}
|
||||
|
||||
@Override public void onApplicationEvent(ServletWebServerInitializedEvent event) {
|
||||
@Override
|
||||
public void onApplicationEvent(ServletWebServerInitializedEvent event) {
|
||||
this.port = event.getSource().getPort();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@ import org.springframework.integration.annotation.MessagingGateway;
|
||||
@MessagingGateway
|
||||
public interface SampleSink {
|
||||
|
||||
@Gateway(requestChannel="messages")
|
||||
@Gateway(requestChannel = "messages")
|
||||
void send(String message);
|
||||
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ public class SampleTransformer {
|
||||
@Autowired
|
||||
SampleBackground background;
|
||||
|
||||
@ServiceActivator(inputChannel="xform")
|
||||
@ServiceActivator(inputChannel = "xform")
|
||||
public String log(Message<?> message) throws InterruptedException {
|
||||
log.info("Received: " + message);
|
||||
this.background.background();
|
||||
|
||||
Reference in New Issue
Block a user