Java was perceived (quite rightfully) as a C++ with the rough edges filed off. It gained a ton of mindshare by making it trivial for C++ developers to jump on the bandwagon. This was critical because in terms of desktop development (that's how all apps were built in the 90s) and even on the server side C++ was the undisputed king of app development.