UpdatePool() 공개 메소드

public UpdatePool ( string poolId, string name = null, string lbMethod = null ) : Pool
poolId string
name string
lbMethod string
리턴 Pool
        public void UpdatePoolTest()
        {
            var os = new OpenStackMember(UserName, Password, TenantName, TenantId);
            // string tenantId = os.IdentityProvider.GetToken(os.Identity).Tenant.Id;

            // create pool
            string pool_name = GetTesterNameByEnv();
            string TokyoLBaas_subnetId = GetSubnetIdByRegion(region: null);
            string[] lbMethods = { "ROUND_ROBIN", "LEAST_CONNECTIONS" };
            string protocol = "TCP";

            foreach (var lbMethod in lbMethods)
            {
                var p = os.CreatePool(pool_name, TokyoLBaas_subnetId, lbMethod, protocol);
                Trace.WriteLine(string.Format("pool Status : {0}", p.Status));
                System.Threading.Thread.Sleep(1000 * 10);
                Trace.WriteLine(string.Format("pool Status : {0}", p.Status));
                try
                {
                    foreach (var newLbMethod in lbMethods)
                    {
                        os.UpdatePool(p.Id, "newName", newLbMethod);

                        // not tested yet.
                        //os.UpdatePool(p.Id, "日本語", lbMethod);
                        //os.UpdatePool(p.Id, "//", lbMethod);
                    }
                }
                finally
                {
                    Assert.IsTrue(os.DeletePool(p.Id));
                }
            }
        }