From 806d1fa4ec4bb3f10301591e87ba2ab0ed07dd7a Mon Sep 17 00:00:00 2001 From: Zack Goodwin Date: Mon, 17 Jun 2024 16:59:52 -0400 Subject: [PATCH] PROC-1521: Call CED logging for payload experiments --- .../java/com/indeed/proctor/consumer/AbstractGroups.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/proctor-consumer/src/main/java/com/indeed/proctor/consumer/AbstractGroups.java b/proctor-consumer/src/main/java/com/indeed/proctor/consumer/AbstractGroups.java index 181c58ef..abaaeb8f 100644 --- a/proctor-consumer/src/main/java/com/indeed/proctor/consumer/AbstractGroups.java +++ b/proctor-consumer/src/main/java/com/indeed/proctor/consumer/AbstractGroups.java @@ -324,9 +324,12 @@ final TestBucket getTestBucketWithValue(final String testName, final int bucketV } public @Nullable JsonNode getProperty(final String propertyName) { - return Optional.ofNullable(proctorResult.getProperties().get(propertyName)) - .map(PayloadProperty::getValue) - .orElse(null); + final Optional payloadProperty = + Optional.ofNullable(proctorResult.getProperties().get(propertyName)); + + payloadProperty.ifPresent(p -> markTestUsed(p.getTestName())); + + return payloadProperty.map(PayloadProperty::getValue).orElse(null); } public @Nullable T getProperty(final String propertyName, final Class propertyClazz) {