[SPARK-4661][Core] Minor code and docs cleanup