public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonXRayConfig config = new AmazonXRayConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonXRayClient client = new AmazonXRayClient(creds, config); GetGroupsResponse resp = new GetGroupsResponse(); do { GetGroupsRequest req = new GetGroupsRequest { NextToken = resp.NextToken }; resp = client.GetGroups(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.Groups) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.NextToken)); }
private AmazonXRayClient CreateXRayClient(DaemonConfig endpoint) { var config = new AmazonXRayConfig(); config.ServiceURL = "http://" + endpoint.TCPEndpoint.Address.ToString() + ":" + endpoint.TCPEndpoint.Port; AWSCredentials credentials = new AnonymousAWSCredentials(); // sends unsigned requests to daemon endpoint return(new AmazonXRayClient(credentials, config)); }
protected static void ClassInit() { var config = new AmazonXRayConfig(); config.ServiceURL = "https://xray.us-east-1.amazonaws.com "; config.AuthenticationRegion = "us-east-1"; XrayClient = new AmazonXRayClient(config); Recorder = new AWSXRayRecorder(); }
protected IAmazonXRay CreateClient(AWSCredentials credentials, RegionEndpoint region) { var config = new AmazonXRayConfig { RegionEndpoint = region }; Amazon.PowerShell.Utils.Common.PopulateConfig(this, config); this.CustomizeClientConfig(config); var client = new AmazonXRayClient(credentials, config); client.BeforeRequestEvent += RequestEventHandler; client.AfterResponseEvent += ResponseEventHandler; return(client); }