Exemple #1
0
func New(uri string) (*AMQPRedialer, error) {
	u, err := amqp.ParseURI(uri)
	if err != nil {
		return nil, err
	}
	u.Password = "******" // do not print in logs
	d := amqpDialer{
		uri:     uri,
		address: u.String(),
	}
	return &AMQPRedialer{
		redialer.New(d),
	}, nil
}
Exemple #2
0
func New(address string) *SMTPRedialer {
	d := &smtpDialer{address}
	return &SMTPRedialer{redialer.New(d)}
}
Exemple #3
0
func New(network, address string) *NetRedialer {
	d := &netDialer{network, address}
	return &NetRedialer{redialer.New(d)}
}