{"id":13413703,"url":"https://github.com/pkg/profile","last_synced_at":"2025-05-13T22:01:53.497Z","repository":{"id":22222605,"uuid":"25555486","full_name":"pkg/profile","owner":"pkg","description":"Simple profiling for Go","archived":false,"fork":false,"pushed_at":"2022-10-20T20:16:29.000Z","size":66,"stargazers_count":2027,"open_issues_count":11,"forks_count":123,"subscribers_count":38,"default_branch":"master","last_synced_at":"2025-04-28T17:14:49.083Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pkg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-10-22T01:35:18.000Z","updated_at":"2025-04-26T23:56:18.000Z","dependencies_parsed_at":"2022-07-14T05:00:36.142Z","dependency_job_id":null,"html_url":"https://github.com/pkg/profile","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkg%2Fprofile","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkg%2Fprofile/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkg%2Fprofile/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkg%2Fprofile/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pkg","download_url":"https://codeload.github.com/pkg/profile/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254036807,"owners_count":22003651,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-30T20:01:46.888Z","updated_at":"2025-05-13T22:01:53.422Z","avatar_url":"https://github.com/pkg.png","language":"Go","readme":"profile\n=======\n\nSimple profiling support package for Go\n\n[![Build Status](https://travis-ci.org/pkg/profile.svg?branch=master)](https://travis-ci.org/pkg/profile) [![GoDoc](http://godoc.org/github.com/pkg/profile?status.svg)](http://godoc.org/github.com/pkg/profile)\n\n\ninstallation\n------------\n\n    go get github.com/pkg/profile\n\nusage\n-----\n\nEnabling profiling in your application is as simple as one line at the top of your main function\n\n```go\nimport \"github.com/pkg/profile\"\n\nfunc main() {\n    defer profile.Start().Stop()\n    ...\n}\n```\n\noptions\n-------\n\nWhat to profile is controlled by config value passed to profile.Start.\nBy default CPU profiling is enabled.\n\n```go\nimport \"github.com/pkg/profile\"\n\nfunc main() {\n    // p.Stop() must be called before the program exits to\n    // ensure profiling information is written to disk.\n    p := profile.Start(profile.MemProfile, profile.ProfilePath(\".\"), profile.NoShutdownHook)\n    ...\n    // You can enable different kinds of memory profiling, either Heap or Allocs where Heap\n    // profiling is the default with profile.MemProfile.\n    p := profile.Start(profile.MemProfileAllocs, profile.ProfilePath(\".\"), profile.NoShutdownHook)\n}\n```\n\nSeveral convenience package level values are provided for cpu, memory, and block (contention) profiling.\n\nFor more complex options, consult the [documentation](http://godoc.org/github.com/pkg/profile).\n\ncontributing\n------------\n\nWe welcome pull requests, bug fixes and issue reports.\n\nBefore proposing a change, please discuss it first by raising an issue.\n","funding_links":[],"categories":["Performance","Misc","开源类库","Open source library","Go","性能","Utilities","工具库","Go语言包管理","實用工具","Relational Databases","实用工具"],"sub_categories":["HTTP Clients","调试","Debugging","HTTP客户端","交流","Advanced Console UIs","ORM","高級控制台界面","OpenGL","\u003cspan id=\"高级控制台用户界面-advanced-console-uis\"\u003e高级控制台用户界面 Advanced Console UIs\u003c/span\u003e","高级控制台界面"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpkg%2Fprofile","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpkg%2Fprofile","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpkg%2Fprofile/lists"}