SlideShare a Scribd company logo
1 of 47
Download to read offline
© 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Preston Tamkin and Jonathan Henson
October 2015
DEV204
AWS SDK for C++
Building High-Performance, Native Cloud
Apps in C++
Agenda
• Overview of the AWS SDK for C++
• github.com/awslabs/aws-sdk-cpp
• Core library features
• Credential management
• Logging
• Asynchronous requests
• Rate limiting
• Error handling
• Memory allocation
• Streaming
• Overriding the HTTP/TLS stack
• High-level APIs overview
Getting started
What is it?
• Modern C++ language bindings for AWS
• Generated service clients + high-level APIs
Source
• github.com/awslabs/aws-sdk-cpp
Build Prerequisites
• C++11-compatible compiler
• CMake
• A HTTP/TLS implementation for your platform
– We ship Curl, WinHTTP, and WinINet interfaces
Sample
1 DynamoDBClient client;
2 AttributeValue hashKeyAttribute;
3 hashKeyAttribute.SetS(“SampleHashKeyValue”);
4 AttributeValue valueAttribute;
5 valueAttribute.SetS(“SampleValue”);
6
7 PutItemRequest putItemRequest;
8 putItemRequest.WithTableName(“TestTableName”)
9 .AddItem(“HashKey”, hashKeyAttribute).AddItem(“Value”, valueAttribute);
10
11 client.PutItem(putItemRequest);
12
13
Credential management
• AWSCredentialsProvider interface
• Core library includes
• EnvironmentAWSCredentialsProvider
• ProfileConfigFileAWSCredentialsProvider
• InstanceProfileCredentialsProvider
• DefaultAWSCredentialsProviderChain (chains the above)
• Amazon Cognito identity providers included
• Custom providers supported
Credentials
1 auto credentialProvider = Aws::MakeShared<InstanceProfileCredentialsProvider >(“re:InventSample”);
2 DynamoDBClient client(credentialProvider);
SDK logging
• Internal logging interface for SDK diagnostics
• No external dependencies
• Default implementation logs to local filesystem
Logging
1 Aws::Utils::Logging::InitializeAWSLogging(Aws::MakeShared<Aws::Utils::Logging::DefaultLogSystem>(“re:InventSample”,
2 Aws::Utils::Logging::LogLevel::Trace, “aws_"));
3 auto credentialProvider = Aws::MakeShared<InstanceProfileCredentialsProvider >(“re:InventSample”);
4 DynamoDBClient client(credentialProvider);
15 Aws::Utils::Logging::ShutdownAWSLogging();
ClientConfiguration
• Optional parameter for client constructors
• Plain old data
• Contains per-client configuration and overrides
Async
• All generated operations have an async version
• Async requests notify your callback function
• Callback receives client, request, outcome, and
optional context objects
• Pluggable custom executor for more control
Async
1 void putItemFinished(const DynamoDBClient* client, const PutItemRequest& request,
2 const PutItemOutcome& outcome,
3 const std::shared_ptr<AsyncContext>& context)
4 {
5 If (outcome.IsSuccess())
6 {
7 SEND_QUEUE.erase(context->GetUUIID());
8 }
9 }
10
11 auto context = Aws::MakeShared<AsyncContext>(“re:invent sample”);
12 context.SetUUID(“UniqueRequestKey”);
13 SEND_QUEUE[“UniqueRequestKey”] = putItemRequest;
14 client.PutItemAsync(putItemRequest, &putItemFinished, context);
Async with member functions
1 void ReinventSample::putItemFinished(const DynamoDBClient* client, const PutItemRequest& request,
2 const PutItemOutcome& outcome,
3 const shared_ptr<AsyncContext>& context)
7 m_sendQueue.erase(context->GetUUIID());
13 m_sendQueue[“UniqueRequestKey”] = putItemRequest;
std::bind(&ReinventSample::putItemFinished, this, std::placeholders::_1,
15 std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)
Asynchronous executor
• Default executor will spawn a detached thread
• Implement executor for more control
• Use this to tie asynchronous calls to your system’s
custom thread pool
Asynchronous executor
1 #include <aws/core/utils/threading/Executor.h>
2
3 class CustomExecutor : public Aws::Utils::Threading::Executor
4 {
5 public:
6 CustomExecutor(MySystemsExecutorImpl* executor) : m_executor(executor)
7
8 protected:
9 bool SubmitToThread(std::function<void()>&& task) override
10 {
11 return m_executor->QueueTask(std::forward<std::function<void()>(task));
12 }
13
14 private:
15 MySystemsExecutorImpl* m_executor;
16 };
Asynchronous executor
1 ClientConfiguration config;
2 auto mySystemsExecutorImpl = applicationConfiguration->GetExecutor();
3 config.executor = mySystemsExecutorImpl;
4
5 DynamoDBClient client(config);
client.PutItemAsync(putItemRequest, &putItemFinished);
Rate limiting
• Client-side bandwidth throttling at the HTTP layer
• Configurable separately for each client and each
directionality (uploads and downloads)
Rate limiting
1 class CustomRateLimiter : public Aws::Utils::RateLimits::RateLimiterInterface
2 {
3 public:
4 ….
5
6 DelayType ApplyCost(int64_t cost) override
7 {
8 m_availableBandwidth -= cost;
9 return m_availableBandwidth > 0 ? DelayType(0) : DelayType(0 – m_availableBandwidth);
10 }
11
12 void ApplyAndPayForCost(int64_t cost) override
13 {
14 std::this_thread::sleep_for(ApplyCost(cost));
15 m_availableBandwidth += cost;
16 }
17 …
18 };
Rate limiting
1 ClientConfiguration config;
2 auto downloadLimiter = Aws::MakeShared<CustomRateLimiter>(“re:InventSample”, FIVE_MB);
3 auto uploadLimiter =
4 Aws::MakeShared<CustomRateLimiter>(“re:InventSample”, TWO_HUNDRED_KB);
5 config.readRateLimiter = downloadLimiter;
6 config.writeRateLimiter = uploadLimiter;
7 DynamoDBClient client(config);
Rate limiting
Recommendations and things to know:
• Default rate limiter implementation probably does what
you want. (#include
<aws/core/utils/ratelimiter/DefaultRateLimiter.h> )
• Calculation made at IO time not request size.
Error handling
• No exceptions used internally or thrown externally
• Performance and flexibility reasons
• SDK is exception-safe
• Exceptions are safe to use in your application
Error handling
• Requests return an ‘Outcome’ object.
• An ‘Outcome’ is either successful with a result payload
or unsuccessful with an error payload
• Errors closely match exception names from other
SDKs
Error handling and the outcome pattern
1 PutItemOutcome outcome = client.PutItem(putItemRequest);
2 If (outcome.IsSuccess())
3 {
4 std::cout << outcome.GetResult().GetConsumedCapacity().GetCapacityUnits() <<
5 “ Capacity Consumed” << std::endl;
6 }
7 else
8 {
9 If (outcome.GetError().GetErrorType() == DynamoDbErrors::CONDITIONAL_CHECK_FAILED)
10 {
11 std::cout << “Conditional Write failed. “
12 << “ Message: “ << outcome.GetError().GetMessage() << std::endl;
13 }
14 else
15 {
16 std::cout << “Unexpected error “ << outcome.GetError().GetMessage() << std::endl;
17 }
18 }
Retry strategies
• Default retry strategy
• Overridable per client
• Offers more granular support your application
Retry strategies
1 class ExponentialBackOffStrategy : public Aws::Client::RetryStrategy
2 {
3 public:
4 bool ShouldRetry(const AWSError<CoreErrors>& error, long attemptedRetries) const
5 {
6 If (attemptedRetries < 5) return error.ShouldRetry();
7
8 return false;
9 }
10
11 long CalculateDelayBeforeNextRetry(const AWSError<CoreErrors>& error, long attemptedRetries) const
12 {
13 If (attemptedRetries == 0) return 0;
14
15 return (1 << attemptedRetries) * 25;
16 }
17 };
18
Retry strategies
1 ClientConfiguration config;
2 auto retryStrategy =
3 Aws::MakeShared<ExponentialBackoffStrategy>(“re:inventSample”);
4 config.retryStrategy = retryStrategy;
5 DynamoDBClient client(config);
Memory allocation
• Configured at compile time
• Custom Allocators installed at runtime
• Default forces allocation into single allocator
• On by default for dynamic libraries
• What about the STL?
Memory allocation
1 class DlMallocMemorySystem : public MemorySystemInterface
2 {
3 public:
4 ~DlMallocMemorySystem() = default;
5
6 void Begin() override {}
7 void End() override {}
8
9 void* AllocateMemory(std::size_t blockSize, std::size_t alignment, const char* allocationTag = nullptr) override
10 {
11 return dlmalloc(blockSize);
12 }
13
14 void FreeMemory(void* memoryPtr) override
15 {
16 dlfree(memoryPtr);
17 }
18 };
Memory allocation
1 DlMallocMemorySystem dlMallocMemorySystem;
2 Aws::Utils::Memory::InitializeAWSMemorySystem(dlMallocMemorySystem);
14 Aws::Utils::Memory::ShutdownAWSMemorySystem();
Memory allocation
What about the Standard Template Library?
• Use AWS-defined STL types (Aws::Vector, Aws::String,
Aws::Map, Aws::IOStream, etc.)
• Automatically resolves allocator
• Compile time switch
• Most APIs take primitives as well
Memory allocation
General advice
• Use custom memory management with dynamic
linking -- especially on Windows
• Do not use STL containers directly
• Do not use new or delete directly
• Do not use std smart pointer APIs directly
• Use –DAWS_CUSTOM_MEMORY_MANAGEMENT
w/ custom memory management
Streaming requests and responses
• Some payloads are not typed (example: Amazon S3
GetObject, PutObject)
• Use the STL IOStream interface.
• Defaults to underlying StringBuf
• Easily overridable
Streaming requests
1 S3Client client;
2 PutObjectRequest putObjectRequest;
3 putObjectRequest.SetBucketName(“reinvent_sample_bucket”);
4 putObjectRequest.SetKeyName(“reinvent_sample_key”);
5
6 auto fileToUpload = Aws::MakeShared<Aws::FStream>(“re:InventSample”,
7 “users/me/toUpload/fileToUpload.png”, std::ios_in);
8 putObjectRequest.SetBody(fileToUpload);
9
10 auto outcome = client.PutObject(putObjectRequest);
11
12
Streaming responses
1 S3Client client;
2 GetObjectRequest getObjectRequest;
3 getObjectRequest.SetBucketName(“reinvent_sample_bucket”);
4 getObjectRequest.SetKeyName(“reinvent_sample_key”);
5 getObjectRequest.SetResponseStreamFactory(
6 [](){
7 return Aws::New<Aws::FStream>(“re:InventSample”, “/users/me/downloads/filename.png”,
8 std::ios_base::in | std::ios_base::out | std::ios_base::trunc);
9 });
10
11 auto outcome = client.GetObject(getObjectRequest);
12 ….
Overriding the HTTP/TLS stack
I want to use my own IO stack. What do I do?
• HTTP stacks can be injected into clients
• Implement your own HttpClient
• Simply override the HttpClientFactory in your
ClientConfiguration
Overriding the HTTP/TLS stack
1 class LibUVWithSignalToNoiseHttpClient : public Aws::Http::HttpClient
2 {
3 public:
4 virtual ~LibUVWithSignalToNoiseHttpClient () {}
5
6 std::shared_ptr<HttpResponse> MakeRequest(HttpRequest& request,
7 Aws::Utils::RateLimits::RateLimiterInterface* readLimiter = nullptr,
8 Aws::Utils::RateLimits::RateLimiterInterface* writeLimiter = nullptr) const override;
9 };
10
Overriding the HTTP/TLS stack
1 class LibUVWithSignalToNoiseHttpClientFactory : public Aws::Http::HttpClientFactory
2 {
3 public:
4 virtual ~LibUVWithSignalToNoiseHttpClientFactory() {}
5
6 std::shared_ptr<HttpClient> CreateHttpClient
7 (const Aws::Client::ClientConfiguration& clientConfiguration) const override;
8
9 virtual std::shared_ptr<HttpRequest> CreateHttpRequest(const Aws::String& uri, HttpMethod method,
10 const Aws::IOStreamFactory& streamFactory) const override;
11
12 virtual std::shared_ptr<HttpRequest> CreateHttpRequest(const URI& uri, HttpMethod method,
13 const Aws::IOStreamFactory& streamFactory) const override;
14 };
Overriding the Http/TLS stack
1 auto httpClientFactory = Aws::MakeShared<LibUVWithSignalToNoiseHttpClientFactory>(“re:InventSample”);
2 DynamoDBClient client(credentialProvider, config, httpClientFactory);
High-level APIs
• Amazon Cognito identity providers
• Amazon S3 Transfer Manager
• Queues-like interface for Amazon SQS
• Access management API for IAM
High-level APIs
1 auto credentialsProvider =
2 Aws::MakeShared<CognitoCachingAnonymousCredentialsProvider>(“re:invent sample”,
3 “55216815”, “us-east-1:65814ddc-1479-4dfe-9bab-254541asd2fb”);
4
5 DynamoDBClient dynamoDbClient(credentialsProvider);
6
Identity management with an anonymous identity pool
High-level APIs
1 auto identityProvider =
2 Aws::MakeShared<DefaultPersistentCognitoIdentityProvider>(“re:invent sample”);
3 Aws::Map<Aws::String, LoginAccessTokens> tokens;
4 tokens[“www.amazon.com”] = LoginAccessTokens { “aegedeev”, “bdekibnkoga”, ONE_HOUR };
5 identityProvider->PersistLogins(tokens);
6
7 auto credentialsProvider =
8 Aws::MakeShared<CognitoCachingAuthenticatedCredentialsProvider>(“re:invent sample”,
9 “55216815”, “us-east-1:65814ddc-1479-4dfe-9bab-254541asd2fb”,
10 identityProvider);
11 DynamoDBClient dynamoDbClient(credentialsProvider);
Identity management with an authenticated identity pool
High-level APIs
1 auto s3Client = Aws::MakeShared<S3Client>(“re:invent sample”);
2 TransferClient transferClient(s3Client, TransferClientConfiguration { 10, nullptr } );
3
4 auto uploadFileRequest =
5 transferClient.UploadFile(“/home/user/customer/myDatabase.frm”,
6 “sample_bucket”, “sample_key”, “application/octet-stream”);
Uploading a large file with Transfer Manager
High-level APIs
1 auto sqsClient = Aws::MakeShared<SQSClient>(“reinvent sample”);
2 SQSQueue queue(sqsClient, “sample_queue”, FIFTEEN_SEC);
3 queue.SetMessageRecievedEventHandler(
4 std::bind(&ReinventSample::OnMessageRecieved, this,
5 std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
6 queue.EnsureQueueIsInitialized();
7 queue.StartPolling();
8
9 void ReinventSample::OnMessageRecieved(const Queue* queue,
10 const Message& message , bool& deleteMessage)
11 {
12 auto msgBody = message.GetBody();
13 deleteMessage = SEND_IPC_MESSAGE(Q_ID, msgBody) != -1;
14 }
Receiving async message notifications via queues
High-level APIs
Contributing high-level APIs
• Please do!
• Follow contribution guidelines outlined in readme
• Use constructor injection for low-level clients
Takeaways
• Overview of the AWS SDK for C++
• github.com/awslabs/aws-sdk-cpp
• Core library features
• Credential management
• Logging
• Asynchronous requests
• Rate limiting
• Error handling
• Memory allocation
• Streaming
• Overriding the HTTP/TLS stack
• High-level APIs overview
© 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Send us pull requests @
github.com/awslabs/aws-sdk-cpp
Thank you!
Remember to complete
your evaluations!

More Related Content

What's hot

From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...Jérôme Petazzoni
 
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기Kee Hoon Lee
 
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017Amazon Web Services
 
Infra as Code with Packer, Ansible and Terraform
Infra as Code with Packer, Ansible and TerraformInfra as Code with Packer, Ansible and Terraform
Infra as Code with Packer, Ansible and TerraformInho Kang
 
Twitter의 snowflake 소개 및 활용
Twitter의 snowflake 소개 및 활용Twitter의 snowflake 소개 및 활용
Twitter의 snowflake 소개 및 활용흥배 최
 
[NDC17] Kubernetes로 개발서버 간단히 찍어내기
[NDC17] Kubernetes로 개발서버 간단히 찍어내기[NDC17] Kubernetes로 개발서버 간단히 찍어내기
[NDC17] Kubernetes로 개발서버 간단히 찍어내기SeungYong Oh
 
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈Amazon Web Services Korea
 
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...Amazon Web Services Korea
 
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...Amazon Web Services
 
MySQL Document Store를 활용한 NoSQL 개발
MySQL Document Store를 활용한 NoSQL 개발MySQL Document Store를 활용한 NoSQL 개발
MySQL Document Store를 활용한 NoSQL 개발Oracle Korea
 
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQS
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQSAWS Black Belt Techシリーズ Amazon SNS / Amazon SQS
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQSAmazon Web Services Japan
 
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017Amazon Web Services Korea
 
Build Low-Latency Applications in Rust on ScyllaDB
Build Low-Latency Applications in Rust on ScyllaDBBuild Low-Latency Applications in Rust on ScyllaDB
Build Low-Latency Applications in Rust on ScyllaDBScyllaDB
 
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018Amazon Web Services Korea
 
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive [2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive Amazon Web Services Korea
 
[112]rest에서 graph ql과 relay로 갈아타기 이정우
[112]rest에서 graph ql과 relay로 갈아타기 이정우[112]rest에서 graph ql과 relay로 갈아타기 이정우
[112]rest에서 graph ql과 relay로 갈아타기 이정우NAVER D2
 
Java null survival guide
Java null survival guideJava null survival guide
Java null survival guideSungchul Park
 
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021AWSKRUG - AWS한국사용자모임
 

What's hot (20)

From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...
 
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
 
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017
Best Practices for Running PostgreSQL on AWS - DAT314 - re:Invent 2017
 
Infra as Code with Packer, Ansible and Terraform
Infra as Code with Packer, Ansible and TerraformInfra as Code with Packer, Ansible and Terraform
Infra as Code with Packer, Ansible and Terraform
 
Twitter의 snowflake 소개 및 활용
Twitter의 snowflake 소개 및 활용Twitter의 snowflake 소개 및 활용
Twitter의 snowflake 소개 및 활용
 
[NDC17] Kubernetes로 개발서버 간단히 찍어내기
[NDC17] Kubernetes로 개발서버 간단히 찍어내기[NDC17] Kubernetes로 개발서버 간단히 찍어내기
[NDC17] Kubernetes로 개발서버 간단히 찍어내기
 
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈
[Gaming on AWS] AWS와 함께 한 쿠키런 서버 Re-architecting 사례 - 데브시스터즈
 
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...
PUBG: Battlegrounds 라이브 서비스 EKS 전환 사례 공유 [크래프톤 - 레벨 300] - 발표자: 김정헌, PUBG Dev...
 
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...
ElastiCache Deep Dive: Best Practices and Usage Patterns - March 2017 AWS Onl...
 
MySQL Document Store를 활용한 NoSQL 개발
MySQL Document Store를 활용한 NoSQL 개발MySQL Document Store를 활용한 NoSQL 개발
MySQL Document Store를 활용한 NoSQL 개발
 
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQS
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQSAWS Black Belt Techシリーズ Amazon SNS / Amazon SQS
AWS Black Belt Techシリーズ Amazon SNS / Amazon SQS
 
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017
AWS 클라우드 기반 게임 아키텍처 사례 - AWS Summit Seoul 2017
 
AWS Fargate on EKS 실전 사용하기
AWS Fargate on EKS 실전 사용하기AWS Fargate on EKS 실전 사용하기
AWS Fargate on EKS 실전 사용하기
 
Build Low-Latency Applications in Rust on ScyllaDB
Build Low-Latency Applications in Rust on ScyllaDBBuild Low-Latency Applications in Rust on ScyllaDB
Build Low-Latency Applications in Rust on ScyllaDB
 
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018
아마존 웹 서비스 상에서 MS SQL 100% 활용하기::김석원::AWS Summit Seoul 2018
 
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive [2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive
[2017 AWS Startup Day] AWS 비용 최대 90% 절감하기: 스팟 인스턴스 Deep-Dive
 
Helm intro
Helm introHelm intro
Helm intro
 
[112]rest에서 graph ql과 relay로 갈아타기 이정우
[112]rest에서 graph ql과 relay로 갈아타기 이정우[112]rest에서 graph ql과 relay로 갈아타기 이정우
[112]rest에서 graph ql과 relay로 갈아타기 이정우
 
Java null survival guide
Java null survival guideJava null survival guide
Java null survival guide
 
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021
Amazon EKS로 간단한 웹 애플리케이션 구축하기 - 김주영 (AWS) :: AWS Community Day Online 2021
 

Viewers also liked

Dipping Your Toes Into Cloud Native Application Development
Dipping Your Toes Into Cloud Native Application DevelopmentDipping Your Toes Into Cloud Native Application Development
Dipping Your Toes Into Cloud Native Application DevelopmentMatthew Farina
 
Hybrid Infrastructure Integration
Hybrid Infrastructure IntegrationHybrid Infrastructure Integration
Hybrid Infrastructure IntegrationAmazon Web Services
 
Scaling by Design: AWS Web Services Patterns
Scaling by Design:AWS Web Services PatternsScaling by Design:AWS Web Services Patterns
Scaling by Design: AWS Web Services PatternsAmazon Web Services
 
Encryption and Key Management in AWS
Encryption and Key Management in AWSEncryption and Key Management in AWS
Encryption and Key Management in AWSAmazon Web Services
 
Data Storage for the Long Haul: Compliance and Archive
Data Storage for the Long Haul: Compliance and ArchiveData Storage for the Long Haul: Compliance and Archive
Data Storage for the Long Haul: Compliance and ArchiveAmazon Web Services
 
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...Amazon Web Services
 
AWS March 2016 Webinar Series Getting Started with Serverless Architectures
AWS March 2016 Webinar Series   Getting Started with Serverless ArchitecturesAWS March 2016 Webinar Series   Getting Started with Serverless Architectures
AWS March 2016 Webinar Series Getting Started with Serverless ArchitecturesAmazon Web Services
 
AWS APAC Webinar Week - Understanding AWS Storage Options
AWS APAC Webinar Week - Understanding AWS Storage OptionsAWS APAC Webinar Week - Understanding AWS Storage Options
AWS APAC Webinar Week - Understanding AWS Storage OptionsAmazon Web Services
 
AWS Mobile Services & SDK Introduction & Demo
AWS Mobile Services & SDK Introduction & DemoAWS Mobile Services & SDK Introduction & Demo
AWS Mobile Services & SDK Introduction & DemoAmazon Web Services
 
The Pace of Innovation - Pop-up Loft Tel Aviv
The Pace of Innovation - Pop-up Loft Tel AvivThe Pace of Innovation - Pop-up Loft Tel Aviv
The Pace of Innovation - Pop-up Loft Tel AvivAmazon Web Services
 
Workshop: AWS Lamda Signal Corps vs Zombies
Workshop: AWS Lamda Signal Corps vs ZombiesWorkshop: AWS Lamda Signal Corps vs Zombies
Workshop: AWS Lamda Signal Corps vs ZombiesAmazon Web Services
 
Compute Without Servers – Building Applications with AWS Lambda - Technical 301
Compute Without Servers – Building Applications with AWS Lambda - Technical 301Compute Without Servers – Building Applications with AWS Lambda - Technical 301
Compute Without Servers – Building Applications with AWS Lambda - Technical 301Amazon Web Services
 
(NET307) Pinterest: The road from EC2-Classic To EC2-VPC
(NET307) Pinterest: The road from EC2-Classic To EC2-VPC(NET307) Pinterest: The road from EC2-Classic To EC2-VPC
(NET307) Pinterest: The road from EC2-Classic To EC2-VPCAmazon Web Services
 
Security Day IAM Recommended Practices
Security Day IAM Recommended PracticesSecurity Day IAM Recommended Practices
Security Day IAM Recommended PracticesAmazon Web Services
 
Ansible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAnsible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAmazon Web Services
 
Grid Computing for Financial Services
Grid Computing for Financial ServicesGrid Computing for Financial Services
Grid Computing for Financial ServicesAmazon Web Services
 
Getting Started with Amazon Enterprise Applications
Getting Started with Amazon Enterprise ApplicationsGetting Started with Amazon Enterprise Applications
Getting Started with Amazon Enterprise ApplicationsAmazon Web Services
 

Viewers also liked (20)

Dipping Your Toes Into Cloud Native Application Development
Dipping Your Toes Into Cloud Native Application DevelopmentDipping Your Toes Into Cloud Native Application Development
Dipping Your Toes Into Cloud Native Application Development
 
Hybrid Infrastructure Integration
Hybrid Infrastructure IntegrationHybrid Infrastructure Integration
Hybrid Infrastructure Integration
 
Scaling by Design: AWS Web Services Patterns
Scaling by Design:AWS Web Services PatternsScaling by Design:AWS Web Services Patterns
Scaling by Design: AWS Web Services Patterns
 
Encryption and Key Management in AWS
Encryption and Key Management in AWSEncryption and Key Management in AWS
Encryption and Key Management in AWS
 
Agile BI - Pop-up Loft Tel Aviv
Agile BI - Pop-up Loft Tel AvivAgile BI - Pop-up Loft Tel Aviv
Agile BI - Pop-up Loft Tel Aviv
 
Data Storage for the Long Haul: Compliance and Archive
Data Storage for the Long Haul: Compliance and ArchiveData Storage for the Long Haul: Compliance and Archive
Data Storage for the Long Haul: Compliance and Archive
 
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...
Get the Most Out of Amazon EC2: A Deep Dive on Reserved, On-Demand, and Spot ...
 
AWS March 2016 Webinar Series Getting Started with Serverless Architectures
AWS March 2016 Webinar Series   Getting Started with Serverless ArchitecturesAWS March 2016 Webinar Series   Getting Started with Serverless Architectures
AWS March 2016 Webinar Series Getting Started with Serverless Architectures
 
AWS APAC Webinar Week - Understanding AWS Storage Options
AWS APAC Webinar Week - Understanding AWS Storage OptionsAWS APAC Webinar Week - Understanding AWS Storage Options
AWS APAC Webinar Week - Understanding AWS Storage Options
 
AWS Mobile Services & SDK Introduction & Demo
AWS Mobile Services & SDK Introduction & DemoAWS Mobile Services & SDK Introduction & Demo
AWS Mobile Services & SDK Introduction & Demo
 
Deep Dive: Hybrid Architectures
Deep Dive: Hybrid ArchitecturesDeep Dive: Hybrid Architectures
Deep Dive: Hybrid Architectures
 
The Pace of Innovation - Pop-up Loft Tel Aviv
The Pace of Innovation - Pop-up Loft Tel AvivThe Pace of Innovation - Pop-up Loft Tel Aviv
The Pace of Innovation - Pop-up Loft Tel Aviv
 
Workshop: AWS Lamda Signal Corps vs Zombies
Workshop: AWS Lamda Signal Corps vs ZombiesWorkshop: AWS Lamda Signal Corps vs Zombies
Workshop: AWS Lamda Signal Corps vs Zombies
 
Compute Without Servers – Building Applications with AWS Lambda - Technical 301
Compute Without Servers – Building Applications with AWS Lambda - Technical 301Compute Without Servers – Building Applications with AWS Lambda - Technical 301
Compute Without Servers – Building Applications with AWS Lambda - Technical 301
 
(NET307) Pinterest: The road from EC2-Classic To EC2-VPC
(NET307) Pinterest: The road from EC2-Classic To EC2-VPC(NET307) Pinterest: The road from EC2-Classic To EC2-VPC
(NET307) Pinterest: The road from EC2-Classic To EC2-VPC
 
Security Day IAM Recommended Practices
Security Day IAM Recommended PracticesSecurity Day IAM Recommended Practices
Security Day IAM Recommended Practices
 
Ansible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAnsible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel Aviv
 
My First Big Data Application
My First Big Data ApplicationMy First Big Data Application
My First Big Data Application
 
Grid Computing for Financial Services
Grid Computing for Financial ServicesGrid Computing for Financial Services
Grid Computing for Financial Services
 
Getting Started with Amazon Enterprise Applications
Getting Started with Amazon Enterprise ApplicationsGetting Started with Amazon Enterprise Applications
Getting Started with Amazon Enterprise Applications
 

Similar to (DEV204) Building High-Performance Native Cloud Apps In C++

Building and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsBuilding and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsOhad Kravchick
 
Samsung WebCL Prototype API
Samsung WebCL Prototype APISamsung WebCL Prototype API
Samsung WebCL Prototype APIRyo Jin
 
How to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinHow to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinSigma Software
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.jsorkaplan
 
Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...Docker, Inc.
 
Advanced iOS Build Mechanics, Sebastien Pouliot
Advanced iOS Build Mechanics, Sebastien PouliotAdvanced iOS Build Mechanics, Sebastien Pouliot
Advanced iOS Build Mechanics, Sebastien PouliotXamarin
 
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...ScyllaDB
 
Developing your first application using FIWARE
Developing your first application using FIWAREDeveloping your first application using FIWARE
Developing your first application using FIWAREFIWARE
 
Writing robust Node.js applications
Writing robust Node.js applicationsWriting robust Node.js applications
Writing robust Node.js applicationsTom Croucher
 
Solving anything in VCL
Solving anything in VCLSolving anything in VCL
Solving anything in VCLFastly
 
Angular 1 + es6
Angular 1 + es6Angular 1 + es6
Angular 1 + es6장현 한
 
Practical AngularJS
Practical AngularJSPractical AngularJS
Practical AngularJSWei Ru
 
Hazelcast and MongoDB at Cloud CMS
Hazelcast and MongoDB at Cloud CMSHazelcast and MongoDB at Cloud CMS
Hazelcast and MongoDB at Cloud CMSuzquiano
 
Original slides from Ryan Dahl's NodeJs intro talk
Original slides from Ryan Dahl's NodeJs intro talkOriginal slides from Ryan Dahl's NodeJs intro talk
Original slides from Ryan Dahl's NodeJs intro talkAarti Parikh
 
2016 W3C Conference #4 : ANGULAR + ES6
2016 W3C Conference #4 : ANGULAR + ES62016 W3C Conference #4 : ANGULAR + ES6
2016 W3C Conference #4 : ANGULAR + ES6양재동 코드랩
 
#3 (Multi Threads With TCP)
#3 (Multi Threads With TCP)#3 (Multi Threads With TCP)
#3 (Multi Threads With TCP)Ghadeer AlHasan
 
JavaOne 2017 - TestContainers: integration testing without the hassle
JavaOne 2017 - TestContainers: integration testing without the hassleJavaOne 2017 - TestContainers: integration testing without the hassle
JavaOne 2017 - TestContainers: integration testing without the hassleAnton Arhipov
 
Spring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenSpring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenJoshua Long
 

Similar to (DEV204) Building High-Performance Native Cloud Apps In C++ (20)

Building and Scaling Node.js Applications
Building and Scaling Node.js ApplicationsBuilding and Scaling Node.js Applications
Building and Scaling Node.js Applications
 
Samsung WebCL Prototype API
Samsung WebCL Prototype APISamsung WebCL Prototype API
Samsung WebCL Prototype API
 
How to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita GalkinHow to make a high-quality Node.js app, Nikita Galkin
How to make a high-quality Node.js app, Nikita Galkin
 
Curator intro
Curator introCurator intro
Curator intro
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.js
 
Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...Online Meetup: Why should container system / platform builders care about con...
Online Meetup: Why should container system / platform builders care about con...
 
Advanced iOS Build Mechanics, Sebastien Pouliot
Advanced iOS Build Mechanics, Sebastien PouliotAdvanced iOS Build Mechanics, Sebastien Pouliot
Advanced iOS Build Mechanics, Sebastien Pouliot
 
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...
Scylla Summit 2018: Introducing ValuStor, A Memcached Alternative Made to Run...
 
Developing your first application using FIWARE
Developing your first application using FIWAREDeveloping your first application using FIWARE
Developing your first application using FIWARE
 
Writing robust Node.js applications
Writing robust Node.js applicationsWriting robust Node.js applications
Writing robust Node.js applications
 
Solving anything in VCL
Solving anything in VCLSolving anything in VCL
Solving anything in VCL
 
Angular 1 + es6
Angular 1 + es6Angular 1 + es6
Angular 1 + es6
 
Practical AngularJS
Practical AngularJSPractical AngularJS
Practical AngularJS
 
Hazelcast and MongoDB at Cloud CMS
Hazelcast and MongoDB at Cloud CMSHazelcast and MongoDB at Cloud CMS
Hazelcast and MongoDB at Cloud CMS
 
Original slides from Ryan Dahl's NodeJs intro talk
Original slides from Ryan Dahl's NodeJs intro talkOriginal slides from Ryan Dahl's NodeJs intro talk
Original slides from Ryan Dahl's NodeJs intro talk
 
[W3C HTML5 2016] Angular + ES6
[W3C HTML5 2016] Angular + ES6[W3C HTML5 2016] Angular + ES6
[W3C HTML5 2016] Angular + ES6
 
2016 W3C Conference #4 : ANGULAR + ES6
2016 W3C Conference #4 : ANGULAR + ES62016 W3C Conference #4 : ANGULAR + ES6
2016 W3C Conference #4 : ANGULAR + ES6
 
#3 (Multi Threads With TCP)
#3 (Multi Threads With TCP)#3 (Multi Threads With TCP)
#3 (Multi Threads With TCP)
 
JavaOne 2017 - TestContainers: integration testing without the hassle
JavaOne 2017 - TestContainers: integration testing without the hassleJavaOne 2017 - TestContainers: integration testing without the hassle
JavaOne 2017 - TestContainers: integration testing without the hassle
 
Spring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in HeavenSpring and Cloud Foundry; a Marriage Made in Heaven
Spring and Cloud Foundry; a Marriage Made in Heaven
 

More from Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

More from Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Recently uploaded

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 

Recently uploaded (20)

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 

(DEV204) Building High-Performance Native Cloud Apps In C++

  • 1. © 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Preston Tamkin and Jonathan Henson October 2015 DEV204 AWS SDK for C++ Building High-Performance, Native Cloud Apps in C++
  • 2. Agenda • Overview of the AWS SDK for C++ • github.com/awslabs/aws-sdk-cpp • Core library features • Credential management • Logging • Asynchronous requests • Rate limiting • Error handling • Memory allocation • Streaming • Overriding the HTTP/TLS stack • High-level APIs overview
  • 3. Getting started What is it? • Modern C++ language bindings for AWS • Generated service clients + high-level APIs Source • github.com/awslabs/aws-sdk-cpp Build Prerequisites • C++11-compatible compiler • CMake • A HTTP/TLS implementation for your platform – We ship Curl, WinHTTP, and WinINet interfaces
  • 4. Sample 1 DynamoDBClient client; 2 AttributeValue hashKeyAttribute; 3 hashKeyAttribute.SetS(“SampleHashKeyValue”); 4 AttributeValue valueAttribute; 5 valueAttribute.SetS(“SampleValue”); 6 7 PutItemRequest putItemRequest; 8 putItemRequest.WithTableName(“TestTableName”) 9 .AddItem(“HashKey”, hashKeyAttribute).AddItem(“Value”, valueAttribute); 10 11 client.PutItem(putItemRequest); 12 13
  • 5. Credential management • AWSCredentialsProvider interface • Core library includes • EnvironmentAWSCredentialsProvider • ProfileConfigFileAWSCredentialsProvider • InstanceProfileCredentialsProvider • DefaultAWSCredentialsProviderChain (chains the above) • Amazon Cognito identity providers included • Custom providers supported
  • 6. Credentials 1 auto credentialProvider = Aws::MakeShared<InstanceProfileCredentialsProvider >(“re:InventSample”); 2 DynamoDBClient client(credentialProvider);
  • 7. SDK logging • Internal logging interface for SDK diagnostics • No external dependencies • Default implementation logs to local filesystem
  • 8. Logging 1 Aws::Utils::Logging::InitializeAWSLogging(Aws::MakeShared<Aws::Utils::Logging::DefaultLogSystem>(“re:InventSample”, 2 Aws::Utils::Logging::LogLevel::Trace, “aws_")); 3 auto credentialProvider = Aws::MakeShared<InstanceProfileCredentialsProvider >(“re:InventSample”); 4 DynamoDBClient client(credentialProvider); 15 Aws::Utils::Logging::ShutdownAWSLogging();
  • 9. ClientConfiguration • Optional parameter for client constructors • Plain old data • Contains per-client configuration and overrides
  • 10. Async • All generated operations have an async version • Async requests notify your callback function • Callback receives client, request, outcome, and optional context objects • Pluggable custom executor for more control
  • 11. Async 1 void putItemFinished(const DynamoDBClient* client, const PutItemRequest& request, 2 const PutItemOutcome& outcome, 3 const std::shared_ptr<AsyncContext>& context) 4 { 5 If (outcome.IsSuccess()) 6 { 7 SEND_QUEUE.erase(context->GetUUIID()); 8 } 9 } 10 11 auto context = Aws::MakeShared<AsyncContext>(“re:invent sample”); 12 context.SetUUID(“UniqueRequestKey”); 13 SEND_QUEUE[“UniqueRequestKey”] = putItemRequest; 14 client.PutItemAsync(putItemRequest, &putItemFinished, context);
  • 12. Async with member functions 1 void ReinventSample::putItemFinished(const DynamoDBClient* client, const PutItemRequest& request, 2 const PutItemOutcome& outcome, 3 const shared_ptr<AsyncContext>& context) 7 m_sendQueue.erase(context->GetUUIID()); 13 m_sendQueue[“UniqueRequestKey”] = putItemRequest; std::bind(&ReinventSample::putItemFinished, this, std::placeholders::_1, 15 std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)
  • 13. Asynchronous executor • Default executor will spawn a detached thread • Implement executor for more control • Use this to tie asynchronous calls to your system’s custom thread pool
  • 14. Asynchronous executor 1 #include <aws/core/utils/threading/Executor.h> 2 3 class CustomExecutor : public Aws::Utils::Threading::Executor 4 { 5 public: 6 CustomExecutor(MySystemsExecutorImpl* executor) : m_executor(executor) 7 8 protected: 9 bool SubmitToThread(std::function<void()>&& task) override 10 { 11 return m_executor->QueueTask(std::forward<std::function<void()>(task)); 12 } 13 14 private: 15 MySystemsExecutorImpl* m_executor; 16 };
  • 15. Asynchronous executor 1 ClientConfiguration config; 2 auto mySystemsExecutorImpl = applicationConfiguration->GetExecutor(); 3 config.executor = mySystemsExecutorImpl; 4 5 DynamoDBClient client(config); client.PutItemAsync(putItemRequest, &putItemFinished);
  • 16. Rate limiting • Client-side bandwidth throttling at the HTTP layer • Configurable separately for each client and each directionality (uploads and downloads)
  • 17. Rate limiting 1 class CustomRateLimiter : public Aws::Utils::RateLimits::RateLimiterInterface 2 { 3 public: 4 …. 5 6 DelayType ApplyCost(int64_t cost) override 7 { 8 m_availableBandwidth -= cost; 9 return m_availableBandwidth > 0 ? DelayType(0) : DelayType(0 – m_availableBandwidth); 10 } 11 12 void ApplyAndPayForCost(int64_t cost) override 13 { 14 std::this_thread::sleep_for(ApplyCost(cost)); 15 m_availableBandwidth += cost; 16 } 17 … 18 };
  • 18. Rate limiting 1 ClientConfiguration config; 2 auto downloadLimiter = Aws::MakeShared<CustomRateLimiter>(“re:InventSample”, FIVE_MB); 3 auto uploadLimiter = 4 Aws::MakeShared<CustomRateLimiter>(“re:InventSample”, TWO_HUNDRED_KB); 5 config.readRateLimiter = downloadLimiter; 6 config.writeRateLimiter = uploadLimiter; 7 DynamoDBClient client(config);
  • 19. Rate limiting Recommendations and things to know: • Default rate limiter implementation probably does what you want. (#include <aws/core/utils/ratelimiter/DefaultRateLimiter.h> ) • Calculation made at IO time not request size.
  • 20. Error handling • No exceptions used internally or thrown externally • Performance and flexibility reasons • SDK is exception-safe • Exceptions are safe to use in your application
  • 21. Error handling • Requests return an ‘Outcome’ object. • An ‘Outcome’ is either successful with a result payload or unsuccessful with an error payload • Errors closely match exception names from other SDKs
  • 22. Error handling and the outcome pattern 1 PutItemOutcome outcome = client.PutItem(putItemRequest); 2 If (outcome.IsSuccess()) 3 { 4 std::cout << outcome.GetResult().GetConsumedCapacity().GetCapacityUnits() << 5 “ Capacity Consumed” << std::endl; 6 } 7 else 8 { 9 If (outcome.GetError().GetErrorType() == DynamoDbErrors::CONDITIONAL_CHECK_FAILED) 10 { 11 std::cout << “Conditional Write failed. “ 12 << “ Message: “ << outcome.GetError().GetMessage() << std::endl; 13 } 14 else 15 { 16 std::cout << “Unexpected error “ << outcome.GetError().GetMessage() << std::endl; 17 } 18 }
  • 23. Retry strategies • Default retry strategy • Overridable per client • Offers more granular support your application
  • 24. Retry strategies 1 class ExponentialBackOffStrategy : public Aws::Client::RetryStrategy 2 { 3 public: 4 bool ShouldRetry(const AWSError<CoreErrors>& error, long attemptedRetries) const 5 { 6 If (attemptedRetries < 5) return error.ShouldRetry(); 7 8 return false; 9 } 10 11 long CalculateDelayBeforeNextRetry(const AWSError<CoreErrors>& error, long attemptedRetries) const 12 { 13 If (attemptedRetries == 0) return 0; 14 15 return (1 << attemptedRetries) * 25; 16 } 17 }; 18
  • 25. Retry strategies 1 ClientConfiguration config; 2 auto retryStrategy = 3 Aws::MakeShared<ExponentialBackoffStrategy>(“re:inventSample”); 4 config.retryStrategy = retryStrategy; 5 DynamoDBClient client(config);
  • 26. Memory allocation • Configured at compile time • Custom Allocators installed at runtime • Default forces allocation into single allocator • On by default for dynamic libraries • What about the STL?
  • 27. Memory allocation 1 class DlMallocMemorySystem : public MemorySystemInterface 2 { 3 public: 4 ~DlMallocMemorySystem() = default; 5 6 void Begin() override {} 7 void End() override {} 8 9 void* AllocateMemory(std::size_t blockSize, std::size_t alignment, const char* allocationTag = nullptr) override 10 { 11 return dlmalloc(blockSize); 12 } 13 14 void FreeMemory(void* memoryPtr) override 15 { 16 dlfree(memoryPtr); 17 } 18 };
  • 28. Memory allocation 1 DlMallocMemorySystem dlMallocMemorySystem; 2 Aws::Utils::Memory::InitializeAWSMemorySystem(dlMallocMemorySystem); 14 Aws::Utils::Memory::ShutdownAWSMemorySystem();
  • 29. Memory allocation What about the Standard Template Library? • Use AWS-defined STL types (Aws::Vector, Aws::String, Aws::Map, Aws::IOStream, etc.) • Automatically resolves allocator • Compile time switch • Most APIs take primitives as well
  • 30. Memory allocation General advice • Use custom memory management with dynamic linking -- especially on Windows • Do not use STL containers directly • Do not use new or delete directly • Do not use std smart pointer APIs directly • Use –DAWS_CUSTOM_MEMORY_MANAGEMENT w/ custom memory management
  • 31. Streaming requests and responses • Some payloads are not typed (example: Amazon S3 GetObject, PutObject) • Use the STL IOStream interface. • Defaults to underlying StringBuf • Easily overridable
  • 32. Streaming requests 1 S3Client client; 2 PutObjectRequest putObjectRequest; 3 putObjectRequest.SetBucketName(“reinvent_sample_bucket”); 4 putObjectRequest.SetKeyName(“reinvent_sample_key”); 5 6 auto fileToUpload = Aws::MakeShared<Aws::FStream>(“re:InventSample”, 7 “users/me/toUpload/fileToUpload.png”, std::ios_in); 8 putObjectRequest.SetBody(fileToUpload); 9 10 auto outcome = client.PutObject(putObjectRequest); 11 12
  • 33. Streaming responses 1 S3Client client; 2 GetObjectRequest getObjectRequest; 3 getObjectRequest.SetBucketName(“reinvent_sample_bucket”); 4 getObjectRequest.SetKeyName(“reinvent_sample_key”); 5 getObjectRequest.SetResponseStreamFactory( 6 [](){ 7 return Aws::New<Aws::FStream>(“re:InventSample”, “/users/me/downloads/filename.png”, 8 std::ios_base::in | std::ios_base::out | std::ios_base::trunc); 9 }); 10 11 auto outcome = client.GetObject(getObjectRequest); 12 ….
  • 34. Overriding the HTTP/TLS stack I want to use my own IO stack. What do I do? • HTTP stacks can be injected into clients • Implement your own HttpClient • Simply override the HttpClientFactory in your ClientConfiguration
  • 35. Overriding the HTTP/TLS stack 1 class LibUVWithSignalToNoiseHttpClient : public Aws::Http::HttpClient 2 { 3 public: 4 virtual ~LibUVWithSignalToNoiseHttpClient () {} 5 6 std::shared_ptr<HttpResponse> MakeRequest(HttpRequest& request, 7 Aws::Utils::RateLimits::RateLimiterInterface* readLimiter = nullptr, 8 Aws::Utils::RateLimits::RateLimiterInterface* writeLimiter = nullptr) const override; 9 }; 10
  • 36. Overriding the HTTP/TLS stack 1 class LibUVWithSignalToNoiseHttpClientFactory : public Aws::Http::HttpClientFactory 2 { 3 public: 4 virtual ~LibUVWithSignalToNoiseHttpClientFactory() {} 5 6 std::shared_ptr<HttpClient> CreateHttpClient 7 (const Aws::Client::ClientConfiguration& clientConfiguration) const override; 8 9 virtual std::shared_ptr<HttpRequest> CreateHttpRequest(const Aws::String& uri, HttpMethod method, 10 const Aws::IOStreamFactory& streamFactory) const override; 11 12 virtual std::shared_ptr<HttpRequest> CreateHttpRequest(const URI& uri, HttpMethod method, 13 const Aws::IOStreamFactory& streamFactory) const override; 14 };
  • 37. Overriding the Http/TLS stack 1 auto httpClientFactory = Aws::MakeShared<LibUVWithSignalToNoiseHttpClientFactory>(“re:InventSample”); 2 DynamoDBClient client(credentialProvider, config, httpClientFactory);
  • 38. High-level APIs • Amazon Cognito identity providers • Amazon S3 Transfer Manager • Queues-like interface for Amazon SQS • Access management API for IAM
  • 39. High-level APIs 1 auto credentialsProvider = 2 Aws::MakeShared<CognitoCachingAnonymousCredentialsProvider>(“re:invent sample”, 3 “55216815”, “us-east-1:65814ddc-1479-4dfe-9bab-254541asd2fb”); 4 5 DynamoDBClient dynamoDbClient(credentialsProvider); 6 Identity management with an anonymous identity pool
  • 40. High-level APIs 1 auto identityProvider = 2 Aws::MakeShared<DefaultPersistentCognitoIdentityProvider>(“re:invent sample”); 3 Aws::Map<Aws::String, LoginAccessTokens> tokens; 4 tokens[“www.amazon.com”] = LoginAccessTokens { “aegedeev”, “bdekibnkoga”, ONE_HOUR }; 5 identityProvider->PersistLogins(tokens); 6 7 auto credentialsProvider = 8 Aws::MakeShared<CognitoCachingAuthenticatedCredentialsProvider>(“re:invent sample”, 9 “55216815”, “us-east-1:65814ddc-1479-4dfe-9bab-254541asd2fb”, 10 identityProvider); 11 DynamoDBClient dynamoDbClient(credentialsProvider); Identity management with an authenticated identity pool
  • 41. High-level APIs 1 auto s3Client = Aws::MakeShared<S3Client>(“re:invent sample”); 2 TransferClient transferClient(s3Client, TransferClientConfiguration { 10, nullptr } ); 3 4 auto uploadFileRequest = 5 transferClient.UploadFile(“/home/user/customer/myDatabase.frm”, 6 “sample_bucket”, “sample_key”, “application/octet-stream”); Uploading a large file with Transfer Manager
  • 42. High-level APIs 1 auto sqsClient = Aws::MakeShared<SQSClient>(“reinvent sample”); 2 SQSQueue queue(sqsClient, “sample_queue”, FIFTEEN_SEC); 3 queue.SetMessageRecievedEventHandler( 4 std::bind(&ReinventSample::OnMessageRecieved, this, 5 std::placeholders::_1, std::placeholders::_2, std::placeholders::_3)); 6 queue.EnsureQueueIsInitialized(); 7 queue.StartPolling(); 8 9 void ReinventSample::OnMessageRecieved(const Queue* queue, 10 const Message& message , bool& deleteMessage) 11 { 12 auto msgBody = message.GetBody(); 13 deleteMessage = SEND_IPC_MESSAGE(Q_ID, msgBody) != -1; 14 } Receiving async message notifications via queues
  • 43. High-level APIs Contributing high-level APIs • Please do! • Follow contribution guidelines outlined in readme • Use constructor injection for low-level clients
  • 44. Takeaways • Overview of the AWS SDK for C++ • github.com/awslabs/aws-sdk-cpp • Core library features • Credential management • Logging • Asynchronous requests • Rate limiting • Error handling • Memory allocation • Streaming • Overriding the HTTP/TLS stack • High-level APIs overview
  • 45. © 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Send us pull requests @ github.com/awslabs/aws-sdk-cpp