Github user rxin commented on a diff in the pull request:
https://github.com/apache/spark/pull/14279#discussion_r75233535
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/csv/CSVOptions.scala
---
@@ -101,11 +102,9 @@ private[csv] class CSVOptions(@transient private val
parameters: Map[String, Str
name.map(CompressionCodecs.getCodecClassName)
}
- // Share date format object as it is expensive to parse date pattern.
- val dateFormat: SimpleDateFormat = {
- val dateFormat = parameters.get("dateFormat")
- dateFormat.map(new SimpleDateFormat(_)).orNull
- }
+ // Uses `FastDateFormat` which can be direct replacement for
`SimpleDateFormat` and thread-safe.
+ val dateFormat: FastDateFormat =
--- End diff --
ah ok - i misread it. this is good.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]