Java did many things very right. It's a really fast language. It's memory safe. It could run anywhere. It had well-thought out namespacing at a time where namespacing was a concept most people barely knew they needed it. It had an advanced security model.
It was a very reasonable bet at the time imo.