Created connect_amqp func