[Go] APM log not showing

Hi, I’m using this echo for http and uberzap for log. Using this lib for integration between echo and uberzap . But still logs is not sent to new relic.

Hi, @Endorsaja.id: Have you configured a log-forwarding plugin to send your logs to New Relic? Have you configured logs in context to associate your logs with your application transactions?

This post was flagged by the community and is temporarily hidden.

(post withdrawn by author, will be automatically deleted in 24 hours unless flagged)

Hi @philweber , i already configure logs in context. Im using go language, so im following docs from link. I also has verified that my go service already sent log to new relic(check from my service console). But still not showing on new relic UI logs

Check this link: https://onenr.io/0e1wZ1aBLQ6. Are these your logs?

yes, but thats infrastructure log. i thought thats APM log
So i already disabled it. For log in context still not working

They have an APM application name: see the query at the top? The Infrastructure agent is forwarding the logs, but I think they are coming from your application.

Anyway, I don’t know why logs in context is not working. I will flag your question for help from a support engineer.

Yeah, i purposely set the application name same as my APM(server-prod) but still not showing on APM. Then i just realize APM log and infrastructure is different. So i disable infrastructure log.
Although the infrastructure log source also come from my application, but i lose the feature log in context.
Thats why i move to use logs in context, but still not working. I dont know whats wrong.
Thanks @philweber for the help!!

Logs in context just adds metadata to your logs; you still need to configure something to send your logs to New Relic: Forward your logs to New Relic | New Relic Documentation.

aaa i see.
right now i already configure infrastructure log forwarder for server-dev and also have configure log in context. Still no logs show at my APM.

Hi @Endorsaja.id,

Thank you for the updates. A support engineer on the logs team will be taking a look at this. Please be on the lookout for updates on this thread. :slightly_smiling_face:

Hi @tpaul1 , Any updates?

@Endorsaja.id: New Relic is closed in the U.S. for the Thanksgiving holiday. Someone will respond to you as soon as possible.

1 Like

Oh sorry, i didn’t know that.
Happy Thanksgiving Day! for everyone :grinning: :partying_face:

1 Like

Hello @Endorsaja.id ,

You will need these 2 pieces of Documentation to get this sorted.

  1. Go Agent Troubleshooting Framework Logs in Context

  2. Go Agent Troubleshooting Framework Install

On a side note concerning the log lines which look awkward and short. This is because you need to review log parsing at the application. I would review regex and make sure any return characters /r are then escaped properly. logfmt seems to be the default parsing package on Logrus.

I would take a look at the Logrus Framework and Golang documentation on logfmt

I hope this helps.

Hi @cconde ,
Thanks for the guide, I already figured it out.
Turns out i need to manually integrate APM log in context link. Because im using log uberzap.
Thanks for the help