|
| 1 | +require('dotenv').config(); |
| 2 | +'use strict' |
| 3 | +/** |
| 4 | + * New Relic agent configuration. |
| 5 | + * |
| 6 | + * See lib/config/default.js in the agent distribution for a more complete |
| 7 | + * description of configuration variables and their potential values. |
| 8 | + */ |
| 9 | +exports.config = { |
| 10 | + /** |
| 11 | + * Array of application names. |
| 12 | + */ |
| 13 | + app_name: ['SDC-ListingInfo'], |
| 14 | + /** |
| 15 | + * Your New Relic license key. |
| 16 | + */ |
| 17 | + license_key: `${process.env.NEW_RELIC_KEY}`, |
| 18 | + /** |
| 19 | + * This setting controls distributed tracing. |
| 20 | + * Distributed tracing lets you see the path that a request takes through your |
| 21 | + * distributed system. Enabling distributed tracing changes the behavior of some |
| 22 | + * New Relic features, so carefully consult the transition guide before you enable |
| 23 | + * this feature: https://docs.newrelic.com/docs/transition-guide-distributed-tracing |
| 24 | + * Default is true. |
| 25 | + */ |
| 26 | + distributed_tracing: { |
| 27 | + /** |
| 28 | + * Enables/disables distributed tracing. |
| 29 | + * |
| 30 | + * @env NEW_RELIC_DISTRIBUTED_TRACING_ENABLED |
| 31 | + */ |
| 32 | + enabled: true |
| 33 | + }, |
| 34 | + logging: { |
| 35 | + /** |
| 36 | + * Level at which to log. 'trace' is most useful to New Relic when diagnosing |
| 37 | + * issues with the agent, 'info' and higher will impose the least overhead on |
| 38 | + * production applications. |
| 39 | + */ |
| 40 | + level: 'info' |
| 41 | + }, |
| 42 | + /** |
| 43 | + * When true, all request headers except for those listed in attributes.exclude |
| 44 | + * will be captured for all traces, unless otherwise specified in a destination's |
| 45 | + * attributes include/exclude lists. |
| 46 | + */ |
| 47 | + allow_all_headers: true, |
| 48 | + attributes: { |
| 49 | + /** |
| 50 | + * Prefix of attributes to exclude from all destinations. Allows * as wildcard |
| 51 | + * at end. |
| 52 | + * |
| 53 | + * NOTE: If excluding headers, they must be in camelCase form to be filtered. |
| 54 | + * |
| 55 | + * @env NEW_RELIC_ATTRIBUTES_EXCLUDE |
| 56 | + */ |
| 57 | + exclude: [ |
| 58 | + 'request.headers.cookie', |
| 59 | + 'request.headers.authorization', |
| 60 | + 'request.headers.proxyAuthorization', |
| 61 | + 'request.headers.setCookie*', |
| 62 | + 'request.headers.x*', |
| 63 | + 'response.headers.cookie', |
| 64 | + 'response.headers.authorization', |
| 65 | + 'response.headers.proxyAuthorization', |
| 66 | + 'response.headers.setCookie*', |
| 67 | + 'response.headers.x*' |
| 68 | + ] |
| 69 | + } |
| 70 | +} |
0 commit comments