public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems)
        {
            AmazonEMRContainersConfig config = new AmazonEMRContainersConfig();

            config.RegionEndpoint = region;
            ConfigureClient(config);
            AmazonEMRContainersClient client = new AmazonEMRContainersClient(creds, config);

            ListVirtualClustersResponse resp = new ListVirtualClustersResponse();

            do
            {
                ListVirtualClustersRequest req = new ListVirtualClustersRequest
                {
                    NextToken = resp.NextToken
                    ,
                    MaxResults = maxItems
                };

                resp = client.ListVirtualClusters(req);
                CheckError(resp.HttpStatusCode, "200");

                foreach (var obj in resp.VirtualClusters)
                {
                    AddObject(obj);
                }
            }while (!string.IsNullOrEmpty(resp.NextToken));
        }
        protected IAmazonEMRContainers CreateClient(AWSCredentials credentials, RegionEndpoint region)
        {
            var config = new AmazonEMRContainersConfig {
                RegionEndpoint = region
            };

            Amazon.PowerShell.Utils.Common.PopulateConfig(this, config);
            this.CustomizeClientConfig(config);
            var client = new AmazonEMRContainersClient(credentials, config);

            client.BeforeRequestEvent += RequestEventHandler;
            client.AfterResponseEvent += ResponseEventHandler;
            return(client);
        }