Kibana version : 7.3.2
Elasticsearch version : 7.3.2
APM Server version : 7.3.2
APM Agent language and version : 4.2.2
Browser version : 77.0.3865.90
Original install method (e.g. download page, yum, deb, from source, etc.) and version : cannot recall
Fresh install or upgraded from other version? 7.1.1
Is there anything special in your setup? For example, are you using the Logstash or Kafka outputs? Are you using a load balancer in front of the APM Servers? Have you changed the index pattern, generated custom templates, changed agent configuration etc.
No
Description of the problem including expected versus actual behavior. Please include screenshots (if relevant):
I am trying to instrument a React component using "withTransaction", but it doesn't work. My code is something like:
initialization
import { init as initApm } from '@elastic/apm-rum'
export const apm = initApm({
serviceName: <serviceName>,
serverUrl: <serverUrl>,
debug: true
});
Home.js
import { withTransaction } from '@elastic/apm-rum-react'
class Home extends React.Component {
render () {
return <div>Home</div>;
}
}
export default withTransaction("Home component", "component")(Home);
I enabled the debug flag, and transactions of the type of "page-load" are detected. However, I don't see any logs for "withTransaction".
Can anyone give me some advice what i should do?