func (s *vortexSubscriber) Status() chan manipulate.SubscriberStatus {
	return s.subscriberStatusChannel
}
Status returns the status channel.
package manipvortex
import (
	"context"
	"fmt"
	"sync"
	"go.aporeto.io/elemental"
	"go.aporeto.io/manipulate"
)
type vortexSubscriber struct {
	v                       *vortexManipulator
	subscriberErrorChannel  chan error
	subscriberEventChannel  chan *elemental.Event
	subscriberStatusChannel chan manipulate.SubscriberStatus
	filter                  *elemental.PushConfig
	sync.RWMutex
}
func NewSubscriber(m manipulate.Manipulator, queueSize int) (manipulate.Subscriber, error) {
	v, ok := m.(*vortexManipulator)
	if !ok {
		return nil, fmt.Errorf("NewSubscriber only works with Vortex manipulator")
	}
	if !v.hasBackendSubscriber() {
		return nil, fmt.Errorf("vortex has no upstream subscriber: local subscriptions not supported")
	}
	s := &vortexSubscriber{
		v:                       v,
		subscriberErrorChannel:  make(chan error, queueSize),
		subscriberEventChannel:  make(chan *elemental.Event, queueSize),
		subscriberStatusChannel: make(chan manipulate.SubscriberStatus, queueSize),
	}
	v.registerSubscriber(s)
	return s, nil
}
func (s *vortexSubscriber) Start(ctx context.Context, e *elemental.PushConfig) {
	s.UpdateFilter(e)
}
func (s *vortexSubscriber) UpdateFilter(e *elemental.PushConfig) {
	if e == nil {
		return
	}
	s.Lock()
	s.filter = e
	s.Unlock()
	s.v.updateFilter()
}
func (s *vortexSubscriber) Events() chan *elemental.Event { return s.subscriberEventChannel }
func (s *vortexSubscriber) Errors() chan error { return s.subscriberErrorChannel }