mirror of
https://github.com/zulip/zulip.git
synced 2025-10-27 01:53:59 +00:00
This list was likely to end up out of date quickly, since it wasn't documented that you need to update it when adding a queue. The best solution is to just not require it to be updated.
27 lines
759 B
Python
Executable File
27 lines
759 B
Python
Executable File
#!/usr/bin/env python
|
|
|
|
from __future__ import print_function
|
|
import argparse
|
|
import os
|
|
import sys
|
|
from os.path import dirname, abspath
|
|
|
|
BASE_DIR = dirname(dirname(dirname(abspath(__file__))))
|
|
sys.path.append(BASE_DIR)
|
|
import scripts.lib.setup_path_on_import
|
|
|
|
os.environ['DJANGO_SETTINGS_MODULE'] = 'zproject.settings'
|
|
|
|
import django
|
|
django.setup()
|
|
from zerver.worker.queue_processors import get_active_worker_queues
|
|
|
|
if __name__ == "__main__":
|
|
parser = argparse.ArgumentParser()
|
|
parser.add_argument('--queue_type', action='store', dest='queue_type', default=None,
|
|
help="Specify which types of queues to list")
|
|
args = parser.parse_args()
|
|
|
|
workers = get_active_worker_queues(args.queue_type)
|
|
print(" ".join(workers))
|