Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use :channels namespace in Appsignal.Phoenix.Channel #197

Merged
merged 1 commit into from
Apr 11, 2017

Conversation

jeffkreeftmeijer
Copy link
Member

Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channels instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.

@@ -51,7 +51,7 @@ if Appsignal.phoenix? do
def channel_action(module, name, %Phoenix.Socket{} = socket, function) do
alias Appsignal.Transaction

transaction = Transaction.start(Transaction.generate_id(), :background_job)
transaction = Transaction.start(Transaction.generate_id(), :channels)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The namespace names are usually singular form, so we should probably keep that similar.
Since :channels (and :action_cable appsignal/appsignal-ruby#275) will be an internal namespace name (like :http_request and :background_job) we can change the display name for that in the UI

So that would become a mapping like so:

  • http_request => "Web"
  • background_job => "Background"
  • action_cable => "Action Cable" / "Channels"
  • channel => "Channels"

Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channel instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.
@jeffkreeftmeijer jeffkreeftmeijer merged commit d147958 into develop Apr 11, 2017
@tombruijn tombruijn deleted the channels-namespace branch April 11, 2017 07:17
jeffkreeftmeijer added a commit that referenced this pull request May 2, 2017
Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channel instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.
jeffkreeftmeijer added a commit that referenced this pull request May 10, 2017
* Use :channel namespace in Appsignal.Phoenix.Channel (#197)

Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channel instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.

* Parse new report from agent diagnose mode (#196)

* Parse new report from agent diagnose mode

The extension returns a JSON object, as a string, which contains the
agent diagnostics report.

The report definition is defined in the diagnose CLI task so we can
check all the tests and display them in a human readable format.

This change makes it possible to return the agent diagnostics report
without capturing the STDOUT while the agent is running. This proved
difficult to do in Elixir, where we previously called the agent
executable directly.

Instead of printing the report to STDOUT the extension will now return
the report as a JSON object, which is formatted as a string which needs
to be parsed into JSON first.

This report may be incomplete when the agent fails to start or something
else goes wrong. Any error will be captured and added to the agent
report.

* Give release upgrade test more time

* Test for agent diagnose report errors and output

* Test for fatal error in agent diagnose report

* Bump agent to da14f3b

- New diagnose report from agent (called through extension).
- Refactor internal extension worker

* Send diagnostics data report to AppSignal (#199)

This change will allow users to send the diagnostics report to
AppSignal. We'll ask before sending if the user wants this, but because
we see how useful this can be when debugging an issue it sends the
report by default. When you press enter, no input, "Y" (yes) is
submitted.

Why this change?
We've seen that in every support request we get we'll ask for the
diagnostics report. To make it easier for everyone this change allows
users to send it directly to AppSignal so our support team can review it
without valuable data getting lost by formatting by our support system
for example.

We also provide the user with a support token when they send the report.
This can be useful for a user if they see a problem with the output and
want to dive right in with the report. They can contact us with the
support token, after which we can immediately review the report.

* Backtrace.format_stacktrace handles lists of binaries
jeffkreeftmeijer added a commit that referenced this pull request May 10, 2017
* Use :channel namespace in Appsignal.Phoenix.Channel (#197)

Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channel instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.

* Parse new report from agent diagnose mode (#196)

* Parse new report from agent diagnose mode

The extension returns a JSON object, as a string, which contains the
agent diagnostics report.

The report definition is defined in the diagnose CLI task so we can
check all the tests and display them in a human readable format.

This change makes it possible to return the agent diagnostics report
without capturing the STDOUT while the agent is running. This proved
difficult to do in Elixir, where we previously called the agent
executable directly.

Instead of printing the report to STDOUT the extension will now return
the report as a JSON object, which is formatted as a string which needs
to be parsed into JSON first.

This report may be incomplete when the agent fails to start or something
else goes wrong. Any error will be captured and added to the agent
report.

* Give release upgrade test more time

* Test for agent diagnose report errors and output

* Test for fatal error in agent diagnose report

* Bump agent to da14f3b

- New diagnose report from agent (called through extension).
- Refactor internal extension worker

* Send diagnostics data report to AppSignal (#199)

This change will allow users to send the diagnostics report to
AppSignal. We'll ask before sending if the user wants this, but because
we see how useful this can be when debugging an issue it sends the
report by default. When you press enter, no input, "Y" (yes) is
submitted.

Why this change?
We've seen that in every support request we get we'll ask for the
diagnostics report. To make it easier for everyone this change allows
users to send it directly to AppSignal so our support team can review it
without valuable data getting lost by formatting by our support system
for example.

We also provide the user with a support token when they send the report.
This can be useful for a user if they see a problem with the output and
want to dive right in with the report. They can contact us with the
support token, after which we can immediately review the report.

* Explicitly assert stacktraces in ErrorMatcherTest

* Function clause errors use their nested stacktraces

* Only accept actual stacktraces in ErrorHandler.extract_stacktrace/1

* Use regexes to test stacktraces in ErrorMatcherTest
jeffkreeftmeijer added a commit that referenced this pull request Jun 22, 2017
Closes #194.

Instead of using the :background_job namespace,
Appsignal.Phoenix.Channel will use :channel instead. This also allows
users to set their own custom namespaces in
Appsignal.Transaction.start/2.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants