Packages
erlcloud
0.11.0
3.8.3
3.8.2
3.8.1
3.7.6
3.7.4
3.7.3
3.7.2
3.7.1
3.7.0
3.6.8
3.6.7
3.6.5
3.6.4
3.6.3
3.6.2
3.6.1
3.6.0
3.5.16
3.5.15
3.5.14
3.5.13
3.5.12
3.5.11
3.5.10
3.5.9
3.5.8
3.5.7
3.5.6
3.5.5
3.5.4
3.5.3
3.5.2
3.5.1
3.5.0
3.4.5
3.4.3
3.4.1
3.4.0
3.3.9
3.3.8
3.3.7
3.3.6
3.3.5
3.3.4
3.3.3
3.3.2
3.3.1
3.3.0
3.2.18
3.2.17
3.2.16
3.2.15
3.2.14
3.2.13
3.2.12
3.2.11
3.2.10
3.2.7
3.2.6
3.2.5
3.2.4
3.2.3
3.2.2
3.2.1
3.2.0
3.1.17
3.1.16
3.1.14
3.1.13
3.1.12
3.1.11
3.1.9
3.1.8
3.1.7
3.1.6
3.1.5
3.1.4
3.1.3
3.1.2
3.1.1
3.1.0
3.0.5
3.0.4
3.0.3
3.0.2
3.0.1
2.2.16
2.2.15
2.2.14
2.2.13
2.2.12
2.2.11
2.2.10
2.2.9
2.2.8
2.2.7
2.2.6
2.2.5
2.2.4
2.2.2
2.2.1
2.2.0
2.1.0
2.0.5
2.0.4
2.0.3
2.0.0
0.13.10
0.13.9
0.13.8
0.13.6
0.13.5
0.13.4
0.13.3
0.13.2
0.13.0
0.12.0
0.11.0
0.9.2
0.9.2-rc.1
0.9.1
0.9.0
AWS APIs library for Erlang
Current section
Files
Jump to
Current section
Files
include/erlcloud_aws.hrl
-record(aws_config, {
as_host="autoscaling.amazonaws.com"::string(),
ec2_host="ec2.amazonaws.com"::string(),
iam_host="iam.amazonaws.com"::string(),
sts_host="sts.amazonaws.com"::string(),
s3_scheme="https://"::string(),
s3_host="s3.amazonaws.com"::string(),
s3_port=80::non_neg_integer(),
sdb_host="sdb.amazonaws.com"::string(),
elb_host="elasticloadbalancing.amazonaws.com"::string(),
ses_host="email.us-east-1.amazonaws.com"::string(),
sqs_host="queue.amazonaws.com"::string(),
sqs_protocol=undefined::string()|undefined,
sqs_port=undefined::non_neg_integer()|undefined,
sns_scheme="http://"::string(),
sns_host="sns.amazonaws.com"::string(),
mturk_host="mechanicalturk.amazonaws.com"::string(),
mon_host="monitoring.amazonaws.com"::string(),
mon_port=undefined::non_neg_integer()|undefined,
mon_protocol=undefined::string()|undefined,
ddb_scheme="https://"::string(),
ddb_host="dynamodb.us-east-1.amazonaws.com"::string(),
ddb_port=80::non_neg_integer(),
ddb_retry=fun erlcloud_ddb_impl:retry/1::erlcloud_ddb_impl:retry_fun(),
kinesis_scheme="https://"::string(),
kinesis_host="kinesis.us-east-1.amazonaws.com"::string(),
kinesis_port=80::non_neg_integer(),
kinesis_retry=fun erlcloud_kinesis_impl:retry/2::erlcloud_kinesis_impl:retry_fun(),
cloudtrail_scheme="https://"::string(),
cloudtrail_host="cloudtrail.amazonaws.com"::string(),
cloudtrail_port=80::non_neg_integer(),
access_key_id::string()|undefined|false,
secret_access_key::string()|undefined|false,
security_token=undefined::string()|undefined,
timeout=10000::timeout(),
cloudtrail_raw_result=false::boolean(),
http_client=lhttpc::erlcloud_httpc:request_fun(),
%% Default to not retry failures (for backwards compatability).
%% Recommended to be set to default_retry to provide recommended retry behavior.
%% Currently only affects S3, but intent is to change other services to use this as well.
%% If you provide a custom function be aware of this anticipated change.
%% See erlcloud_retry for full documentation.
retry=fun erlcloud_retry:no_retry/1::erlcloud_retry:retry_fun()
}).
-type(aws_config() :: #aws_config{}).
-record(aws_request,
{
%% Provided by requesting service
service :: s3,
uri :: string() | binary(),
method :: atom(),
request_headers :: [{string(), string()}],
request_body :: binary(),
%% Read from response
attempt = 0 :: integer(),
response_type :: ok | error,
error_type :: aws | httpc,
httpc_error_reason :: term(),
response_status :: pos_integer(),
response_status_line :: string(),
response_headers :: [{string(), string()}],
response_body :: binary(),
%% Service specific error information
should_retry :: boolean()
}).