consistent infinite for loop style
This commit is contained in:
parent
e8ac96d68d
commit
93ccd37c82
|
@ -23,7 +23,7 @@ func main() {
|
||||||
|
|
||||||
rai := ra.NewRegistrationAuthorityImpl(auditlogger)
|
rai := ra.NewRegistrationAuthorityImpl(auditlogger)
|
||||||
|
|
||||||
for true {
|
for {
|
||||||
ch := cmd.AmqpChannel(c.AMQP.Server)
|
ch := cmd.AmqpChannel(c.AMQP.Server)
|
||||||
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ func main() {
|
||||||
sai, err := sa.NewSQLStorageAuthority(auditlogger, c.SA.DBDriver, c.SA.DBName)
|
sai, err := sa.NewSQLStorageAuthority(auditlogger, c.SA.DBDriver, c.SA.DBName)
|
||||||
cmd.FailOnError(err, "Failed to create SA impl")
|
cmd.FailOnError(err, "Failed to create SA impl")
|
||||||
|
|
||||||
for true {
|
for {
|
||||||
ch := cmd.AmqpChannel(c.AMQP.Server)
|
ch := cmd.AmqpChannel(c.AMQP.Server)
|
||||||
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@ func main() {
|
||||||
|
|
||||||
vai := va.NewValidationAuthorityImpl(auditlogger, c.CA.TestMode)
|
vai := va.NewValidationAuthorityImpl(auditlogger, c.CA.TestMode)
|
||||||
|
|
||||||
for true {
|
for {
|
||||||
ch := cmd.AmqpChannel(c.AMQP.Server)
|
ch := cmd.AmqpChannel(c.AMQP.Server)
|
||||||
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
closeChan := ch.NotifyClose(make(chan *amqp.Error, 1))
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ func main() {
|
||||||
// sit around and reconnect to AMQP if the channel
|
// sit around and reconnect to AMQP if the channel
|
||||||
// drops for some reason and repopulate the wfe object
|
// drops for some reason and repopulate the wfe object
|
||||||
// with new RA and SA rpc clients.
|
// with new RA and SA rpc clients.
|
||||||
for true {
|
for {
|
||||||
for err := range closeChan {
|
for err := range closeChan {
|
||||||
auditlogger.Warning(fmt.Sprintf("AMQP Channel closed, will reconnect in 5 seconds: [%s]", err))
|
auditlogger.Warning(fmt.Sprintf("AMQP Channel closed, will reconnect in 5 seconds: [%s]", err))
|
||||||
time.Sleep(time.Second*5)
|
time.Sleep(time.Second*5)
|
||||||
|
|
Loading…
Reference in New Issue