public class EC2Manager extends TaskclusterRequestHandler
A taskcluster service which manages EC2 instances. This service does not understand any taskcluster concepts intrinsicaly other than using the name workerType
to refer to a group of associated instances. Unless you are working on building a provisioner for AWS, you almost certainly do not want to use this service
Modifier and Type | Field and Description |
---|---|
protected static String |
defaultBaseURL |
Constructor and Description |
---|
EC2Manager() |
EC2Manager(Credentials credentials) |
EC2Manager(Credentials credentials,
String baseURL) |
EC2Manager(String baseURL) |
EC2Manager(String clientId,
String accessToken) |
EC2Manager(String clientId,
String accessToken,
String certificate) |
Modifier and Type | Method and Description |
---|---|
CallSummary<EmptyPayload,EmptyPayload> |
allState()
This method is only for debugging the ec2-managerRequired scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
amiUsage()
List AMIs and their usage by returning a list of objects in the form: { region: string volumetype: string lastused: timestamp }Required scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
apiReference()
Generate an API reference for this service
|
CallSummary<EmptyPayload,EmptyPayload> |
dbpoolStats()
This method is only for debugging the ec2-managerRequired scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
ebsUsage()
Lists current EBS volume usage by returning a list of objects that are uniquely defined by {region, volumetype, state} in the form: { region: string, volumetype: string, state: string, totalcount: integer, totalgb: integer, touched: timestamp (last time that information was updated), }Required scopes: ec2-manager:internals
|
CallSummary<SshPublicKey,EmptyPayload> |
ensureKeyPair(String name,
SshPublicKey payload)
Idempotently ensure that a keypair of a given name existsRequired scopes: ec2-manager:manage-key-pairs:
|
CallSummary<EmptyPayload,HealthOfTheEC2Account> |
getHealth()
Give some basic stats on the health of our EC2 account
|
CallSummary<EmptyPayload,Entry1[]> |
getPrices()
Return a list of possible prices for EC2
|
CallSummary<EmptyPayload,Errors> |
getRecentErrors()
Return a list of recent errors encountered
|
CallSummary<Entry2[],Entry1[]> |
getSpecificPrices(Entry2[] payload)
Return a list of possible prices for EC2
|
CallSummary<EmptyPayload,String[]> |
listWorkerTypes()
This method is only for debugging the ec2-manager
|
CallSummary<EmptyPayload,EmptyPayload> |
ping()
Respond without doing anything.
|
CallSummary<EmptyPayload,EmptyPayload> |
purgeQueues()
This method is only for debugging the ec2-managerRequired scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
regions()
This method is only for debugging the ec2-managerRequired scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
removeKeyPair(String name)
Ensure that a keypair of a given name does not exist.
|
CallSummary<MakeASpotRequest,EmptyPayload> |
runInstance(String workerType,
MakeASpotRequest payload)
Request an instance of a worker typeRequired scopes: ec2-manager:manage-resources:
|
CallSummary<EmptyPayload,EmptyPayload> |
sqsStats()
This method is only for debugging the ec2-managerRequired scopes: ec2-manager:internals
|
CallSummary<EmptyPayload,EmptyPayload> |
terminateInstance(String region,
String instanceId)
Terminate an instance in a specified regionRequired scopes: Any of: - ec2-manager:manage-instances:
|
CallSummary<EmptyPayload,EmptyPayload> |
terminateWorkerType(String workerType)
Terminate all instances for this worker typeRequired scopes: ec2-manager:manage-resources:
|
CallSummary<EmptyPayload,Errors> |
workerTypeErrors(String workerType)
Return a list of the most recent errors encountered by a worker type
|
CallSummary<EmptyPayload,HealthOfTheEC2Account> |
workerTypeHealth(String workerType)
Return a view of the health of a given worker type
|
CallSummary<EmptyPayload,OverviewOfComputationalResources1> |
workerTypeState(String workerType)
Return state information for a given worker type
|
CallSummary<EmptyPayload,OverviewOfComputationalResources> |
workerTypeStats(String workerType)
Return an object which has a generic state description.
|
apiCall, setBaseURL, uriEncode
protected static final String defaultBaseURL
public EC2Manager(Credentials credentials)
public EC2Manager(Credentials credentials, String baseURL)
public EC2Manager(String baseURL)
public EC2Manager()
public CallSummary<EmptyPayload,String[]> listWorkerTypes() throws APICallFailure
This method is only for debugging the ec2-manager
public CallSummary<MakeASpotRequest,EmptyPayload> runInstance(String workerType, MakeASpotRequest payload) throws APICallFailure
Request an instance of a worker type
Required scopes: ec2-manager:manage-resources:
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> terminateWorkerType(String workerType) throws APICallFailure
Terminate all instances for this worker type
Required scopes: ec2-manager:manage-resources:
APICallFailure
public CallSummary<EmptyPayload,OverviewOfComputationalResources> workerTypeStats(String workerType) throws APICallFailure
Return an object which has a generic state description. This only contains counts of instances
APICallFailure
public CallSummary<EmptyPayload,HealthOfTheEC2Account> workerTypeHealth(String workerType) throws APICallFailure
Return a view of the health of a given worker type
APICallFailure
public CallSummary<EmptyPayload,Errors> workerTypeErrors(String workerType) throws APICallFailure
Return a list of the most recent errors encountered by a worker type
public CallSummary<EmptyPayload,OverviewOfComputationalResources1> workerTypeState(String workerType) throws APICallFailure
Return state information for a given worker type
APICallFailure
public CallSummary<SshPublicKey,EmptyPayload> ensureKeyPair(String name, SshPublicKey payload) throws APICallFailure
Idempotently ensure that a keypair of a given name exists
Required scopes: ec2-manager:manage-key-pairs:
public CallSummary<EmptyPayload,EmptyPayload> removeKeyPair(String name) throws APICallFailure
Ensure that a keypair of a given name does not exist.
Required scopes: ec2-manager:manage-key-pairs:
public CallSummary<EmptyPayload,EmptyPayload> terminateInstance(String region, String instanceId) throws APICallFailure
Terminate an instance in a specified region
Required scopes: Any of: - ec2-manager:manage-instances:
APICallFailure
public CallSummary<EmptyPayload,Entry1[]> getPrices() throws APICallFailure
Return a list of possible prices for EC2
APICallFailure
public CallSummary<Entry2[],Entry1[]> getSpecificPrices(Entry2[] payload) throws APICallFailure
Return a list of possible prices for EC2
APICallFailure
public CallSummary<EmptyPayload,HealthOfTheEC2Account> getHealth() throws APICallFailure
Give some basic stats on the health of our EC2 account
APICallFailure
public CallSummary<EmptyPayload,Errors> getRecentErrors() throws APICallFailure
Return a list of recent errors encountered
public CallSummary<EmptyPayload,EmptyPayload> regions() throws APICallFailure
This method is only for debugging the ec2-manager
Required scopes: ec2-manager:internals
public CallSummary<EmptyPayload,EmptyPayload> amiUsage() throws APICallFailure
List AMIs and their usage by returning a list of objects in the form: { region: string volumetype: string lastused: timestamp }
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> ebsUsage() throws APICallFailure
Lists current EBS volume usage by returning a list of objects that are uniquely defined by {region, volumetype, state} in the form: { region: string, volumetype: string, state: string, totalcount: integer, totalgb: integer, touched: timestamp (last time that information was updated), }
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> dbpoolStats() throws APICallFailure
This method is only for debugging the ec2-manager
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> allState() throws APICallFailure
This method is only for debugging the ec2-manager
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> sqsStats() throws APICallFailure
This method is only for debugging the ec2-manager
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> purgeQueues() throws APICallFailure
This method is only for debugging the ec2-manager
Required scopes: ec2-manager:internals
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> apiReference() throws APICallFailure
Generate an API reference for this service
APICallFailure
public CallSummary<EmptyPayload,EmptyPayload> ping() throws APICallFailure
Respond without doing anything. This endpoint is used to check that the service is up.
APICallFailure
Copyright © 2014–2018 Mozilla. All rights reserved.