Skip to content
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

Don't catch or ignore Throwables #13

Merged
merged 1 commit into from
Dec 17, 2018

Conversation

juhoautio
Copy link
Contributor

@juhoautio juhoautio commented Dec 17, 2018

I had this error on my job:

java.lang.NoSuchMethodError: org.apache.flink.runtime.state.KeyedBackendSerializationProxy.<init>(Ljava/lang/ClassLoader;)V

I used debugger to find it. The error was silently ignored by StateMetadataUtils#getKeyedBackendSerializationProxy which returned Optional.empty() instead.

The exception that was eventually thrown was misleading and wrong:

Exception in thread "main" java.lang.IllegalStateException: Cannot read state of a stateless operator.
	at com.king.bravo.reader.OperatorStateReader.lambda$readKeyedStates$6(OperatorStateReader.java:101)
	at java.util.Optional.orElseThrow(Optional.java:290)
	at com.king.bravo.reader.OperatorStateReader.readKeyedStates(OperatorStateReader.java:101)

./gradlew test passed with these changes.

I had this error on my job:

	java.lang.NoSuchMethodError: org.apache.flink.runtime.state.KeyedBackendSerializationProxy.<init>(Ljava/lang/ClassLoader;)V

I used debugger to find it. The error was silently ignored by StateMetadataUtils#getKeyedBackendSerializationProxy which returned `Optional.empty()` instead.
Copy link
Contributor

@gyfora gyfora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense 👍

@gyfora gyfora merged commit 69b1e13 into king:master Dec 17, 2018
@juhoautio juhoautio deleted the dont_catch_Throwable branch December 17, 2018 14:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants