By default SAS would be using its private JRE (<SASHome>/SASPrivateJavaRuntimeEnvironment), not the one that is run when you run "java" from the command line.
According to this page, 9.4 M6 included Java 8. Are you sure you are on version 9.4 M6 and not M5 or earlier?
https://support.sas.com/en/documentation/third-party-software-reference/9-4/support-for-java.htmlI believe upgrading the SAS Private JRE would involve upgrading your SAS deployment to a newer release.
The current release, 9.4 M8, ships with Java 11.
--
Greg Wootton | Principal Systems Technical Support Engineer