/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace SagemakerEdgeManager { /** *

SageMaker Edge Manager dataplane service for communicating with active * agents.

*/ class AWS_SAGEMAKEREDGEMANAGER_API SagemakerEdgeManagerClient : public Aws::Client::AWSJsonClient, public Aws::Client::ClientWithAsyncTemplateMethods { public: typedef Aws::Client::AWSJsonClient BASECLASS; static const char* SERVICE_NAME; static const char* ALLOCATION_TAG; typedef SagemakerEdgeManagerClientConfiguration ClientConfigurationType; typedef SagemakerEdgeManagerEndpointProvider EndpointProviderType; /** * Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client config * is not specified, it will be initialized to default values. */ SagemakerEdgeManagerClient(const Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration& clientConfiguration = Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration(), std::shared_ptr endpointProvider = Aws::MakeShared(ALLOCATION_TAG)); /** * Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config * is not specified, it will be initialized to default values. */ SagemakerEdgeManagerClient(const Aws::Auth::AWSCredentials& credentials, std::shared_ptr endpointProvider = Aws::MakeShared(ALLOCATION_TAG), const Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration& clientConfiguration = Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration()); /** * Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied, * the default http client factory will be used */ SagemakerEdgeManagerClient(const std::shared_ptr& credentialsProvider, std::shared_ptr endpointProvider = Aws::MakeShared(ALLOCATION_TAG), const Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration& clientConfiguration = Aws::SagemakerEdgeManager::SagemakerEdgeManagerClientConfiguration()); /* Legacy constructors due deprecation */ /** * Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client config * is not specified, it will be initialized to default values. */ SagemakerEdgeManagerClient(const Aws::Client::ClientConfiguration& clientConfiguration); /** * Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config * is not specified, it will be initialized to default values. */ SagemakerEdgeManagerClient(const Aws::Auth::AWSCredentials& credentials, const Aws::Client::ClientConfiguration& clientConfiguration); /** * Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied, * the default http client factory will be used */ SagemakerEdgeManagerClient(const std::shared_ptr& credentialsProvider, const Aws::Client::ClientConfiguration& clientConfiguration); /* End of legacy constructors due deprecation */ virtual ~SagemakerEdgeManagerClient(); /** *

Use to get the active deployments from a device.

See Also:

* AWS * API Reference

*/ virtual Model::GetDeploymentsOutcome GetDeployments(const Model::GetDeploymentsRequest& request) const; /** * A Callable wrapper for GetDeployments that returns a future to the operation so that it can be executed in parallel to other requests. */ template Model::GetDeploymentsOutcomeCallable GetDeploymentsCallable(const GetDeploymentsRequestT& request) const { return SubmitCallable(&SagemakerEdgeManagerClient::GetDeployments, request); } /** * An Async wrapper for GetDeployments that queues the request into a thread executor and triggers associated callback when operation has finished. */ template void GetDeploymentsAsync(const GetDeploymentsRequestT& request, const GetDeploymentsResponseReceivedHandler& handler, const std::shared_ptr& context = nullptr) const { return SubmitAsync(&SagemakerEdgeManagerClient::GetDeployments, request, handler, context); } /** *

Use to check if a device is registered with SageMaker Edge * Manager.

See Also:

AWS * API Reference

*/ virtual Model::GetDeviceRegistrationOutcome GetDeviceRegistration(const Model::GetDeviceRegistrationRequest& request) const; /** * A Callable wrapper for GetDeviceRegistration that returns a future to the operation so that it can be executed in parallel to other requests. */ template Model::GetDeviceRegistrationOutcomeCallable GetDeviceRegistrationCallable(const GetDeviceRegistrationRequestT& request) const { return SubmitCallable(&SagemakerEdgeManagerClient::GetDeviceRegistration, request); } /** * An Async wrapper for GetDeviceRegistration that queues the request into a thread executor and triggers associated callback when operation has finished. */ template void GetDeviceRegistrationAsync(const GetDeviceRegistrationRequestT& request, const GetDeviceRegistrationResponseReceivedHandler& handler, const std::shared_ptr& context = nullptr) const { return SubmitAsync(&SagemakerEdgeManagerClient::GetDeviceRegistration, request, handler, context); } /** *

Use to get the current status of devices registered on SageMaker Edge * Manager.

See Also:

AWS * API Reference

*/ virtual Model::SendHeartbeatOutcome SendHeartbeat(const Model::SendHeartbeatRequest& request) const; /** * A Callable wrapper for SendHeartbeat that returns a future to the operation so that it can be executed in parallel to other requests. */ template Model::SendHeartbeatOutcomeCallable SendHeartbeatCallable(const SendHeartbeatRequestT& request) const { return SubmitCallable(&SagemakerEdgeManagerClient::SendHeartbeat, request); } /** * An Async wrapper for SendHeartbeat that queues the request into a thread executor and triggers associated callback when operation has finished. */ template void SendHeartbeatAsync(const SendHeartbeatRequestT& request, const SendHeartbeatResponseReceivedHandler& handler, const std::shared_ptr& context = nullptr) const { return SubmitAsync(&SagemakerEdgeManagerClient::SendHeartbeat, request, handler, context); } void OverrideEndpoint(const Aws::String& endpoint); std::shared_ptr& accessEndpointProvider(); private: friend class Aws::Client::ClientWithAsyncTemplateMethods; void init(const SagemakerEdgeManagerClientConfiguration& clientConfiguration); SagemakerEdgeManagerClientConfiguration m_clientConfiguration; std::shared_ptr m_executor; std::shared_ptr m_endpointProvider; }; } // namespace SagemakerEdgeManager } // namespace Aws