// New creates an instance of fabricbeat.
New creates an instance of fabricbeat.
// New creates an instance of fabricbeat .
func New(b *beat.Beat, cfg *common.Config) (beat.Beater, error) {
	c := config.DefaultConfig
	if err := cfg.Unpack(&c); err != nil {
		return nil, fmt.Errorf("Error reading config file: %v", err)
	}
	bt := &Fabricbeat{
		done:   make(chan struct{}),
		config: c,
	}
	return bt, nil
}
func New ( b * beat . Beat , cfg * common . Config ) ( beat . Beater , error ) { c := config . DefaultConfig if err := cfg . Unpack ( & c ) ; err != nil { return nil , fmt . Errorf ( " " , err ) } bt := & Fabricbeat { done : make ( chan struct { } ) , config : c , } return bt , nil }
New creates an instance of fabricbeat.
New creates an instance of fabricbeat .