[SPARK-3599]Avoid loading properties file frequently

https://issues.apache.org/jira/browse/SPARK-3599