spandex-project / spandex

A platform agnostic tracing library
MIT License
335 stars 53 forks source link

Remove plugs from Spandex core #81

Open GregMefford opened 6 years ago

GregMefford commented 6 years ago

See the Plug docs for details, but libraries aren't supposed to pollute the assigns on the Conn.

https://github.com/elixir-plug/plug/blob/master/lib/plug/conn.ex#L69 https://github.com/elixir-plug/plug/blob/master/lib/plug/conn.ex#L84-L89

zachdaniel commented 6 years ago

:+1:

zachdaniel commented 6 years ago

Thinking about it, we should probably move the plugs stuff over to spandex_phoenix or something. I know plugs are their own thing, but it probably fits more there than it does here.

GregMefford commented 6 years ago

Yeah I had the same thought, but at the time, we didn't have spandex_phoenix. Now that we do, I'd like to make a use Spandex.Phoenix type macro that will include the plugs automatically, but perhaps still have a way you could include them manually like you can today.

zachdaniel commented 5 years ago

I've updated this issue to represent more modern times. In our 3.0.0 release we should simply remove the plugs from core.

GregMefford commented 5 years ago

Agreed, which means we should go ahead and deprecate them now, in favor of the spandex_phoenix integration.

zachdaniel commented 5 years ago

Yeah, great plan. How do you deprecate a plug? Do we just deprecate the call or init function?