Improve error reporting for Next.js app
Fixed
- Report errors in AppSignal for exception events in Next.js render spans.
This release can be installed through our collector packages and Docker image.
This release can be installed through our collector packages and Docker image.
min, max or sum values. Use the exemplars provided alongside the histogram to improve the accuracy of the histogram.Access-Control-Allow-Origin header value can be configured in the collector with the cors_origin config option or APPSIGNAL_CORS_ORIGIN environment variable.appsignal.config.request_headers and appsignal.config.response_headers configuration options can still be used for additional header filtering if needed. Consult your application's language OpenTelemetry SDK for the configuration option to record request and response headers.telemetry.sdk.language resource attribute if set. This attribute is set by the OpenTelemetry SDK for some languages, like Go, Java and PHP.
If your application's OpenTelemetry SDK sets the telemetry.sdk.language resource attribute, you will not need to set the appsignal.config.language_integration attribute.
If the appsignal.config.language_integration attribute is set, it will take precedence over the telemetry.sdk.language resource attribute.This release can be installed through our collector packages and Docker image.
Add an ignore_logs config option, which can be set using the appsignal.config.ignore_logs resource attribute. When this resource attribute is set, logs whose message matches any of the values in the ignore_logs list of values will be discarded.
The values on the ignore_logs configuration option support the ^, $ and .* meta-characters, with their expected meanings in regular expressions. When neither ^ or $ are specified at the beginning or ending of the value respectively, ignore_logs will match a log message if its value is present at any point in the message.
For example, to ignore logs starting with "success" or containing the word "OK", when setting the resource attributes in a Go application:
res := resource.NewWithAttributes( attribute.StringSlice("appsignal.config.ignore_logs", []string{"^success", "OK"}), // And other resource attributes )
The list of patterns can also be provided as a comma-separated string -- this is useful when using the OTEL_RESOURCE_ATTRIBUTES environment variable, such as in a PHP application:
function encode() { echo -n "$@" | sed 's/,/%2C/g' } export OTEL_RESOURCE_ATTRIBUTES="\ appsignal.config.ignore_errors=$(encode "^success,OK"),\ ..."
This release can be installed through our collector packages and Docker image.
When reporting a boolean resource attribute configuration option, such as send_function_parameters, send_request_payload, send_request_query_parameters and send_request_session_data, allow it to be provided as a string containing the case-insensitive values "true" or "false".
This makes it possible to set these configuration options using the OTEL_RESOURCE_ATTRIBUTES environment variable.
appsignal.namespace attribute.This release can be installed through our collector packages and Docker image.
Add ignore_errors option. Configure this option using the appsignal.config.ignore_errors resource attribute. The errors are matched by class/type.
The value can be set both as an array or a comma-separated string. The following examples are equivalent:
appsignal.config.ignore_errors=["RuntimeError", "NoMethodError"] appsignal.config.ignore_errors="RuntimeError,NoMethodError"
Allow log records with non-string values as bodies.
When a log record does not have a string as its body, but it has attributes, serialise those attributes as JSON and use that as the log message instead of the body.
When a log record has a key-value list as its body, use those key-value pairs as attributes.
Extract attributes in Laravel logs, encoded into the context attribute, into separate attributes that can be explored individually in AppSignal.
This release can be installed through our collector packages and Docker image.
/v1/logs endpoint in OTLP/HTTP format will be delivered to AppSignal's logging feature.<WorkerClass>#perform, e.g. MyWorker#perform.This release can be installed through our collector packages and Docker image.
The shutdown behavior on internal errors is improved, and now logs what crashed and why.
Limit appsignal.tag.<key> tag values to 256 characters.
Rename an internal span event attribute for metadata distributions. Older collectors will no longer report metadata distributions for error incidents.
This will create new incidents for existing errors. This is intentional.
This release can be installed through our collector packages and Docker image.
Configure AppSignal via HTTP request headers on export requests. If it's not possible to configure resource attributes in OpenTelemetry export data, configure AppSignal via request headers set on the export requests made to the collector's HTTP endpoints.
Supported headers are:
AppSignal-Config-Name: app name (required) AppSignal-Config-Environment: app environment (required) AppSignal-Config-PushApiKey: push API key (required) AppSignal-Config-Revision: app revision (required) AppSignal-Config-LanguageIntegration: language integration like ruby, elixir, php, etc. (required) OpenTelemetry-ServiceName: service name of the app OpenTelemetry-HostName: name of the app's host (required)
For more information, see our configuration documentation.
This release can be installed through our collector packages and Docker image.
appsignal.config.otp_app resource attribute config option. When set for Elixir applications, we will use the OTP app name to detect which stacktrace lines originate from the app, and which lines are from dependencies.Consider empty environment variables as unset. From now on, an environment variable that's set to an empty string is considered unset when reading the collector configuration from system environment variables.
In the example below, the environment variable will be considered unset. It will not fail on parsing an empty string as a number and set the default HTTP port instead.
APPSIGNAL_HTTP_PORT=""
This behavior is changed for the following config options:
APPSIGNAL_CPU_COUNTAPPSIGNAL_ENABLE_HOST_METRICSAPPSIGNAL_FILES_WORLD_ACCESSIBLEAPPSIGNAL_HOSTNAMEAPPSIGNAL_HTTP_PORTAPPSIGNAL_LOG_LEVELAPPSIGNAL_PUSH_API_ENDPOINTAPPSIGNAL_PUSH_API_KEYAPPSIGNAL_RUNNING_IN_CONTAINERIn the appsignal/collector Docker image we will now listen to the PORT environment variable if it's set, and use it to configure the HTTP server's port.
If the APPSIGNAL_HTTP_PORT environment variable is also set in addition to the PORT environment variable, it will read from the APPSIGNAL_HTTP_PORT environment variable.
This release can be installed through our collector packages and Docker image.
Content-Encoding header.This release can be installed through our collector packages and Docker image.
This release can be installed through our collector packages and Docker image.
Filter query parameters in the url.query span attribute. When an url.query attribute contains an URL encoded query parameter we will filter out the keys configured in the appsignal.config.filter_request_query_parameters resource attribute.
In the situation that a url.query span attribute has the value password=secret&some_param=some_value, and the appsignal.config.filter_request_query_parameters resource attribute is configured with ["password"], the url.query span attribute will be stored as password=[FILTERED]&some_param=some_value.
If no appsignal.request.query_parameters span attribute is set, we will store the query parameters as a JSON map on this attribute. For example:
{ "password": "[FILTERED]", "some_param": "some_value" }
Rename the working_dir_path config option to working_directory_path. This names matches with the naming in our other tools and integrations.
This is a breaking change: With this change the working_dir_path config option will no longer work.
When the appsignal.config.send_request_query_parameters resource attribute config option value is set to false, we will remove the url.query span attribute from spans.
This release can be installed through our collector packages and Docker image.
db.query.text attribute and Redis queries in the db.operation.name attribute.This release can be installed through our collector packages and Docker image.
Add the appsignal.config.app_path resource attribute config option. In the future this will be used to sanitize backtrace/stacktrace lines and detect which lines originate from the instrumented app and which lines originate from frameworks/libraries/dependencies/etc.
Add the hostname config option to allow customization of the hostname reported with the host metrics. By default, it will try to determine the hostname from the host itself. On Heroku it will read from the DYNO environment variable.
Add CPU count cpu_count config option. Use it to override the auto-detected, cgroups-provided, number of CPUs that is used to calculate CPU usage percentages.
To set it, use the APPSIGNAL_CPU_COUNT environment variable or the cpu_count configuration option in the configuration file.
# /etc/appsignal-collector.conf # These value formats are supported: cpu_count = 1 cpu_count = 2.5 cpu_count = 4
Collect host metrics from the machine where the collector is running. This is disabled by default when the collector is running in a container. If it's not, it's enabled by default.
Use the APPSIGNAL_ENABLE_HOST_METRICS env var or enable_host_metrics option to true to enable it and to false to disable it. If this config option is set, it overrides the defaults.
Add resource attributes for config options to not send request query parameters, request session data and function parameters at all. If these options are set to false, their respective metadata attributes are removed from the span attributes.
appsignal.config.send_request_query_parameters: default is true, if set to false, the appsignal.request.query_parameters attribute is removed.appsignal.config.send_request_payload: default is true, if set to false, the appsignal.request.payload attribute is removed.appsignal.config.send_request_session_data: default is true, if set to false, the appsignal.request.session_data attribute is removed.appsignal.config.send_function_parameters: default is true, if set to false, the appsignal.function.parameters attribute is removed.These options are for when the deny list appsignal.config.filter_<type> options are not enough and all data needs to be removed.
Add the running_in_container config option. Use it to override the automatic detection of containers. This determines the method of reading host metrics. Only set this when the reported host metrics seem wrong.
To set it, use the APPSIGNAL_RUNNING_IN_CONTAINER environment variable or the running_in_container configuration option in the configuration file.
# These value formats are supported: export APPSIGNAL_RUNNING_IN_CONTAINER="true" export APPSIGNAL_RUNNING_IN_CONTAINER="false"
# /etc/appsignal-collector.conf # These value formats are supported: running_in_container = true running_in_container = false
Add a resource attribute for a config option to filter function parameters. Configure the appsignal.config.filter_function_parameters resource attribute deny list in OpenTelemetry with a list function parameter keys to filter out. The parameters are recursively filtered, so any nested objects will also be filtered.
With this config:
appsignal.config.filter_function_parameters = ["email", "secret"]
The function parameters, set in the appsignal.function.parameters span attribute, are filtered. The appsignal.function.parameters span attribute value needs to be a valid JSON object for it to be filtered.
Add a resource attribute for a config option to filter request query parameters. Configure the appsignal.config.filter_request_query_parameters resource attribute deny list in OpenTelemetry with a list request query parameter keys to filter out. The parameters are recursively filtered, so any nested objects will also be filtered.
With this config:
appsignal.config.filter_request_query_parameters = ["password", "secret"]
The request query parameters, set in the appsignal.request.query_parameters span attribute, are filtered. The appsignal.request.query_parameters span attribute value needs to be a valid JSON object for it to be filtered.
Add a resource attribute for a config option to filter request headers. Configure the appsignal.config.request_headers resource attribute allow list in OpenTelemetry to a list of header names to keep. All other headers are removed.
# Given this config: appsignal.config.request_headers = ["accept", "date"] # Results in these headers as span attributes to be stored on the span http.request.header.accept http.request.header.date
By default the headers listed below are included. Setting the appsignal.config.request_headers resource attribute overrides this default. If you want to include them, you need to list them again. To include no headers, set the resource attribute value to an empty array.
Add a resource attribute for a config option to filter request payloads. Configure the appsignal.config.filter_request_payload resource attribute deny list in OpenTelemetry with a list request payload keys to filter out. The parameters are recursively filtered, so any nested objects will also be filtered.
With this config:
appsignal.config.filter_request_payload = ["password", "secret"]
The request payload, set in the appsignal.request.payload span attribute, are filtered. The appsignal.request.payload span attribute value needs to be a valid JSON object for it to be filtered.
Add a resource attribute for a config option to filter response headers. Configure the appsignal.config.response_headers resource attribute allow list in OpenTelemetry to a list of header names to keep. All other headers stored by HTTP client instrumentations are removed.
# Given this config: appsignal.config.request_headers = ["accept", "date"] # Results in these headers as span attributes to be stored on the span http.request.header.accept http.request.header.date
By default the headers listed below are included. Setting the appsignal.config.response_headers resource attribute overrides this default. If you want to include them, you need to list them again. To include no headers, set the resource attribute value to an empty array.
Add a resource attribute for a config option to filter request session data. Configure the appsignal.config.filter_request_session_data resource attribute deny list in OpenTelemetry with a list request session data keys to filter out. The session data is recursively filtered, so any nested objects will also be filtered.
With this config:
appsignal.config.filter_request_session_data = ["token", "secret"]
The request session data, set in the appsignal.request.session_data span attribute, are filtered. The appsignal.request.session_data span attribute value needs to be a valid JSON object for it to be filtered.
This release can be installed through our collector packages and Docker image.
0.0.0.0:8099/v1/metrics endpoint. The following metric types are supported: Gauge, Sum and Histogram. Configure your OpenTelemetry SDK to export to this application to track OpenTelemetry metrics in AppSignal.This release can be installed through our collector packages and Docker image.
AppSignal offers a 30-day free trial, no credit card is required. All features are available in all plans. Start monitoring your application in just a few clicks!