public class Client
extends BaseClient
Client for AWS protocol based on SDK provided by Amazon. In terms of
Discovery client represents low-level bridge for protocol - AWS.
Key word in scope of this client that is used very frequently is 'service'.
Services is a particular functionality of 'Amazon Cloud infrastructure' like EC2, S3, RDS.
To get service we have to choose type of service and establish connection.
ServiceType - used to choose type or determine service type by name.
ServiceManager - wrapper around service which can correctly close connection to it and
make perform other service life-cycle functionality.
To create ServiceManager instance ServiceType must to be used.
Lets consider an example
ServiceType serviceType = ServiceType.EC2;
ServiceManager serviceManager = DefaultServiceManager.connect(serviceType.getClientClass(), accessKey, secretKey)
After this code we have a connection established to service EC2 identified by accessKey
and encapsulated in the ServiceManager instance. To get service use method
serviceManager.getService()
to close connection
serviceManager.disconnect()
ServiceType also has technical information about service interface types for
dynamic proxies creation.