aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/pkg/profile/README.md
diff options
context:
space:
mode:
authorLukas Macko <lmacko@cisco.com>2017-09-07 10:00:26 +0200
committerLukas Macko <lmacko@cisco.com>2017-09-07 10:09:45 +0200
commitf2cbe790a5c3c3e8cb59b592c252b2b84025bd91 (patch)
treeac2fafdcb653ee05ed8ca3cfbc18d818cf6e7f3d /vendor/github.com/pkg/profile/README.md
parent13ab652c89a8bf5b16017156f8fb388e1889a8e1 (diff)
Wait until vpp is ready + Update vendor
Change-Id: I7c42d44d60f84fd21e55f9e4928d776f5466cc83 Signed-off-by: Lukas Macko <lmacko@cisco.com>
Diffstat (limited to 'vendor/github.com/pkg/profile/README.md')
-rw-r--r--vendor/github.com/pkg/profile/README.md54
1 files changed, 54 insertions, 0 deletions
diff --git a/vendor/github.com/pkg/profile/README.md b/vendor/github.com/pkg/profile/README.md
new file mode 100644
index 0000000..37bfa58
--- /dev/null
+++ b/vendor/github.com/pkg/profile/README.md
@@ -0,0 +1,54 @@
+profile
+=======
+
+Simple profiling support package for Go
+
+[![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)
+
+
+installation
+------------
+
+ go get github.com/pkg/profile
+
+usage
+-----
+
+Enabling profiling in your application is as simple as one line at the top of your main function
+
+```go
+import "github.com/pkg/profile"
+
+func main() {
+ defer profile.Start().Stop()
+ ...
+}
+```
+
+options
+-------
+
+What to profile is controlled by config value passed to profile.Start.
+By default CPU profiling is enabled.
+
+```go
+import "github.com/pkg/profile"
+
+func main() {
+ // p.Stop() must be called before the program exits to
+ // ensure profiling information is written to disk.
+ p := profile.Start(profile.MemProfile, profile.ProfilePath("."), profile.NoShutdownHook)
+ ...
+}
+```
+
+Several convenience package level values are provided for cpu, memory, and block (contention) profiling.
+
+For more complex options, consult the [documentation](http://godoc.org/github.com/pkg/profile).
+
+contributing
+------------
+
+We welcome pull requests, bug fixes and issue reports.
+
+Before proposing a change, please discuss it first by raising an issue.