The main focus of the development of version 2.0 of the Go agent was to improve reliability and reduce agent overhead by upgrading and tuning the profiling capabilities.
Here is a summary of the main changes:
- Some of the profiles in version 1.x relied on Go’s tracer, which records every blocking event. It has high overhead, although we’ve kept it under control by implementing overhead checks around it. In the version 2.0, blocking call and server bottleneck profilers use Go’s block profiler, which is a sampling profiler, similar to CPU and memory allocation profilers, and thus has a very low overhead.
- A profiler-triggering algorithm was updated to better orchestrate the recording of different profilers.
- For regular profiling, we’ve introduced a logic to take periodicity bias into account. This will make sure the profile recording schedule does not accidentally match any application batch jobs, if any.