Hello Everyone.
I am trying to configure the APM to track as well the SQL transactions. I am looking to Built-in instrumentation modules | APM Go Agent Reference [2.x] | Elastic and this is my current test code
dsn := "user@pass(localhost:3306)/db?charset=utf8&parseTime=True&loc=Local"
db, err := apmsql.Open("mysql", dsn)
if err != nil {
returns.Error(w, http.StatusInternalServerError, err)
return
}
defer db.Close()
stmt, _ := db.Prepare("INSERT INTO user (name) values (value))
defer stmt.Close()
if _, err := stmt.Exec(); err != nil {
returns.Error(w, http.StatusInternalServerError, err)
return
}
The transaction is executed and a new row is created but I can not see the tracing of the queries in the APM UI in Kibana. Just for you know, I can see the HTTP transactions tracked.
Thank you!