[
https://issues.apache.org/jira/browse/GOBBLIN-2218?focusedWorklogId=978728&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-978728
]
ASF GitHub Bot logged work on GOBBLIN-2218:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 13/Aug/25 13:24
Start Date: 13/Aug/25 13:24
Worklog Time Spent: 10m
Work Description: aga9900 commented on code in PR #4130:
URL: https://github.com/apache/gobblin/pull/4130#discussion_r2273464978
##########
gobblin-service/src/test/java/org/apache/gobblin/service/modules/scheduler/GobblinServiceJobSchedulerTest.java:
##########
@@ -120,6 +117,70 @@ public void testIsNextRunWithinRangeToSchedule() {
}
+ /**
+ * Test that demonstrates the NullPointerException issue in
GobblinServiceJob.executeImpl
+ * when getNextFireTime() returns null for a one-time scheduled flow.
+ */
+ @Test
+ public void testGobblinServiceJobExecuteImplWithNullNextFireTime()
+ throws Exception {
+ // Create a mock JobExecutionContext
+ org.quartz.JobExecutionContext mockContext =
mock(org.quartz.JobExecutionContext.class);
+ org.quartz.JobDetail mockJobDetail = mock(org.quartz.JobDetail.class);
+ org.quartz.JobDataMap mockJobDataMap = mock(org.quartz.JobDataMap.class);
+ org.quartz.Trigger mockTrigger = mock(org.quartz.Trigger.class);
+
+ // Mock the job detail and data map
+ when(mockContext.getJobDetail()).thenReturn(mockJobDetail);
+ when(mockContext.getTrigger()).thenReturn(mockTrigger);
+ when(mockJobDetail.getJobDataMap()).thenReturn(mockJobDataMap);
+ when(mockJobDetail.getKey()).thenReturn(new org.quartz.JobKey("testFlow",
"testGroup"));
+
+ // Mock the job data map contents
+ Properties jobProps = new Properties();
+ jobProps.setProperty(ConfigurationKeys.FLOW_NAME_KEY, "testFlow");
+ jobProps.setProperty(ConfigurationKeys.FLOW_GROUP_KEY, "testGroup");
+
jobProps.setProperty(ConfigurationKeys.ORCHESTRATOR_TRIGGER_EVENT_TIME_MILLIS_KEY,
"0");
Review Comment:
Updated
Issue Time Tracking
-------------------
Worklog Id: (was: 978728)
Time Spent: 50m (was: 40m)
> Handle single schedule jobs failures
> ------------------------------------
>
> Key: GOBBLIN-2218
> URL: https://issues.apache.org/jira/browse/GOBBLIN-2218
> Project: Apache Gobblin
> Issue Type: Task
> Reporter: Vaibhav Singhal
> Priority: Major
> Time Spent: 50m
> Remaining Estimate: 0h
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)