axiomhq / next-axiom

The official Next.js library for Axiom.
https://axiom.co/vercel
MIT License
365 stars 29 forks source link

Getting occasional 404s for _axiom/web-vitals call on PROD #52

Closed jerang closed 1 year ago

jerang commented 2 years ago

Noticed my production dashboard is showing a small percentage of 404 errors for the web vitals call. Any idea what's causing this and how I can patch it? I do see the web vitals working since there are a number of successful calls for most users.

Secondly, is there a way to get this call to work locally?

bahlo commented 2 years ago

Hey @jerang, thanks for the issue -- it's something we're aware of and looking into 👍

Secondly, is there a way to get this call to work locally?

You can copy the NEXT_PUBLIC_AXIOM_INGEST_ENDPOINT from your environment and expose it locally.

agustinl commented 2 years ago

Hi @bahlo, to prevent create a duplicated issue, I'm seeing some requests to non-existents paths like /wordpress /wp /old /new /2020 etc.

This is something related to this issue?

Thanks!

dasfmi commented 2 years ago

Hi @bahlo, to prevent create a duplicated issue, I'm seeing some requests to non-existents paths like /wordpress /wp /old /new /2020 etc.

This is something related to this issue?

Thanks!

those are probably bots or web crawlers maybe trying to access those routes that don't exist on your app, I believe its not related to next-axiom.

bahlo commented 2 years ago

@jerang do you still see this happening?

jerang commented 2 years ago

I am still seeing it; pulled data using query:

vercel
| where ['vercel.route'] contains "axiom" and ['request.statusCode'] != 200
| summarize count() by bin_auto(_time), ['request.host'], ['request.path']

Post requests look correct to "https://vercel-vitals.axiom.co/api/v1/send"