コード例 #1
0
ファイル: logs.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new Logs client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *Logs {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("logs", region)

	return &Logs{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "Logs_20140328",
		},
	}
}
コード例 #2
0
ファイル: ecs.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new ECS client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *ECS {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("ecs", region)

	return &ECS{
		client: &aws.QueryClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2014-11-13",
		},
	}
}
コード例 #3
0
ファイル: dynamodb.go プロジェクト: 2722/lantern
// New returns a new DynamoDB client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *DynamoDB {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("dynamodb", region)

	return &DynamoDB{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.0",
			TargetPrefix: "DynamoDB_20120810",
		},
	}
}
コード例 #4
0
ファイル: cloudhsm.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new CloudHSM client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *CloudHSM {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("cloudhsm", region)

	return &CloudHSM{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "CloudHsmFrontendService",
		},
	}
}
コード例 #5
0
ファイル: support.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new Support client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *Support {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("support", region)

	return &Support{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "AWSSupport_20130415",
		},
	}
}
コード例 #6
0
ファイル: cloudtrail.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new CloudTrail client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *CloudTrail {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("cloudtrail", region)

	return &CloudTrail{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "com.amazonaws.cloudtrail.v20131101.CloudTrail_20131101",
		},
	}
}
コード例 #7
0
ファイル: importexport.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new ImportExport client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *ImportExport {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("importexport", region)

	return &ImportExport{
		client: &aws.QueryClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2010-06-01",
		},
	}
}
コード例 #8
0
ファイル: emr.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new EMR client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *EMR {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("elasticmapreduce", region)

	return &EMR{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "ElasticMapReduce",
		},
	}
}
コード例 #9
0
ファイル: config.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new Config client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *Config {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("config", region)

	return &Config{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "StarlingDoveService",
		},
	}
}
コード例 #10
0
ファイル: cloudsearchdomain.go プロジェクト: yang1006/lantern
// New returns a new CloudSearchDomain client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *CloudSearchDomain {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("cloudsearchdomain", region)

	return &CloudSearchDomain{
		client: &aws.RestClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2013-01-01",
		},
	}
}
コード例 #11
0
ファイル: route53domains.go プロジェクト: 2722/lantern
// New returns a new Route53Domains client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *Route53Domains {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("route53domains", region)

	return &Route53Domains{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "Route53Domains_v20140515",
		},
	}
}
コード例 #12
0
ファイル: cloudwatch.go プロジェクト: 2722/lantern
// New returns a new CloudWatch client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *CloudWatch {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("monitoring", region)

	return &CloudWatch{
		client: &aws.QueryClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2010-08-01",
		},
	}
}
コード例 #13
0
ファイル: datapipeline.go プロジェクト: ComeOn-Wuhan/lantern
// New returns a new DataPipeline client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *DataPipeline {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("datapipeline", region)

	return &DataPipeline{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "DataPipeline",
		},
	}
}
コード例 #14
0
ファイル: directconnect.go プロジェクト: 2722/lantern
// New returns a new DirectConnect client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *DirectConnect {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("directconnect", region)

	return &DirectConnect{
		client: &aws.JSONClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			}, Client: client,
			Endpoint:     endpoint,
			JSONVersion:  "1.1",
			TargetPrefix: "OvertureService",
		},
	}
}
コード例 #15
0
ファイル: elb.go プロジェクト: xiaojianqing/lantern
// New returns a new ELB client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *ELB {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("elasticloadbalancing", region)

	return &ELB{
		client: &aws.QueryClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2012-06-01",
		},
	}
}
コード例 #16
0
ファイル: elastictranscoder.go プロジェクト: 2722/lantern
// New returns a new ElasticTranscoder client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *ElasticTranscoder {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("elastictranscoder", region)

	return &ElasticTranscoder{
		client: &aws.RestClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2012-09-25",
		},
	}
}
コード例 #17
0
ファイル: sync.go プロジェクト: 2722/lantern
// New returns a new CognitoSync client.
func New(creds aws.CredentialsProvider, region string, client *http.Client) *CognitoSync {
	if client == nil {
		client = http.DefaultClient
	}

	endpoint, service, region := endpoints.Lookup("cognito-sync", region)

	return &CognitoSync{
		client: &aws.RestClient{
			Context: aws.Context{
				Credentials: creds,
				Service:     service,
				Region:      region,
			},
			Client:     client,
			Endpoint:   endpoint,
			APIVersion: "2014-06-30",
		},
	}
}