mirror of
https://github.com/ZwareBear/awx.git
synced 2026-04-19 22:41:49 -05:00
Updates for automatic triggering of policies
* Switch policy router queue to not be "tower" so that we don't fall into a chicken/egg scenario * Show fixed policy list in serializer so a user can determine if an instance is manually managed * Change IG membership mixin to not directly handle applying topology changes. Instead it just makes sure the policy instance list is accurate * Add create/delete hooks for instances and groups to trigger policy re-evaluation * Update policy algorithm for fairer distribution * Fix an issue where CELERY_ROUTES wasn't renamed after celery/django upgrade * Update unit tests to be more explicit * Update count calculations used by algorithm to only consider non-manual instances * Adding unit tests and fixture * Don't propagate logging messages from awx.main.tasks and awx.main.scheduler * Use advisory lock to prevent policy eval conflicts * Allow updating instance groups from view
This commit is contained in:
@@ -432,6 +432,7 @@ DEVSERVER_DEFAULT_PORT = '8013'
|
||||
# Set default ports for live server tests.
|
||||
os.environ.setdefault('DJANGO_LIVE_TEST_SERVER_ADDRESS', 'localhost:9013-9199')
|
||||
|
||||
BROKER_POOL_LIMIT = None
|
||||
CELERY_BROKER_URL = 'amqp://guest:guest@localhost:5672//'
|
||||
CELERY_EVENT_QUEUE_TTL = 5
|
||||
CELERY_TASK_DEFAULT_QUEUE = 'tower'
|
||||
@@ -452,7 +453,7 @@ CELERY_TASK_QUEUES = (
|
||||
)
|
||||
CELERY_TASK_ROUTES = {}
|
||||
|
||||
CELERYBEAT_SCHEDULE = {
|
||||
CELERY_BEAT_SCHEDULE = {
|
||||
'tower_scheduler': {
|
||||
'task': 'awx.main.tasks.awx_periodic_scheduler',
|
||||
'schedule': timedelta(seconds=30),
|
||||
@@ -1123,9 +1124,11 @@ LOGGING = {
|
||||
},
|
||||
'awx.main.tasks': {
|
||||
'handlers': ['task_system'],
|
||||
'propagate': False
|
||||
},
|
||||
'awx.main.scheduler': {
|
||||
'handlers': ['task_system'],
|
||||
'propagate': False
|
||||
},
|
||||
'awx.main.consumers': {
|
||||
'handlers': ['null']
|
||||
|
||||
Reference in New Issue
Block a user