/** {@inheritDoc} */ @Override public void attemptStarted(int attemptNumber) { currentAttemptId = attemptNumber; attemptSentMessages.set(0); attemptReceivedMessages = 0; HashMap<String, AttributeValue> attributes = new HashMap<>(); populateAttemptNumber(attributes); span.addAnnotation("Attempt started", attributes); }
/** {@inheritDoc} */ @Override public void attemptStarted(int attemptNumber) { currentAttemptId = attemptNumber; attemptSentMessages.set(0); attemptReceivedMessages = 0; HashMap<String, AttributeValue> attributes = new HashMap<>(); populateAttemptNumber(attributes); span.addAnnotation("Attempt started", attributes); }
private Map<String, AttributeValue> baseAttemptAttributes() { HashMap<String, AttributeValue> attributes = new HashMap<>(); populateAttemptNumber(attributes); long localAttemptSentMessages = attemptSentMessages.get(); if (localAttemptSentMessages > 0) { attributes.put( "attempt request count", AttributeValue.longAttributeValue(localAttemptSentMessages)); } if (attemptReceivedMessages > 0) { attributes.put( "attempt response count", AttributeValue.longAttributeValue(attemptReceivedMessages)); } return attributes; }
private Map<String, AttributeValue> baseAttemptAttributes() { HashMap<String, AttributeValue> attributes = new HashMap<>(); populateAttemptNumber(attributes); long localAttemptSentMessages = attemptSentMessages.get(); if (localAttemptSentMessages > 0) { attributes.put( "attempt request count", AttributeValue.longAttributeValue(localAttemptSentMessages)); } if (attemptReceivedMessages > 0) { attributes.put( "attempt response count", AttributeValue.longAttributeValue(attemptReceivedMessages)); } return attributes; }