@Override public BeforeSentRemoteEvent create(final IValueDeserializer deserializer) throws RecordInstantiationException { return new BeforeSentRemoteEvent(deserializer); }
/** * {@inheritDoc} */ @Override public int hashCode() { int code = 0; code += ((int)this.getTimestamp()); code += ((int)this.getTraceId()); code += ((int)this.getOrderIndex()); code += this.getTechnology().hashCode(); return code; }
if (this.getLoggingTimestamp() != castedRecord.getLoggingTimestamp()) { return false; if (this.getTimestamp() != castedRecord.getTimestamp()) { return false; if (this.getTraceId() != castedRecord.getTraceId()) { return false; if (this.getOrderIndex() != castedRecord.getOrderIndex()) { return false; if (!this.getTechnology().equals(castedRecord.getTechnology())) { return false;
/** * After a request creation with a RestTemplate, we get the current traceId * and orderIndex and add them to the Http header of our message. Also, we * create a new BeforeSentEvent, which we pass to the MonitoringController. */ @AfterReturning(pointcut = "requestCreation()", returning = "request") public void doAfterRequestCreation(final ClientHttpRequest request) { final long traceId = TRACEREGISTRY.getTrace().getTraceId(); final int orderIndex = TRACEREGISTRY.getTrace().getNextOrderId(); final HttpHeaders headers = request.getHeaders(); headers.add(KIEKER_TRACE_ID_HEADER, Long.toString(traceId)); headers.add(KIEKER_ORDER_INDEX_HEADER, Integer.toString(orderIndex)); CTRLINST.newMonitoringRecord(new BeforeSentRemoteEvent(TIME.getTime(), traceId, orderIndex, TECHNOLOGY)); }
/** * {@inheritDoc} */ @Override public void serialize(final IValueSerializer serializer) throws BufferOverflowException { serializer.putLong(this.getTimestamp()); serializer.putLong(this.getTraceId()); serializer.putInt(this.getOrderIndex()); serializer.putString(this.getTechnology()); }