I wanted to capture all the DML statements executed in the database information (execution time, ).
Question:
Can anyone point me pros and cons on either of the approaches.
In my testing, I haven't found any performance degrade on application operations when enabled the additional logging (below logging).
Besides log_min_duration_statement, you can use tools like pg_stat_statements [1] and POWA [2]. POWA authors even did a comparison of performance impact of having log_min_duration_statement (to latter process with pgBadger), using POWA extension and nothing, see [3].