nickwongwong commented on a change in pull request #6729:
URL: https://github.com/apache/skywalking/pull/6729#discussion_r613744865
##########
File path:
apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/ids/GlobalIdGenerator.java
##########
@@ -74,11 +73,11 @@ private long timestamp() {
if (currentTimeMillis < lastTimestamp) {
// Just for considering time-shift-back by Ops or OS.
@hanahmily 's suggestion.
- if (runRandomTimestamp != currentTimeMillis) {
- lastRandomValue = ThreadLocalRandom.current().nextInt();
- runRandomTimestamp = currentTimeMillis;
+ if (lastShiftTimestamp != currentTimeMillis) {
+ lastShiftValue++;
Review comment:
我的理解没有问题吧?我看下面的的`nextThreadSeq++`也是没有问题
There is no problem with my understanding, right? I see the
`nextThreadSeq++` below is also no problem

--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]