Skip to content
Open
Changes from 7 commits
Commits
Show all changes
116 commits
Select commit Hold shift + click to select a range
717f173
Add URL path processing to Vercel logs configuration
swanson8r Jul 23, 2026
e6f7911
Set Log Status when http status code is absent
swanson8r Jul 23, 2026
113aca2
Remove Output Type Remapper
swanson8r Jul 23, 2026
e3ceaba
Add deploymentId remapper and update tags
swanson8r Jul 24, 2026
382271b
Update Log Pipeline, add Facets
swanson8r Aug 17, 2026
bc7b1b0
Merge branch 'DataDog:master' into master
swanson8r Aug 18, 2026
8121694
Correct status remapper definition
swanson8r Aug 18, 2026
50c9a5f
Restore missing `type` for `:string` facets
swanson8r Aug 18, 2026
0b0503b
Rename Vercel attributes with 'vercel.' prefix
swanson8r Aug 18, 2026
4ecf3c4
Simplify and correct remapped prefixes
swanson8r Aug 19, 2026
bff3f14
Apply facetType properly
swanson8r Aug 23, 2026
8a289c3
Merge branch 'master' into master
swanson8r Aug 23, 2026
5f38493
Remove Vercel log facets to test validation
swanson8r Aug 23, 2026
f88e772
Temporarily remove log metrics to test asset validation error for logs
swanson8r Aug 23, 2026
7222224
Remove attribute remappers for asset validation
swanson8r Aug 23, 2026
9b4997b
Update Facets per asset validator output
swanson8r Aug 23, 2026
f0915fc
Update expected test results for new pipeline processors
swanson8r Aug 23, 2026
1a5bb69
Add facets and remappers
swanson8r Aug 23, 2026
b4b1028
Scale back changes until asset vallidation tests stop swallowing errors
swanson8r Aug 23, 2026
cf41473
Remove all but one new vercel.remapper to test asset validation
swanson8r Aug 23, 2026
ecc9af8
Add Vercel Deployment Id Facet to logs configuration
swanson8r Aug 23, 2026
0e46227
Add more remappers and facets
swanson8r Aug 23, 2026
b43e586
Scale back attribute remappers and facets
swanson8r Aug 23, 2026
ea58fec
Remove Vercel Deployment Id from logs configuration
swanson8r Aug 23, 2026
9b14d37
Add environment field to vercel_tests.yaml
swanson8r Aug 23, 2026
a7f5a47
Change preserveSource to false in vercel.yaml
swanson8r Aug 23, 2026
15337bb
Restore DeploymentId and add InvocationId
swanson8r Aug 23, 2026
325925d
Update vercel_tests.yaml with facets and remapped attributes
swanson8r Aug 23, 2026
81f3966
Remove trailing blank lines in log config
swanson8r Aug 23, 2026
f9ca7f1
Remove second facet to test asset validator
swanson8r Aug 23, 2026
df3e08c
Remove trailing newline
swanson8r Aug 23, 2026
da3d87e
refer to vercel.deploymentId, remove other new remapped attribute to …
swanson8r Aug 23, 2026
fe45a5e
Remove deploymentId from vercel_tests.yaml
swanson8r Aug 23, 2026
8c14327
Remove Vercel Deployment Id facet from vercel.yaml
swanson8r Aug 23, 2026
9e720f2
Removed fields from vercel_tests.yaml
swanson8r Aug 23, 2026
6cdbb12
keep vercel.deploymentId after mapping to version tag
swanson8r Aug 23, 2026
6302e21
restore deploymentId in vercel_tests.yaml
swanson8r Aug 23, 2026
32e8231
Fix formatting of deploymentId in vercel_tests.yaml
swanson8r Aug 23, 2026
7ef4e46
Reorder attribute-remapper for deploymentId to test asset validator
swanson8r Aug 23, 2026
9dff663
Remove invocationId from vercel_tests.yaml
swanson8r Aug 23, 2026
4110a1e
Remove duplicate facet names
swanson8r Aug 23, 2026
db8a835
Add span_id to vercel_tests.yaml log entry
swanson8r Aug 23, 2026
eeb7715
Fix indentation in vercel.yaml for pipeline section
swanson8r Aug 23, 2026
d997de8
Fix indentation in vercel.yaml pipeline configuration
swanson8r Aug 23, 2026
c24669b
Fix indentation
swanson8r Aug 23, 2026
bbc1ba6
Remove vercel. custom remapper and facet
swanson8r Aug 23, 2026
72a3ce0
Remove deploymentId from Vercel logs test
swanson8r Aug 23, 2026
7d982e6
Remove URL facets from vercel.yaml
swanson8r Aug 24, 2026
fae4326
Add deploymentId to vercel_tests.yaml
swanson8r Aug 24, 2026
2a4ed94
indent nested pipeline using valid YAML
swanson8r Aug 24, 2026
d16980d
Applied validator facets
swanson8r Aug 24, 2026
d3ebd12
Add attribute remapper for vercel.deploymentId
swanson8r Aug 24, 2026
44f55c0
Add vercel.deploymentId to vercel_tests.yaml
swanson8r Aug 24, 2026
f0a0b09
Add Vercel Deployment Id to logs facet
swanson8r Aug 24, 2026
8a6f6ee
Add attribute remapper for environment mapping
swanson8r Aug 24, 2026
3636a67
Rename environment to vercel.environment in logs
swanson8r Aug 24, 2026
f3350cc
Add environment field to vercel_tests.yaml
swanson8r Aug 24, 2026
92487f6
Match returned timestamp
swanson8r Aug 24, 2026
db6b419
Add Vercel Deployment Environment facet
swanson8r Aug 24, 2026
5e40ef5
Add Vercel Project Id and Name to vercel.yaml
swanson8r Aug 24, 2026
d80e119
Update projectId and projectName in vercel_tests.yaml
swanson8r Aug 24, 2026
15ff22c
Add Vercel Invocation Id mapping to logs
swanson8r Aug 24, 2026
7bc40f9
Fix formatting in vercel_tests.yaml
swanson8r Aug 24, 2026
8ab185e
Update vercel.* attributes
swanson8r Aug 24, 2026
0c511a3
Add invocationId to vercel_tests.yaml
swanson8r Aug 24, 2026
dcd5583
do not retain original sources of vercel.* attributes
swanson8r Aug 24, 2026
e84fc8b
Remove blank lines
swanson8r Aug 24, 2026
e146b1c
Fix formatting of invocationId and timestamp
swanson8r Aug 24, 2026
802792f
Remove Vercel Deployment Environment facet from vercel.yaml
swanson8r Aug 24, 2026
5c039a9
remove references to vercel.environment
swanson8r Aug 24, 2026
5da5840
Remove vercel.environment field from vercel_tests.yaml
swanson8r Aug 24, 2026
7e56dec
Remove Vercel. Facets to prompt asset validator
swanson8r Aug 24, 2026
5446611
Remove invocationId from Vercel test logs
swanson8r Aug 24, 2026
ba7b0a6
Remove invocationId attribute remapper
swanson8r Aug 24, 2026
5130f35
Delete environment attribute remapper configuration
swanson8r Aug 24, 2026
a2ea71c
Remove 'environment' field and env tag from vercel_tests.yaml
swanson8r Aug 24, 2026
3ee778d
Restore span id and timestamp to original test values
swanson8r Aug 24, 2026
f1e0e73
reorder remappers to alphabetize names
swanson8r Aug 24, 2026
1e8a9b5
Update preserveSource and enable deploymentId attribute
swanson8r Aug 24, 2026
16f91c4
Remove version attribute remapper for deploymentId
swanson8r Aug 25, 2026
aa43937
Remove version tag from vercel_tests.yaml
swanson8r Aug 25, 2026
666ece6
Remove projectId attribute remapper
swanson8r Aug 25, 2026
c02dc98
Move projectId out Vercel and into custom log test
swanson8r Aug 25, 2026
fb52651
Remove projectName remapper and update log service name
swanson8r Aug 25, 2026
2bc59db
Fix formatting issues in vercel_tests.yaml
swanson8r Aug 25, 2026
4d44dc9
Add Vercel Deployment Id facet to logs configuration
swanson8r Aug 25, 2026
6fef7fd
Add Vercel Invocation Id to logs configuration
swanson8r Aug 25, 2026
2d9b20a
Add invocationId to vercel_tests.yaml logs
swanson8r Aug 25, 2026
5805c91
Add attribute remapper for deploymentId to version
swanson8r Aug 25, 2026
70e41cf
Add version tag to vercel_tests.yaml
swanson8r Aug 25, 2026
457ccd8
Change timestamp format in vercel_tests.yaml
swanson8r Aug 25, 2026
bef5058
Reorder tests to match error output, remove span_id
swanson8r Aug 26, 2026
bbddc1d
Normalize version tag casing in vercel_tests.yaml
swanson8r Aug 27, 2026
8e8f420
Enhance Vercel logs with deployment environment attributes
swanson8r Aug 27, 2026
79c635c
Add production environment details to vercel_tests.yaml
swanson8r Aug 27, 2026
d3ae6b3
Rename deploymentEnvironment to deploymentEnv
swanson8r Aug 27, 2026
7b2e7aa
reorder test outputs to match failed asset-validator suggestion
swanson8r Aug 27, 2026
2afa7ec
Add Vercel project details to logs configuration
swanson8r Aug 27, 2026
c1f4a91
Add projectId and Name to vercel assset testing, and service tag
swanson8r Aug 27, 2026
69b0bf2
Remove service tag from vercel_tests.yaml
swanson8r Aug 27, 2026
40fc41b
Add Vercel Request Duration and update status category mapper
swanson8r Aug 27, 2026
5e10251
move lambda duration to custom named attribute in vercel_tests.yaml
swanson8r Aug 27, 2026
38d5b0f
Update Vercel metrics configuration
swanson8r Aug 27, 2026
02bdb22
Change vercel.lambda.duration
swanson8r Aug 27, 2026
52eed54
Add duration to lambda execution metrics
swanson8r Aug 27, 2026
d4a090b
Remove vercel lambda duration from vercel_tests.yaml
swanson8r Aug 27, 2026
a955f2a
Remove vercel lambda duration mapping and update aggregation path
swanson8r Aug 27, 2026
1da6122
Add test_metrics to vercel_tests.yaml
swanson8r Aug 27, 2026
83a63e5
Merge branch 'master' into master
swanson8r Aug 27, 2026
52f43fb
Exclude error level logs with HTTP 200 from OK status
swanson8r Aug 28, 2026
d32dffe
Set preserveSource to true for vercel. attribute remappers
swanson8r Aug 31, 2026
c49cd03
restore preserved attributes to test results
swanson8r Aug 31, 2026
5aa2ed2
Apply suggested update to Error category mapper
swanson8r Aug 31, 2026
0baa1ae
Merge branch 'master' into master
swanson8r Aug 31, 2026
0e558fa
Replace '@requestId' with '@vercel.requestId'
swanson8r Sep 1, 2026
3f46b6e
restore httpStatus
swanson8r Sep 1, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
108 changes: 106 additions & 2 deletions vercel/assets/logs/vercel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,76 @@ facets:
name: Subdivision Name
path: network.client.geoip.subdivision.name
source: log
- groups:
- Vercel
name: Vercel Environment
path: environment
source: log
: string
- groups:
- Vercel
name: Vercel Deployment Id
path: deploymentId
source: log
: string
- groups:
- Vercel
name: Vercel Invocation Id
path: invocationId
source: log
: string
- groups:
- Vercel
name: Vercel Project Id
path: projectId
source: log
: string
- groups:
- Vercel
name: Vercel Project Name
path: projectName
source: log
type: string
- groups:
- Vercel
name: Vercel Request Duration
path: lambda.duration
source: log
type: integer
unit:
family: time
name: nanosecond
Comment thread
swanson8r marked this conversation as resolved.
Outdated
pipeline:
type: pipeline
name: Vercel
enabled: true
filter:
query: source:vercel
processors:
- type: pipeline
name: Processing for URL Paths
enabled: true
filter:
query: "@proxy.scheme:* @proxy.host:* @proxy.path:* NOT @source:build"
processors:
- type: string-builder-processor
name: Build a parseable http.url from proxy scheme, host, and path
enabled: true
template: '%{proxy.scheme}://%{proxy.host}%{proxy.path}'
target: http.url
replaceMissing: true
- type: url-parser
name: Parse http.url into http.url_details
enabled: true
sources:
- http.url
target: http.url_details
- type: url-parser
name: Parse proxy.referer into http.referer_details
enabled: true
sources:
- proxy.referer
target: http.referer_details
- type: grok-parser
name: Parsing Lambda Report Logs
enabled: true
Expand All @@ -64,17 +127,20 @@ pipeline:
name: Status Code Remapper
enabled: true
categories:
- filter:
query: '@type:stdout AND @source:build'
name: Info
Comment on lines +146 to +148

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Status Type @level @source count
      5,388.4k
info       5,374.5k
  stdout     5,374.5k
    info   5,374.5k
      build 5,345.4k
      lambda 29.1k
      edge 4
warn       13.8k
  stdout     13.8k
    info   13.8k
      build 11.9k
      lambda 1.9k

- filter:
query: '@proxy.statusCode:[200 TO 299]'
name: OK
Comment thread
swanson8r marked this conversation as resolved.
- filter:
query: '@proxy.statusCode:[300 TO 399]'
name: Notice
- filter:
query: '@proxy.statusCode:[400 TO 499]'
query: '@proxy.statusCode:[400 TO 499] OR (@type:stderr AND @source:build) OR message:*warn*'
Comment thread
swanson8r marked this conversation as resolved.
Outdated
name: Warning
Comment on lines 155 to 157

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Status Type @level @source count
        3,511.7k
warn       3,469.1k
  stderr     2,605.0k
    warning   1,784.3k
      lambda 1,784.3k
    info   482.3k
      build 482.3k
    warn   338.4k
      lambda 338.4k
    error   1
      lambda 1
  stdout     863.6k
    warning   863.6k
      lambda 863.6k
  N/A     429
    warning   429
      firewall 379
      lambda 50
error       42.7k
  stderr     42.7k
    warning   42.7k
      lambda 42.7k

- filter:
query: '@proxy.statusCode:[500 TO 599]'
query: '@proxy.statusCode:[500 TO 599] OR (@type:stderr AND NOT @source:build AND NOT message:*warn*)'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What led you to differentiate on build logs and exclude them from the Error category here?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Great question, one which can be addressed by adding another sample log to be tested.

Vercel Build logs do not contain an HTTP Status Code, so the next best option is to rely on the @type attribute.

On the downside, these logs are currently emitted one line at a time instead of in json format, which causes headaches when there are stack traces, and requires querying as Transactions in order to assemble as a single end-to-end build by @buildId

name: Error
target: http.status_category
- type: status-remapper
Expand All @@ -87,6 +153,26 @@ pipeline:
enabled: true
sources:
- projectName
- type: attribute-remapper
name: Define `deploymentId` as the official version of the log
enabled: true
sources:
- deploymentId
sourceType: attribute
target: version
targetType: tag
preserveSource: false
overrideOnConflict: false
- type: attribute-remapper
name: Define `environment` as the official env of the log
enabled: true
sources:
- environment
sourceType: attribute
target: env
targetType: tag
preserveSource: true
overrideOnConflict: false
- type: attribute-remapper
name: Map `host` to `url_host`
enabled: true
Expand Down Expand Up @@ -131,6 +217,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -158,6 +246,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -185,6 +275,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -215,6 +307,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -245,6 +339,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -275,6 +371,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand Down Expand Up @@ -305,6 +403,8 @@ metrics:
tagName: branch
- path: '@environment'
tagName: environment
- path: '@deploymentId'
tagName: deployment_id
- path: '@projectId'
tagName: project_id
- path: '@statusCode'
Expand All @@ -324,7 +424,11 @@ metrics:
- name: vercel.projects.build_count
query: source:vercel "Build completed in"
groupBys:
- path: '@environment'
tagName: environment
- path: '@projectName'
tagName: project_name
- path: '@projectId'
tagName: project_id
- path: '@deploymentId'
tagName: deployment_id
Loading