Skip to content
This repository has been archived by the owner on Mar 28, 2023. It is now read-only.

Commit

Permalink
some debug
Browse files Browse the repository at this point in the history
  • Loading branch information
laullon committed Mar 6, 2019
1 parent 0360ea8 commit d8d88cc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
8 changes: 4 additions & 4 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ var logger = log.New(os.Stdout, "[WAVEFRONT] ", 0)
var debug = os.Getenv("WAVEFRONT_DEBUG") == "true"

func main() {
if debug {
for _, pair := range os.Environ() {
logger.Println("env:", pair)
}
// if debug {
for _, pair := range os.Environ() {
logger.Println("env:", pair)
}
// }

conf, err := nozzle.ParseConfig()
if err != nil {
Expand Down
7 changes: 7 additions & 0 deletions nozzle/filter.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ type globFilter struct {

// NewGlobFilter grate a new Filter using gobwas/glob as regex engine
func NewGlobFilter(cfg *Filters) Filter {
logger.Printf("filters: MetricsWhiteList = '%v", cfg.MetricsWhiteList)
logger.Printf("filters: MetricsBlackList = '%v", cfg.MetricsBlackList)
logger.Printf("filters: MetricsTagWhiteList = '%v", cfg.MetricsTagWhiteList)
logger.Printf("filters: MetricsTagBlackList = '%v", cfg.MetricsTagBlackList)
logger.Printf("filters: TagInclude = '%v", cfg.TagInclude)
logger.Printf("filters: TagExclude = '%v", cfg.TagExclude)

return &globFilter{
metricWhitelist: compile(cfg.MetricsWhiteList),
metricBlacklist: compile(cfg.MetricsBlackList),
Expand Down

0 comments on commit d8d88cc

Please sign in to comment.