Just to add for others finding this post: after you upgrade Java it doesn't mean your path environment variable was updated. Due to my work, I have 2-3 versions of java installed; though, I did set Java 8 install directory as my default for the environment variables CLASSPATH and JAVA_HOME. That was not enough however, since my PATH environment variable referenced an older version of java. Make sure the PATH environment variable is updated to remove ALL java paths except those for the new version.
You can find the variable by either:
1. Going to Start->Run (if enabled) and typing "systempropertiesadvanced" (enter). (you might be able to search this in Windows 8 easily as well)
-or-
2. Right-clicking on "Computer" or "My Computer", selecting "Properties", then selecting "Advanced system settings" on the left.
In either case you'll see the "Environment Variables..." button at the bottom right. The "Path" variable should be under "System Variables".
Notice: I've had some programs create a PATH variable specifically for me as a user (under "User variables for ..." which also messed things up for me in the past. You might be better off merging it with the System PATH instead, then deleting it.
Hope that helps someone.