@Test public void traceIdShouldBeThirtyTwoCharactersAndLowerCase() { String traceId = Transaction.buildTraceId(System.currentTimeMillis()); assertThat(traceId).hasSize(32); assertThat(traceId.toLowerCase()).isEqualTo(traceId); }
@VisibleForTesting static String buildTraceId(long startTime) { byte[] bytes = new byte[10]; random.nextBytes(bytes); return lowerSixBytesHex(startTime) + BaseEncoding.base16().lowerCase().encode(bytes); }
Transaction { @VisibleForTesting static String buildTraceId(long startTime) { byte[] bytes = new byte[10]; random.nextBytes(bytes); return lowerSixBytesHex(startTime) + BaseEncoding.base16().lowerCase().encode(bytes); } }
Transaction { @VisibleForTesting static String buildTraceId(long startTime) { byte[] bytes = new byte[10]; random.nextBytes(bytes); return lowerSixBytesHex(startTime) + BaseEncoding.base16().lowerCase().encode(bytes); } Transaction(long startTime, long startTick, String transactionType, String transactionName,
            MessageSupplier messageSupplier, TimerName timerName, boolean captureThreadStats,
            int maxTraceEntries, int maxQueryAggregates, int maxServiceCallAggregates,
            int maxProfileSamples, @Nullable ThreadAllocatedBytes threadAllocatedBytes,
            CompletionCallback completionCallback, Ticker ticker,
            TransactionRegistry transactionRegistry, TransactionService transactionService,
            ConfigService configService, UserProfileScheduler userProfileScheduler,
            ThreadContextThreadLocal.Holder threadContextHolder); }
Transaction { @VisibleForTesting static String buildTraceId(long startTime) { byte[] bytes = new byte[10]; random.nextBytes(bytes); return lowerSixBytesHex(startTime) + BaseEncoding.base16().lowerCase().encode(bytes); } Transaction(long startTime, long startTick, String transactionType, String transactionName,
            MessageSupplier messageSupplier, TimerName timerName, boolean captureThreadStats,
            int maxTraceEntries, int maxQueryAggregates, int maxServiceCallAggregates,
            int maxProfileSamples, @Nullable ThreadAllocatedBytes threadAllocatedBytes,
            CompletionCallback completionCallback, Ticker ticker,
            TransactionRegistry transactionRegistry, TransactionService transactionService,
            ConfigService configService, UserProfileScheduler userProfileScheduler,
            ThreadContextThreadLocal.Holder threadContextHolder); String getTraceId(); long getStartTick(); boolean isCompleted(); long getDurationNanos(); String getTransactionType(); String getTransactionName(); String getHeadline(); String getUser(); SetMultimap<String, String> getAttributes(); @Nullable ErrorMessage getErrorMessage(); long getTotalCpuNanos(); List<Aggregate.Query> getQueries(); List<String> getSharedQueryTexts(); void visitEntries(long captureTick, EntryVisitor entryVisitor); @Nullable Profile getMainThreadProfileProtobuf(); @Nullable Profile getAuxThreadProfileProtobuf(); @Nullable Cancellable getImmedateTraceStoreRunnable(); boolean isPartiallyStored(); ThreadContextImpl getMainThreadContext(); List<ThreadContextImpl> getActiveAuxThreadContexts(); void setImmediateTraceStoreRunnable(Cancellable immedateTraceStoreRunnable); }
Transaction { @VisibleForTesting static String buildTraceId(long startTime) { byte[] bytes = new byte[10]; random.nextBytes(bytes); return lowerSixBytesHex(startTime) + BaseEncoding.base16().lowerCase().encode(bytes); } Transaction(long startTime, long startTick, String transactionType, String transactionName,
            MessageSupplier messageSupplier, TimerName timerName, boolean captureThreadStats,
            int maxTraceEntries, int maxQueryAggregates, int maxServiceCallAggregates,
            int maxProfileSamples, @Nullable ThreadAllocatedBytes threadAllocatedBytes,
            CompletionCallback completionCallback, Ticker ticker,
            TransactionRegistry transactionRegistry, TransactionService transactionService,
            ConfigService configService, UserProfileScheduler userProfileScheduler,
            ThreadContextThreadLocal.Holder threadContextHolder); String getTraceId(); long getStartTick(); boolean isCompleted(); long getDurationNanos(); String getTransactionType(); String getTransactionName(); String getHeadline(); String getUser(); SetMultimap<String, String> getAttributes(); @Nullable ErrorMessage getErrorMessage(); long getTotalCpuNanos(); List<Aggregate.Query> getQueries(); List<String> getSharedQueryTexts(); void visitEntries(long captureTick, EntryVisitor entryVisitor); @Nullable Profile getMainThreadProfileProtobuf(); @Nullable Profile getAuxThreadProfileProtobuf(); @Nullable Cancellable getImmedateTraceStoreRunnable(); boolean isPartiallyStored(); ThreadContextImpl getMainThreadContext(); List<ThreadContextImpl> getActiveAuxThreadContexts(); void setImmediateTraceStoreRunnable(Cancellable immedateTraceStoreRunnable);  }