mosn / holmes

self-aware Golang profile dumper
Apache License 2.0
1.06k stars 135 forks source link

support cgroup v2 #121

Open Curl-Li opened 1 year ago

Curl-Li commented 1 year ago

适配CGroupv2,兼容v1版本,暂未支持混用挂载

mosn-community-bot[bot] commented 1 year ago

Hi @Curl-Li, welcome to mosn community, Please sign Contributor License Agreement!

After you signed CLA, we will automatically sync the status of this pull request in 3 minutes.

Jun10ng commented 1 year ago

Hi Curl, thanks for your PR, this is a large PR for holmes, I need more time to figure out them, and these changes seems very like automaxprocs/tree/master/internal/cgroups.

It seems to be a common solution, but I'm not sure whether it is related to the Golang version

Curl-Li commented 1 year ago

Hi Curl, thanks for your PR, this is a large PR for holmes, I need more time to figure out them, and these changes seems very like automaxprocs/tree/master/internal/cgroups.

It seems to be a common solution, but I'm not sure whether it is related to the Golang version

I referenced part of automaxprocs's code and wrapped it. About issue of version, I tried golang1.9rc1 and golang1.19.1, both are working well.

Jun10ng commented 1 year ago

LGTM. It seems standard modifications about CGroups v1/v2.

doujiang24 commented 1 year ago

Thanks, I will take a deeper look when I have a long free time.