mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-15 18:08:30 -07:00
9671050e5b
Squashed commit of the following:
commit 96d185cf4acc55b21a00d10072e0a641ef7655b8
Merge: 3b75a8cb 9b7c1181
Author: Simon Zolin <s.zolin@adguard.com>
Date: Wed Apr 22 15:57:50 2020 +0300
Merge remote-tracking branch 'origin/master' into add-pprof
commit 3b75a8cbec5d72be8865a56bfd7ebb8b0673c3bc
Author: Simon Zolin <s.zolin@adguard.com>
Date: Wed Apr 22 13:52:36 2020 +0300
* use localhost:6060 for pprof
commit f66f2fbd7409b98cd9f7d297c268fca998f85e3b
Author: Simon Zolin <s.zolin@adguard.com>
Date: Wed Apr 22 12:46:25 2020 +0300
minor
commit 6e38712fb5542f612675858eb957efdefc38f9b0
Author: Simon Zolin <s.zolin@adguard.com>
Date: Wed Apr 22 11:59:39 2020 +0300
use separate HTTP server for pprof
commit 988d95b5fad22f536bf9204b6b96f3697cf9a589
Author: Simon Zolin <s.zolin@adguard.com>
Date: Tue Apr 21 17:04:04 2020 +0300
minor
commit 90ee6e9753be2af49467687cdf71c35b3943b78b
Author: Simon Zolin <s.zolin@adguard.com>
Date: Tue Apr 21 16:57:38 2020 +0300
* use modified version of pprof
commit 413002220fe0717950539a8b7e6b0f31cef31bb8
Author: Simon Zolin <s.zolin@adguard.com>
Date: Mon Apr 20 16:35:21 2020 +0300
minor
commit d4655d3849de1d9fe97efdb7f18fc21d5ac19eda
Author: Simon Zolin <s.zolin@adguard.com>
Date: Mon Apr 20 15:57:57 2020 +0300
+ config: add "enable_pprof" setting
73 lines
2.0 KiB
YAML
73 lines
2.0 KiB
YAML
# options for analysis running
|
|
run:
|
|
# default concurrency is a available CPU number
|
|
concurrency: 4
|
|
|
|
# timeout for analysis, e.g. 30s, 5m, default is 1m
|
|
deadline: 2m
|
|
|
|
# which files to skip: they will be analyzed, but issues from them
|
|
# won't be reported. Default value is empty list, but there is
|
|
# no need to include all autogenerated files, we confidently recognize
|
|
# autogenerated files. If it's not please let us know.
|
|
skip-files:
|
|
- ".*generated.*"
|
|
- dnsfilter/rule_to_regexp.go
|
|
- util/pprof.go
|
|
- ".*_test.go"
|
|
|
|
|
|
# all available settings of specific linters
|
|
linters-settings:
|
|
errcheck:
|
|
# [deprecated] comma-separated list of pairs of the form pkg:regex
|
|
# the regex is used to ignore names within pkg. (default "fmt:.*").
|
|
# see https://github.com/kisielk/errcheck#the-deprecated-method for details
|
|
ignore: fmt:.*,net:SetReadDeadline,net/http:^Write
|
|
gocyclo:
|
|
min-complexity: 20
|
|
lll:
|
|
line-length: 200
|
|
|
|
linters:
|
|
enable:
|
|
- deadcode
|
|
- errcheck
|
|
- govet
|
|
- ineffassign
|
|
- staticcheck
|
|
- structcheck
|
|
- unused
|
|
- varcheck
|
|
- bodyclose
|
|
- depguard
|
|
- dupl
|
|
- gocyclo
|
|
- goimports
|
|
- golint
|
|
- gosec
|
|
- misspell
|
|
- stylecheck
|
|
- unconvert
|
|
disable-all: true
|
|
fast: true
|
|
|
|
issues:
|
|
# List of regexps of issue texts to exclude, empty list by default.
|
|
# But independently from this option we use default exclude patterns,
|
|
# it can be disabled by `exclude-use-default: false`. To list all
|
|
# excluded by default patterns execute `golangci-lint run --help`
|
|
exclude:
|
|
# structcheck cannot detect usages while they're there
|
|
- .parentalServer. is unused
|
|
- .safeBrowsingServer. is unused
|
|
# errcheck
|
|
- Error return value of .s.closeConn. is not checked
|
|
- Error return value of ..*.Shutdown.
|
|
# goconst
|
|
- string .forcesafesearch.google.com. has 3 occurrences
|
|
# gosec: Profiling endpoint is automatically exposed on /debug/pprof
|
|
- G108
|
|
# gosec: Subprocess launched with function call as argument or cmd arguments
|
|
- G204
|