With a special thanks to Aleksandar and Unai, we're happy to announce AppSignal for Elixir 1.13.0, which includes our all-new LiveView instrumentation helpers and updated typespecs.
If you're not an AppSignal user yet, make sure to check out the product tour and see how errors, performance, host metrics and triggers all come together in one tool.
Using the LiveView Helpers
Phoenix LiveView renders HTML on the server and uses web sockets to push changes to the client in real-time. To gain insights into their performance, AppSignal for Elixir 1.13.0 ships with a LiveView helper to instrument those server sight actions.
A LiveView action is instrumented by wrapping its contents in a
Appsignal.Phoenix.LiveView.live_view_action/4
block.
Given a live view that updates its state every second, we can add
AppSignal instrumentation by wrapping both the mount/2 and handle_info/2
functions with a Appsignal.Phoenix.LiveView.live_view_action
/4 call:
Calling one of these functions in your app will now automatically create a
sample that's sent to AppSignal. These are displayed under the :live_view
namespace.
Typespecs and Behaviours
The Appsignal.Phoenix.Channel.channel_action/4
function has an updated
typespec in 1.13.0,
which prevents Dialyzer errors when using the @channel_action
decorator in
your apps.
Also, Unai added the
missing record_event
callback, in our TransactionBehaviour
, which fixes
issues when using the behaviour when mocking with Mox.
You can keep an eye on our changelog for incoming or past changes to our Elixir integration. And as always: get in touch if you have any questions, compliments, or encounter problems after upgrading. We're happy to help!