SE-1463 Allow overriding broker heartbeat

Description

BROKER_HEARTBEAT appears to interfere with the celery worker
configuration. If we want to disable or change the heartbeat interval,
It must be from these configuration options.

Just setting --without-heartbeat and/or --heartbeat-interval on the
workers does not fully work. Eg. --without-heartbeat disables sending
heartbeats, but BROKER_HEARTBEAT = 60 means that the connection will get
a 60s heartbeat interval negotiated.

*JIRA tickets*:

*Dependencies*: None

*Sandbox URL*: TBD - sandbox is being provisioned.

*Merge deadline*: None

*Testing instructions*:

1. Change the variables `BROKER_HEARTBEAT` to 0, and deploy edxapp
2. ensure that the heartbeat config for the rabbitmq server is set to 0
3. run the workers
4. verify that rabbitmq connections are negotiated with heartbeats disabled.
5. Change the variables `BROKER_HEARTBEAT` to 600, and deploy edxapp
6. ensure that the heartbeat config for the rabbitmq server is set to 600 or higher
7. run the workers
8. verify that rabbitmq connections are negotiated with heartbeats set to 600s.

The change can be verified on the sandbox by tailing the worker logs and verifying
that the socket closed errors happen with a lesser frequency than 3 minutes per
worker.

*Reviewers*

  • [ ] @viadanna

  • [ ] edX reviewer[s] TBD

*Settings*
```yaml
EDXAPP_BROKER_HEARTBEAT: 500
EDXAPP_BROKER_HEARTBEAT_CHECKRATE: 2
```

Status

Assignee

David Ormsbee

Reporter

Open Source Pull Request Bot

Labels

Contributor Name

Samuel Walladge

Repo

edx/edx-platform

Customer

Epic Link

None

OSCM Assignee

None

Priority

Unset
Configure