Advertisement
Guest User

Untitled

a guest
Jun 13th, 2018
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.66 KB | None | 0 0
  1. final Logger logger = LogManager.getLogger(ScheduledQueryRunnable.class);
  2.  
  3.     @Autowired
  4.     SendScheduledRequestService sendScheduledRequestService;
  5.  
  6.     public void run() {
  7.  
  8.         String endpointUri = this.getEndpoint().getUri();
  9.         byte[] body = new byte[0];
  10.         try {
  11.             body = this.getBody().getBytes(1, (int) this.getBody().length());
  12.         } catch (SQLException e) {
  13.             logger.error(e.getMessage());
  14.         }
  15.         String contentType = this.getContentType();
  16.         sendScheduledRequestService.sendSheduledRequest(endpointUri, body, contentType);
  17.         logger.info("сообщение отправлено");
  18.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement