Nebo15 / logger_json

JSON logger formatter with support for Google Cloud, DataDog and other for Elixir.
https://nebo15.github.io/logger_json/
MIT License
237 stars 92 forks source link

The documentation refers to Ecto :loggers option, which is deprecated #47

Closed ryanhart2 closed 3 years ago

ryanhart2 commented 4 years ago

The documentation section shown below refers to the :loggers option, which was deprecated in Ecto v3.0.0, at the time that telemetry was introduced. It was replaced with a :log option. Per the docs the :log option provides the log level used when logging the query with Elixir's Logger. It defaults to :debug and, if false, disables logging for the repository. I think that the explanation of the :loggers option should be replaced with an explanation of the :log option. I can submit a PR if agreed that this should be changed.

config :my_app, MyApp.Repo,
 adapter: Ecto.Adapters.Postgres,
 ...
 loggers: [{LoggerJSON.Ecto, :log, [:info]}]
AndrewDryga commented 4 years ago

Hey, thank you for bringing this up, a PR would be welcome

AndrewDryga commented 3 years ago

It's fixed in master