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

Compilation in src/main/java/com/amazon/redshift/util/StreamWrapper.java with latest versions of Java #86

Open
cushon opened this issue Apr 5, 2023 · 1 comment

Comments

@cushon
Copy link

cushon commented Apr 5, 2023

The following code doesn't compile with JDK 21 and newer:

protected void finalize() throws IOException {

It overrides finalize() in FileInputStream, which throws IOException. That override was removed in JDK 12: https://bugs.openjdk.org/browse/JDK-8192939

The compilation error with newer versions is:

com/amazon/redshift/util/StreamWrapper.java:120: error: unreported exception Throwable; must be caught or declared to be thrown
            super.finalize();
                          ^
@bhvkshah
Copy link
Contributor

bhvkshah commented May 5, 2023

Thanks for submitting this issue @cushon . I'll take a look and get back to you when I have an update

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

No branches or pull requests

2 participants