From 34cda5b6067d3d1ae7dafed277268302af0571b6 Mon Sep 17 00:00:00 2001 From: Lily Wittle Date: Mon, 2 Feb 2026 21:05:41 -0500 Subject: [PATCH] Prevent false session state failure Specifically, prevent early session failure in the case that the session key value is blank and the session fail condition is undefined. This will allow the session to continue polling. --- .../com/linkedin/cdi/extractor/MultistageExtractor.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cdi-core/src/main/java/com/linkedin/cdi/extractor/MultistageExtractor.java b/cdi-core/src/main/java/com/linkedin/cdi/extractor/MultistageExtractor.java index 32ded77..71217c0 100644 --- a/cdi-core/src/main/java/com/linkedin/cdi/extractor/MultistageExtractor.java +++ b/cdi-core/src/main/java/com/linkedin/cdi/extractor/MultistageExtractor.java @@ -723,14 +723,14 @@ protected boolean isSessionStateMatch() { } /** - * Check if session state is enabled and session fail condition is met + * Check if session state is enabled with a session fail condition defined, and the fail condition is met * - * @return true if session state is enabled and session fail condition is met + * @return true if session state is enabled with a session fail condition defined, and the fail condition is met * otherwise return false */ protected boolean isSessionStateFailed() { - return jobKeys.isSessionStateEnabled() && extractorKeys.getSessionKeyValue() - .matches(jobKeys.getSessionStateFailCondition()); + return jobKeys.isSessionStateEnabled() && StringUtils.isNotBlank(jobKeys.getSessionStateFailCondition()) + && extractorKeys.getSessionKeyValue().matches(jobKeys.getSessionStateFailCondition()); } /**