LOG.debug("No redelivery of {} on rollback of {} due to failover of {}", md, ack.getTransactionId(), connection.getTransport()); return; LOG.debug("No local redelivery of {} on rollback of {} because consumer is no longer active on {}", md, ack.getTransactionId(), connection.getTransport()); return;
@Override public void onMessage(Message message) { String transport= ((ActiveMQConnection)((ActiveMQObjectMessage)message).getConnection()).getTransport().toString(); String text= ""; try { text = ((ActiveMQObjectMessage)message).getObject().toString(); } catch (JMSException e) { e.printStackTrace(); } if(Product.transportResult.containsKey(transport)){ Product.transportResult.get(transport).add(text); } else { List<String> productList=new ArrayList<>(); productList.add(text); Product.transportResult.put(transport,productList); } System.out.println("Consumer,productId:"+text+"transport:"+transport); } }
@Override public void onMessage(Message message) { String transport= ((ActiveMQConnection)((ActiveMQObjectMessage)message).getConnection()).getTransport().toString(); String text= ""; try { text = ((ActiveMQObjectMessage)message).getObject().toString(); } catch (JMSException e) { e.printStackTrace(); } if(Product.transportResult.containsKey(transport)){ Product.transportResult.get(transport).add(text); } else { List<String> productList=new ArrayList<>(); productList.add(text); Product.transportResult.put(transport,productList); } System.out.println("Consumer,productId:"+text+"transport:"+transport); } }
@Override @After public void tearDown() throws Exception { try { if (flowControlConnection != null) { TcpTransport t = flowControlConnection.getTransport().narrow(TcpTransport.class); try { flowControlConnection.getTransport().stop(); flowControlConnection.close(); } catch (Throwable ignored) { } } } finally { super.tearDown(); } }
@Override @After public void tearDown() throws Exception { try { if (flowControlConnection != null) { TcpTransport t = flowControlConnection.getTransport().narrow(TcpTransport.class); try { flowControlConnection.getTransport().stop(); flowControlConnection.close(); } catch (Throwable ignored) { // sometimes the disposed up can make the test to fail // even worse I have seen this breaking every single test after this // if not caught here } t.getTransportListener().onException(new IOException("Disposed.")); } if (asyncThread != null) { asyncThread.join(); asyncThread = null; } } finally { super.tearDown(); } }
LOG.debug("No redelivery of {} on rollback of {} due to failover of {}", md, ack.getTransactionId(), connection.getTransport()); return; LOG.debug("No local redelivery of {} on rollback of {} because consumer is no longer active on {}", md, ack.getTransactionId(), connection.getTransport()); return;
LOG.debug("No redelivery of {} on rollback of {} due to failover of {}", md, ack.getTransactionId(), connection.getTransport()); return; LOG.debug("No local redelivery of {} on rollback of {} because consumer is no longer active on {}", md, ack.getTransactionId(), connection.getTransport()); return;
LOG.debug("No redelivery of {} on rollback of {} due to failover of {}", md, ack.getTransactionId(), connection.getTransport()); return; LOG.debug("No local redelivery of {} on rollback of {} because consumer is no longer active on {}", md, ack.getTransactionId(), connection.getTransport()); return;