JayjeetAtGithub opened a new issue, #3416:
URL: https://github.com/apache/arrow-rs/issues/3416

   **Is your feature request related to a problem or challenge? Please describe 
what you are trying to do.**
   
   `arrow-json` needs to use RFC3339 style timestamps for timestamps with 
timezones as already done in `arrow-csv`. We intend to fix the upstream 
InfluxDB IOX bug https://github.com/influxdata/influxdb_iox/issues/2095.
   
   **Describe the solution you'd like**
   
   The 
[`array_value_to_string`](https://github.com/apache/arrow-rs/blob/master/arrow-cast/src/display.rs#L311)
 function (from `arrow-cast`) already supports RFC3339 style timestamps. We 
would use this function inside `arrow-json` to change to writing RFC3339 style 
timestamps while writing out record batches to JSON files. The 
`array_value_to_string` function will be modified a bit to print a trailing 
`Z`, when the timestamp is in UTC.
   
   **Describe alternatives you've considered**
   We could also implement a 
[handle_timestamp](https://github.com/apache/arrow-rs/blob/master/arrow-csv/src/writer.rs#L242)
 helper function as present in `arrow-csv` inside `arrow-json`, but that would 
be a duplication of code.
   
   **Additional context**
   We intend to use `array_value_to_string` across `arrow-csv`, `arrow-json`, 
and `arrow-pretty` for consistency in the RFC3339 timestamp implementation in 
the near future.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to