예제 #1
0
 def __init__(self, args, suffix):
     self.suffix = suffix
     self.config_tag = get_mandatory_arg(args, "--config-tag", self.suffix)
     self.technology = get_mandatory_arg_validated(args, "--technology",
                                                   self.suffix,
                                                   ["rabbitmq"])
     self.cluster_size = int(
         get_optional_arg(args, "--cluster-size", self.suffix, "1"))
     self.broker_version = get_mandatory_arg(args, "--version", self.suffix)
     self.volume_size = get_optional_arg(args, "--volume-size", self.suffix,
                                         "50")  # for GCP deployment only
     self.filesystem = get_mandatory_arg_validated(args, "--filesystem",
                                                   self.suffix,
                                                   ["ext4", "xfs"])
     self.tenancy = get_mandatory_arg_validated(args, "--tenancy",
                                                self.suffix,
                                                ["default", "dedicated"])
     self.core_count = get_mandatory_arg(args, "--core-count", self.suffix)
     self.threads_per_core = get_mandatory_arg(args, "--threads-per-core",
                                               self.suffix)
     self.vars_file = get_optional_arg(
         args, "--vars-file", self.suffix,
         f".variables/{self.technology}-generic-vars.yml")
     self.no_tcp_delay = get_optional_arg(args, "--no-tcp-delay",
                                          self.suffix, "true")
     self.policies_file = get_optional_arg(args, "--policies-file",
                                           self.suffix, "none")
     self.pub_connect_to_node = get_optional_arg_validated(
         args, "--pub-connect-to-node", self.suffix,
         ["roundrobin", "local", "non-local", "random"], "roundrobin")
     self.con_connect_to_node = get_optional_arg_validated(
         args, "--con-connect-to-node", self.suffix,
         ["roundrobin", "local", "non-local", "random"], "roundrobin")
     self.node_number = -1
예제 #2
0
    def __init__(self, args, suffix):
        super().__init__(args, suffix)

        self.generic_unix_url = get_mandatory_arg(args, "--generic-unix-url",
                                                  self.suffix)
        self.instance = get_mandatory_arg(args, "--instance", self.suffix)
        self.volume = get_mandatory_arg_validated(
            args, "--volume", self.suffix,
            ["ebs-io1", "ebs-st1", "ebs-gp2", "local-nvme"])
    def __init__(self, args, suffix):
        super().__init__(args, suffix)

        self.container_image = get_mandatory_arg(args, "--container-image",
                                                 self.suffix)
        self.container_env = get_optional_arg(args, "--container-env",
                                              self.suffix, "")
        self.machine_type = get_mandatory_arg(args, "--machine-type",
                                              self.suffix)
        self.volume = get_mandatory_arg_validated(args, "--volume",
                                                  self.suffix,
                                                  ["pd-ssd", "pd-standard"])
예제 #4
0
    mgmt_ip = get_mandatory_arg(args, "--mgmt-ip")
    mgmt_port = get_mandatory_arg(args, "--mgmt-port")
    broker_name = get_mandatory_arg(args, "--broker-name")
    
    if use_amqproxy:
        amqproxy_ip = get_mandatory_arg(args, "--amqproxy-ip")
        amqproxy_port = get_mandatory_arg(args, "--amqproxy-port")
        broker_ip = ""
        broker_port = ""
    else:
        broker_ip = get_mandatory_arg(args, "--broker-ip")
        broker_port = get_mandatory_arg(args, "--broker-port")
        amqproxy_ip = ""
        amqproxy_port = ""

    publish_mode = get_mandatory_arg_validated(args, "--pub-mode", ["async", "sync", "new-conn-per-msg", "fire-and-forget"])
    delay_seconds = int(get_optional_arg(args, "--pub-delay", "0"))

    if delay_seconds > 0:
        console_out(f"Starting with delay of {delay_seconds} seconds", "TEST RUNNER")
        time.sleep(delay_seconds)

    broker_manager = BrokerManager(mgmt_ip, mgmt_port, broker_name, broker_ip, broker_port, amqproxy_ip, amqproxy_port, user, password, use_https, virtual_host)

    queue_created = False

    while queue_created == False:  
        queue_created = broker_manager.create_queue(queue, False)

        if queue_created == False:
            time.sleep(5)