public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonStorageGatewayConfig config = new AmazonStorageGatewayConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonStorageGatewayClient client = new AmazonStorageGatewayClient(creds, config); DescribeTapeRecoveryPointsResponse resp = new DescribeTapeRecoveryPointsResponse(); do { DescribeTapeRecoveryPointsRequest req = new DescribeTapeRecoveryPointsRequest { Marker = resp.Marker , Limit = maxItems }; resp = client.DescribeTapeRecoveryPoints(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.TapeRecoveryPointInfos) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.Marker)); }
public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonStorageGatewayConfig config = new AmazonStorageGatewayConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonStorageGatewayClient client = new AmazonStorageGatewayClient(creds, config); ListFileSystemAssociationsResponse resp = new ListFileSystemAssociationsResponse(); do { ListFileSystemAssociationsRequest req = new ListFileSystemAssociationsRequest { Marker = resp.NextMarker , Limit = maxItems }; resp = client.ListFileSystemAssociations(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.FileSystemAssociationSummaryList) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.NextMarker)); }
protected IAmazonStorageGateway CreateClient(AWSCredentials credentials, RegionEndpoint region) { var config = new AmazonStorageGatewayConfig { RegionEndpoint = region }; Amazon.PowerShell.Utils.Common.PopulateConfig(this, config); this.CustomizeClientConfig(config); var client = new AmazonStorageGatewayClient(credentials, config); client.BeforeRequestEvent += RequestEventHandler; client.AfterResponseEvent += ResponseEventHandler; return(client); }
public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonStorageGatewayConfig config = new AmazonStorageGatewayConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonStorageGatewayClient client = new AmazonStorageGatewayClient(creds, config); ListVolumeRecoveryPointsResponse resp = new ListVolumeRecoveryPointsResponse(); ListVolumeRecoveryPointsRequest req = new ListVolumeRecoveryPointsRequest { }; resp = client.ListVolumeRecoveryPoints(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.VolumeRecoveryPointInfos) { AddObject(obj); } }