/** * create default ApplicationInfo * @return */ public static ApplicationInfoImpl createDefault() { return ApplicationInfoImpl.builder() .host(OSUtils.getHostName()) .application(AppInfo.getApplicationName()) .applicationVersion(AppInfo.getApplicationVersion()) .build(); } }
private void processMessageProperties(MessageProperties messageProperties) { messageProperties.setContentType(MessageProperties.CONTENT_TYPE_JSON); messageProperties.setContentEncoding("UTF-8"); messageProperties.setDeliveryMode(MessageDeliveryMode.NON_PERSISTENT); messageProperties.setHeader(MessageHeaders.HOST, OSUtils.getHostName()); messageProperties.setAppId(AppInfo.getApplicationName()); if(this.messagePropertiesCallback != null) { this.messagePropertiesCallback.call(messageProperties); } } }
final String applicationId = AppInfo.getApplicationName(); AmqpUtils.ExchangeFactory exchangeFactory = new AmqpUtils.ExchangeFactory(); exchangeFactory.setExchangeName(exchange);