[server] fix npe in adaptive throttler code (#1456) #4047
Annotations
10 errors and 1 warning
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseAndBufferAfterLeaderTest.java#L1
Wanted but not invoked:
leaderFollowerStoreIngestionTask.reportError(
<any string>,
1,
<Capturing argument>
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.reportError(StoreIngestionTask.java:4299)
However, there were exactly 30 interactions with this mock:
leaderFollowerStoreIngestionTask.subscribePartition(
TestTopic_5bb2abe287_6302786c_v1-1
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTaskTest.runTest(StoreIngestionTaskTest.java:886)
leaderFollowerStoreIngestionTask.subscribePartition(
TestTopic_5bb2abe287_6302786c_v1-1,
true
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:626)
leaderFollowerStoreIngestionTask.throwIfNotRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:640)
leaderFollowerStoreIngestionTask.isRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.throwIfNotRunning(StoreIngestionTask.java:587)
leaderFollowerStoreIngestionTask.getIsRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.isRunning(StoreIngestionTask.java:4132)
leaderFollowerStoreIngestionTask.nextSeqNum();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:649)
leaderFollowerStoreIngestionTask.run();
-> at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
leaderFollowerStoreIngestionTask.isRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1639)
leaderFollowerStoreIngestionTask.getIsRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.isRunning(StoreIngestionTask.java:4132)
leaderFollowerStoreIngestionTask.updateIngestionRoleIfStoreChanged(
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1641)
leaderFollowerStoreIngestionTask.isHybridMode();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.updateIngestionRoleIfStoreChanged(StoreIngestionTask.java:1557)
leaderFollowerStoreIngestionTask.processConsumerActions(
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1642)
leaderFollowerStoreIngestionTask.processConsumerAction(
KafkaTaskMessage{type=SUBSCRIBE, topicPartition=TestTopic_5bb2abe287_6302786c_v1-1, attempts=2, sequenceNumber=1, createdTimestampInMs=1737147973197},
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerActions(StoreIngestionTask.java:1931)
leaderFollowerStoreIngestionTask.processCommonConsumerAction(
KafkaTaskMessage{type=SUBSCRIBE, topicPartition=TestTopic_5bb2abe287_6302786c_v1-1, attempts=2, sequenceNumber=1, createdTimestampInMs=1737147973197}
);
-> at com.linkedin.davinci.kafka.consumer.LeaderFollowerStoreIngestionTask.processConsumerAction(LeaderFollowerStoreIngestionTask.java:569)
leaderFollowerStoreIngestionTask.reportIfCatchUpVersionTopicOffset(
PCS{replicaId=TestTopic_5bb2abe287_6302786c_v1-1, hybrid=false, latestProcessedLocalVersionTopicOffset=-1, latestProcessedUpstreamVersionTopicOffset=-1, latestProcessedUpstreamRTOffsetMap={}, latestIgnoredUpstreamRTOffsetMap={}, latestRTOffsetTriedToProduceToVTMap{}, offsetRecord=OffsetRecord{localVersionTopicOffset=-1, upstreamOffset=-1, leaderTopic=null, offsetLag=0, eventTimeEpochMs=-1, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}, errorReported=false, started=false, lagCaughtUp=false, processedRecordSizeSinceLastSync=0, leaderFollowerState=STANDBY}
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processCommonConsumerAction(StoreIngestionTask.java:2176)
leaderFollowerStoreIngestionTask.updateLeaderTopicOnFollower(
PCS{replicaId=TestTopic_5bb2abe287_6302786c_v1-1, hybrid=false, latestProcessedLocalVersionTopicOffset=-1, latestProcessedUpstreamVersionTopicOffset=-1, latestPro
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseAndBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.TooFewActualInvocations:
hostLevelIngestionStats.recordTotalBytesConsumed(
<any long>
);
Wanted 2 times:
-> at com.linkedin.davinci.stats.HostLevelIngestionStats.recordTotalBytesConsumed(HostLevelIngestionStats.java:492)
But was 1 time:
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseWithoutBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.ArgumentsAreDifferent: Argument(s) are different! Wanted:
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=3, upstreamOffset=-1, leaderTopic=null, offsetLag=0, eventTimeEpochMs=-1, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=true, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTaskTest.lambda$testNotifier$35(StoreIngestionTaskTest.java:1623)
Actual invocations have different arguments:
storageMetadataService.getLastOffset(
"TestTopic_63e30fee2f_ee5ca351_v1",
1
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.getLastOffset(DeepCopyOffsetManager.java:49)
storageMetadataService.getLastOffset(
"TestTopic_63e30fee2f_ee5ca351_v1",
2
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.getLastOffset(DeepCopyOffsetManager.java:49)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@2108e5d5
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=1, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=2, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@38aba58d
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@19fe01ae
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=1, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=2, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@10c5f31
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=3, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, lat
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithTWiseWithoutBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.TooFewActualInvocations:
hostLevelIngestionStats.recordTotalBytesConsumed(
<any long>
);
Wanted 3 times:
-> at com.linkedin.davinci.stats.HostLevelIngestionStats.recordTotalBytesConsumed(HostLevelIngestionStats.java:492)
But was 2 times:
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/repository/NativeMetadataRepositoryTest.java#L133
java.lang.AssertionError: expected [2000.0] but found [1000.0]
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseAndBufferAfterLeaderTest.java#L1
Wanted but not invoked:
leaderFollowerStoreIngestionTask.reportError(
<any string>,
1,
<Capturing argument>
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.reportError(StoreIngestionTask.java:4299)
However, there were exactly 30 interactions with this mock:
leaderFollowerStoreIngestionTask.subscribePartition(
TestTopic_5bb2abe287_6302786c_v1-1
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTaskTest.runTest(StoreIngestionTaskTest.java:886)
leaderFollowerStoreIngestionTask.subscribePartition(
TestTopic_5bb2abe287_6302786c_v1-1,
true
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:626)
leaderFollowerStoreIngestionTask.throwIfNotRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:640)
leaderFollowerStoreIngestionTask.isRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.throwIfNotRunning(StoreIngestionTask.java:587)
leaderFollowerStoreIngestionTask.getIsRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.isRunning(StoreIngestionTask.java:4132)
leaderFollowerStoreIngestionTask.nextSeqNum();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.subscribePartition(StoreIngestionTask.java:649)
leaderFollowerStoreIngestionTask.run();
-> at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
leaderFollowerStoreIngestionTask.isRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1639)
leaderFollowerStoreIngestionTask.getIsRunning();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.isRunning(StoreIngestionTask.java:4132)
leaderFollowerStoreIngestionTask.updateIngestionRoleIfStoreChanged(
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1641)
leaderFollowerStoreIngestionTask.isHybridMode();
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.updateIngestionRoleIfStoreChanged(StoreIngestionTask.java:1557)
leaderFollowerStoreIngestionTask.processConsumerActions(
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.run(StoreIngestionTask.java:1642)
leaderFollowerStoreIngestionTask.processConsumerAction(
KafkaTaskMessage{type=SUBSCRIBE, topicPartition=TestTopic_5bb2abe287_6302786c_v1-1, attempts=2, sequenceNumber=1, createdTimestampInMs=1737147973197},
Mock for Store, hashCode: 1538641733
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerActions(StoreIngestionTask.java:1931)
leaderFollowerStoreIngestionTask.processCommonConsumerAction(
KafkaTaskMessage{type=SUBSCRIBE, topicPartition=TestTopic_5bb2abe287_6302786c_v1-1, attempts=2, sequenceNumber=1, createdTimestampInMs=1737147973197}
);
-> at com.linkedin.davinci.kafka.consumer.LeaderFollowerStoreIngestionTask.processConsumerAction(LeaderFollowerStoreIngestionTask.java:569)
leaderFollowerStoreIngestionTask.reportIfCatchUpVersionTopicOffset(
PCS{replicaId=TestTopic_5bb2abe287_6302786c_v1-1, hybrid=false, latestProcessedLocalVersionTopicOffset=-1, latestProcessedUpstreamVersionTopicOffset=-1, latestProcessedUpstreamRTOffsetMap={}, latestIgnoredUpstreamRTOffsetMap={}, latestRTOffsetTriedToProduceToVTMap{}, offsetRecord=OffsetRecord{localVersionTopicOffset=-1, upstreamOffset=-1, leaderTopic=null, offsetLag=0, eventTimeEpochMs=-1, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}, errorReported=false, started=false, lagCaughtUp=false, processedRecordSizeSinceLastSync=0, leaderFollowerState=STANDBY}
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processCommonConsumerAction(StoreIngestionTask.java:2176)
leaderFollowerStoreIngestionTask.updateLeaderTopicOnFollower(
PCS{replicaId=TestTopic_5bb2abe287_6302786c_v1-1, hybrid=false, latestProcessedLocalVersionTopicOffset=-1, latestProcessedUpstreamVersionTopicOffset=-1, latestPro
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseAndBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.TooFewActualInvocations:
hostLevelIngestionStats.recordTotalBytesConsumed(
<any long>
);
Wanted 2 times:
-> at com.linkedin.davinci.stats.HostLevelIngestionStats.recordTotalBytesConsumed(HostLevelIngestionStats.java:492)
But was 1 time:
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithPWiseWithoutBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.ArgumentsAreDifferent: Argument(s) are different! Wanted:
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=3, upstreamOffset=-1, leaderTopic=null, offsetLag=0, eventTimeEpochMs=-1, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=true, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTaskTest.lambda$testNotifier$35(StoreIngestionTaskTest.java:1623)
Actual invocations have different arguments:
storageMetadataService.getLastOffset(
"TestTopic_63e30fee2f_ee5ca351_v1",
1
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.getLastOffset(DeepCopyOffsetManager.java:49)
storageMetadataService.getLastOffset(
"TestTopic_63e30fee2f_ee5ca351_v1",
2
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.getLastOffset(DeepCopyOffsetManager.java:49)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@2108e5d5
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=1, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=2, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@38aba58d
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@19fe01ae
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=1, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
2,
OffsetRecord{localVersionTopicOffset=2, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, latestProducerProcessingTimeInMs=0, isEndOfPushReceived=false, databaseInfo={}, realTimeProducerState={}}
);
-> at com.linkedin.venice.offsets.DeepCopyOffsetManager.put(DeepCopyOffsetManager.java:38)
storageMetadataService.computeStoreVersionState(
"TestTopic_63e30fee2f_ee5ca351_v1",
com.linkedin.venice.offsets.DeepCopyStorageMetadataService$$Lambda$513/383774629@10c5f31
);
-> at com.linkedin.venice.offsets.DeepCopyStorageMetadataService.computeStoreVersionState(DeepCopyStorageMetadataService.java:33)
storageMetadataService.put(
"TestTopic_63e30fee2f_ee5ca351_v1",
1,
OffsetRecord{localVersionTopicOffset=3, upstreamOffset=-1, leaderTopic=null, offsetLag=9223372036854775807, eventTimeEpochMs=1737148008337, lat
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/kafka/consumer/SITWithTWiseWithoutBufferAfterLeaderTest.java#L1
org.mockito.exceptions.verification.TooFewActualInvocations:
hostLevelIngestionStats.recordTotalBytesConsumed(
<any long>
);
Wanted 3 times:
-> at com.linkedin.davinci.stats.HostLevelIngestionStats.recordTotalBytesConsumed(HostLevelIngestionStats.java:492)
But was 2 times:
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
-> at com.linkedin.davinci.kafka.consumer.StoreIngestionTask.processConsumerRecord(StoreIngestionTask.java:2606)
|
Publish Test Report:
clients/da-vinci-client/src/test/java/com/linkedin/davinci/repository/NativeMetadataRepositoryTest.java#L133
java.lang.AssertionError: expected [2000.0] but found [1000.0]
|
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
|
Loading