Conversation
|
Did I quick review and it looks good. Once thing I noticed is that the dep wasn't added to the 'rebar.config.script' file which TBH I don't remember what it was used for... What else could I do to make shackle more elixir friendly? mix config file and a shackle.ex file to expose the main APIs? |
|
Oh, I think the |
It's an interesting question! I haven't given it much thought because I haven't really been using shackle directly; I've been using buoy. I suspect I'd have a much clearer picture if I write a shackle client in Elixir. I think one big improvement might be having docs generated and uploaded to hexdocs, using an approach similar to EDIT: I found these instructions for releasing |
|
I got I think it would be pretty straightforward to move type definitions into the modules where they're used the most. |
|
I cleaned up a lot of the duplicated types in this branch (based on top of this PR branch). The resulting generated documentation is much cleaner, and linking back to definitions and whatnot is much nicer. |
|
With all respect to
|
|
@x0id Hey, I'll talk with @rkallos and discuss what we should do. I agree that this implementation is a bit slower because of the ETS calls. Moving forward I see two options:
|
|
Both are great options, but still, I prefer the first variant, because the second introduces an extra dependency on the telemetry. |
|
In #133, I removed telemetry as a dependency, and instead reintroduced shackle_hooks, but with a calling convention that is identical to telemetry's: This removes the overhead of the telemetry ETS table lookups, but for now, it does construct many small maps for the @x0id please let me know what you think of my proposed changes 😃 |
|
@rkallos, ideally I'd implement everything via macros. |
:telemetryseems to be picking up steam as the way forward for libraries to emit telemetry for applications. This largely replaces your use of?METRICScalls with matching calls to the newshackle_telemetrymodule.Also, a bunch of links in the docs got updated when I regenerated them. It might be worth looking into generating them with
rebar3_ex_docso they turn into pretty docs on hexdocs.pm.