public static IIntermediarySocket AsIntermediaryWithRandomPort(this EasyZMqConfigurer configurer,
            string backendAddress)
        {
            var frontendAddressBinder = configurer.AddressBinder;
            var backendAddressBinder = new BindRandomPortAddressBinder(backendAddress);

            return CreateIntermediarySocket(frontendAddressBinder, backendAddressBinder);
        }
Пример #2
0
        public static EasyZMqConfigurer BindRandomPort(string address)
        {
            if (string.IsNullOrEmpty(address)) throw new ArgumentNullException(nameof(address));

            var addressBinder = new BindRandomPortAddressBinder(address);

            return CreateConfigurer(addressBinder);
        }