I've run into this problem before, for me, it happens when I have multiple version's of java (like jdk10 and jdk8).
The source should be in your jdk8 folder.
So, what I do is change the workspace jdk to the one in the folder.
Btw sorry for the images being so big... I don't know how to change the size of them
Go to the Properties of the JRE System Library
Then go to Installed JREs... (btw it says jre-10.0.2 for example)
I use "duplicate", but "edit" is an option
Now click "directory", and find your java jdk8
DO NOT SELECT THE "BIN" FOLDER,
Finally, name it something and check it for that workspace
Don't forget to set it as your jre/jdk.
That should work, as for your other problem. It's way over my head.
If it didn't fix it, sorry for wasting your time.