-
Notifications
You must be signed in to change notification settings - Fork 871
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
CREATE DATABASE in console error on MacOs #8422
Comments
@luigidellaquila this is a showstopper! It seems this is JDK9 vs JDK8 incompatibility. Here are a few pointers on why it happens and how to fix it: https://stackoverflow.com/questions/48693695/java-nio-buffer-not-loading-clear-method-on-runtime |
@luigidellaquila , After clean build of 3.0.5-SNAPSHOT on my Mac with Java 8, here is what I see:
A couple of notes:
|
I figured out what was going on: On my Mac, I was using jEnv to switch between JDKs, and although Java 8 is my default environment, I was ending up compiling OrientDB with Java 10! In case someone else faces this issue, the fix is to use this command when building OrientDB (assuming Java 8 is your current or default configuration):
Note, the recommended way to work with Maven by jEnv, is to enable a Maven plug-in:
but I could not get it to work with the supplied |
OrientDB Version: 3.0.5-SNAPSHOT
Java Version: 1.8_172
OS: MacOs latest
The latest 3.0.5-SNAPSHOT produces the below strange error, which I only see on Mac, but not on Windows. Checking the JavaDocs for Java 8, I do see there is this method:
public final Buffer position(int newPosition)
but it returns Buffer, not ByteBuffer. In the child ByteBuffer class, there is no such method, which means it inherits it from Buffer.
That perhaps mean that some recent change to console code forcefully casts the return of the method to ByteBuffer, which fails on MacOs, but may works elsewhere (Windows/Linux) and compiles everywhere?
The text was updated successfully, but these errors were encountered: