Documentation ¶
Index ¶
- func NewRedisClient(opts *redis.Options) *redis.Client
- type Doer
- type IPAcceptor
- type IPAcceptorImpl
- type InmemoryStorage
- type LogLevel
- type Logger
- func (l *Logger) Debug(v ...interface{})
- func (l *Logger) Debugf(format string, v ...interface{})
- func (l *Logger) Debugln(v ...interface{})
- func (l *Logger) Error(v ...interface{})
- func (l *Logger) Errorf(format string, v ...interface{})
- func (l *Logger) Errorln(v ...interface{})
- func (l *Logger) Info(v ...interface{})
- func (l *Logger) Infof(format string, v ...interface{})
- func (l *Logger) Infoln(v ...interface{})
- func (l *Logger) Trace(v ...interface{})
- func (l *Logger) Tracef(format string, v ...interface{})
- func (l *Logger) Traceln(v ...interface{})
- func (l *Logger) Warn(v ...interface{})
- func (l *Logger) Warnf(format string, v ...interface{})
- func (l *Logger) Warnln(v ...interface{})
- type Pool
- type PoolImpl
- type Storage
- type StorageRedis
- type TorFacade
- type TorFacadeFactory
- type TorFacadeFactoryImpl
- type TorFacadeImpl
- type Worker
- type WorkerFactory
- type WorkerFactoryImpl
- type WorkerImpl
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRedisClient ¶
func NewRedisClient(opts *redis.Options) *redis.Client
Types ¶
type IPAcceptor ¶
type IPAcceptorImpl ¶
type IPAcceptorImpl struct {
Storage
}
func NewIPAcceptorImpl ¶
func NewIPAcceptorImpl(storage Storage) *IPAcceptorImpl
type InmemoryStorage ¶
func NewInmemoryStorage ¶
func NewInmemoryStorage() *InmemoryStorage
func (*InmemoryStorage) InsertIfNotExists ¶
func (s *InmemoryStorage) InsertIfNotExists(value string) (bool, error)
type PoolImpl ¶
func NewPoolImpl ¶
func NewPoolImpl(size int, maxCallsPerIP int, wf WorkerFactory) (*PoolImpl, error)
type StorageRedis ¶
type StorageRedis struct { *redis.Client // contains filtered or unexported fields }
func NewRedisStorage ¶
func NewRedisStorage( client *redis.Client, expiration time.Duration, ) *StorageRedis
func (*StorageRedis) InsertIfNotExists ¶
func (s *StorageRedis) InsertIfNotExists(value string) (bool, error)
type TorFacadeFactory ¶
type TorFacadeFactoryImpl ¶
func NewTorFacadeFactoryImpl ¶
func NewTorFacadeFactoryImpl() (*TorFacadeFactoryImpl, error)
func (*TorFacadeFactoryImpl) New ¶
func (t *TorFacadeFactoryImpl) New() (TorFacade, error)
func (*TorFacadeFactoryImpl) NewBasePort ¶
func (t *TorFacadeFactoryImpl) NewBasePort() int
func (*TorFacadeFactoryImpl) NewCtrlPort ¶
func (t *TorFacadeFactoryImpl) NewCtrlPort() int
func (*TorFacadeFactoryImpl) NewDataDir ¶
func (t *TorFacadeFactoryImpl) NewDataDir() (string, error)
func (*TorFacadeFactoryImpl) NewPidFile ¶
func (t *TorFacadeFactoryImpl) NewPidFile() string
type TorFacadeImpl ¶
func NewTorFacadeImpl ¶
func (*TorFacadeImpl) ChangeIP ¶
func (t *TorFacadeImpl) ChangeIP() (string, error)
type WorkerFactory ¶
type WorkerFactoryImpl ¶
type WorkerFactoryImpl struct { IPAcceptor TorFacadeFactory }
func NewWorkerFactoryImpl ¶
func NewWorkerFactoryImpl(IPAcceptor IPAcceptor, torFacadeFactory TorFacadeFactory) *WorkerFactoryImpl
type WorkerImpl ¶
type WorkerImpl struct { IPAcceptor TorFacade // contains filtered or unexported fields }
func NewWorkerImpl ¶
func NewWorkerImpl(IPAcceptor IPAcceptor, torFacade TorFacade, queue chan<- Worker) *WorkerImpl
func (*WorkerImpl) Update ¶
func (w *WorkerImpl) Update() error
Source Files ¶
Click to show internal directories.
Click to hide internal directories.