Skip to content

Handle null JobSyncConfig #18969

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Nov 4, 2022
Merged

Conversation

jdpgrailsdev
Copy link
Contributor

@jdpgrailsdev jdpgrailsdev commented Nov 4, 2022

What

  • Reduce runtime errors that impact workflows

How

  • Handle case where the JobSyncConfig may be null when recording a job failure. Suspicion is that this happens for failed normalization jobs.

Addresses the following error:

java.lang.NullPointerException: Cannot invoke "io.airbyte.config.JobSyncConfig.getSourceDockerImage()" because "jobSyncConfig" is null
	at io.airbyte.workers.temporal.scheduling.activities.JobCreationAndStatusUpdateActivityImpl.jobFailure(JobCreationAndStatusUpdateActivityImpl.java:273)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
	at java.base/java.lang.reflect.Method.invoke(Method.java:578)
	at io.temporal.internal.activity.RootActivityInboundCallsInterceptor$POJOActivityInboundCallsInterceptor.executeActivity(RootActivityInboundCallsInterceptor.java:64)
	at io.temporal.internal.activity.RootActivityInboundCallsInterceptor.execute(RootActivityInboundCallsInterceptor.java:43)
	at io.temporal.internal.activity.ActivityTaskExecutors$BaseActivityTaskExecutor.execute(ActivityTaskExecutors.java:95)
	at io.temporal.internal.activity.ActivityTaskHandlerImpl.handle(ActivityTaskHandlerImpl.java:92)
	at io.temporal.internal.worker.ActivityWorker$TaskHandlerImpl.handleActivity(ActivityWorker.java:241)
	at io.temporal.internal.worker.ActivityWorker$TaskHandlerImpl.handle(ActivityWorker.java:206)
	at io.temporal.internal.worker.ActivityWorker$TaskHandlerImpl.handle(ActivityWorker.java:179)
	at io.temporal.internal.worker.PollTaskExecutor.lambda$process$0(PollTaskExecutor.java:93)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

Recommended reading order

  1. JobCreationAndStatusUpdateActivityImpl.java
  2. JobErrorReportingClient.java
  3. SentryJobErrorReportingClient.java

Tests

  • All tests pass
  • Project builds successfully

@github-actions github-actions bot added area/platform issues related to the platform area/worker Related to worker labels Nov 4, 2022
@benmoriceau
Copy link
Contributor

Nit: should we add a UTest?

@jdpgrailsdev
Copy link
Contributor Author

Nit: should we add a UTest?

@benmoriceau Probably, though I am not quite sure what the cause of this is yet. I'm hoping by fixing this we may see what is causing it. I can add a test to at least verify that the jobFailure method handles the null case.

@jdpgrailsdev jdpgrailsdev temporarily deployed to more-secrets November 4, 2022 15:04 Inactive
@jdpgrailsdev jdpgrailsdev temporarily deployed to more-secrets November 4, 2022 15:51 Inactive
@jdpgrailsdev jdpgrailsdev temporarily deployed to more-secrets November 4, 2022 15:57 Inactive
@jdpgrailsdev jdpgrailsdev temporarily deployed to more-secrets November 4, 2022 16:12 Inactive
@jdpgrailsdev jdpgrailsdev merged commit c8a7cb3 into master Nov 4, 2022
@jdpgrailsdev jdpgrailsdev deleted the jonathan/null-job-sync-config branch November 4, 2022 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/platform issues related to the platform area/worker Related to worker
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants