Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Lists training jobs.
When StatusEquals
and MaxResults
are set at the same time, the
MaxResults
number of training jobs are first retrieved ignoring the
StatusEquals
parameter and then they are filtered by the
StatusEquals
parameter, which is returned as a response.
For example, if ListTrainingJobs
is invoked with the following
parameters:
{ ... MaxResults: 100, StatusEquals: InProgress ... }
First, 100 trainings jobs with any status, including those other than
InProgress
, are selected (sorted according to the creation time, from
the most current to the oldest). Next, those with a status of
InProgress
are returned.
You can quickly test the API using the following Amazon Web Services CLI code.
aws sagemaker list-training-jobs --max-results 100 --status-equals InProgress
This operation returns paginated results.
Synopsis
- data ListTrainingJobs = ListTrainingJobs' {
- nameContains :: Maybe Text
- lastModifiedTimeBefore :: Maybe POSIX
- creationTimeAfter :: Maybe POSIX
- nextToken :: Maybe Text
- sortOrder :: Maybe SortOrder
- lastModifiedTimeAfter :: Maybe POSIX
- creationTimeBefore :: Maybe POSIX
- statusEquals :: Maybe TrainingJobStatus
- maxResults :: Maybe Natural
- sortBy :: Maybe SortBy
- newListTrainingJobs :: ListTrainingJobs
- listTrainingJobs_nameContains :: Lens' ListTrainingJobs (Maybe Text)
- listTrainingJobs_lastModifiedTimeBefore :: Lens' ListTrainingJobs (Maybe UTCTime)
- listTrainingJobs_creationTimeAfter :: Lens' ListTrainingJobs (Maybe UTCTime)
- listTrainingJobs_nextToken :: Lens' ListTrainingJobs (Maybe Text)
- listTrainingJobs_sortOrder :: Lens' ListTrainingJobs (Maybe SortOrder)
- listTrainingJobs_lastModifiedTimeAfter :: Lens' ListTrainingJobs (Maybe UTCTime)
- listTrainingJobs_creationTimeBefore :: Lens' ListTrainingJobs (Maybe UTCTime)
- listTrainingJobs_statusEquals :: Lens' ListTrainingJobs (Maybe TrainingJobStatus)
- listTrainingJobs_maxResults :: Lens' ListTrainingJobs (Maybe Natural)
- listTrainingJobs_sortBy :: Lens' ListTrainingJobs (Maybe SortBy)
- data ListTrainingJobsResponse = ListTrainingJobsResponse' {}
- newListTrainingJobsResponse :: Int -> ListTrainingJobsResponse
- listTrainingJobsResponse_nextToken :: Lens' ListTrainingJobsResponse (Maybe Text)
- listTrainingJobsResponse_httpStatus :: Lens' ListTrainingJobsResponse Int
- listTrainingJobsResponse_trainingJobSummaries :: Lens' ListTrainingJobsResponse [TrainingJobSummary]
Creating a Request
data ListTrainingJobs Source #
See: newListTrainingJobs
smart constructor.
ListTrainingJobs' | |
|
Instances
newListTrainingJobs :: ListTrainingJobs Source #
Create a value of ListTrainingJobs
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:nameContains:ListTrainingJobs'
, listTrainingJobs_nameContains
- A string in the training job name. This filter returns only training
jobs whose name contains the specified string.
$sel:lastModifiedTimeBefore:ListTrainingJobs'
, listTrainingJobs_lastModifiedTimeBefore
- A filter that returns only training jobs modified before the specified
time (timestamp).
$sel:creationTimeAfter:ListTrainingJobs'
, listTrainingJobs_creationTimeAfter
- A filter that returns only training jobs created after the specified
time (timestamp).
$sel:nextToken:ListTrainingJobs'
, listTrainingJobs_nextToken
- If the result of the previous ListTrainingJobs
request was truncated,
the response includes a NextToken
. To retrieve the next set of
training jobs, use the token in the next request.
$sel:sortOrder:ListTrainingJobs'
, listTrainingJobs_sortOrder
- The sort order for results. The default is Ascending
.
$sel:lastModifiedTimeAfter:ListTrainingJobs'
, listTrainingJobs_lastModifiedTimeAfter
- A filter that returns only training jobs modified after the specified
time (timestamp).
$sel:creationTimeBefore:ListTrainingJobs'
, listTrainingJobs_creationTimeBefore
- A filter that returns only training jobs created before the specified
time (timestamp).
$sel:statusEquals:ListTrainingJobs'
, listTrainingJobs_statusEquals
- A filter that retrieves only training jobs with a specific status.
$sel:maxResults:ListTrainingJobs'
, listTrainingJobs_maxResults
- The maximum number of training jobs to return in the response.
$sel:sortBy:ListTrainingJobs'
, listTrainingJobs_sortBy
- The field to sort results by. The default is CreationTime
.
Request Lenses
listTrainingJobs_nameContains :: Lens' ListTrainingJobs (Maybe Text) Source #
A string in the training job name. This filter returns only training jobs whose name contains the specified string.
listTrainingJobs_lastModifiedTimeBefore :: Lens' ListTrainingJobs (Maybe UTCTime) Source #
A filter that returns only training jobs modified before the specified time (timestamp).
listTrainingJobs_creationTimeAfter :: Lens' ListTrainingJobs (Maybe UTCTime) Source #
A filter that returns only training jobs created after the specified time (timestamp).
listTrainingJobs_nextToken :: Lens' ListTrainingJobs (Maybe Text) Source #
If the result of the previous ListTrainingJobs
request was truncated,
the response includes a NextToken
. To retrieve the next set of
training jobs, use the token in the next request.
listTrainingJobs_sortOrder :: Lens' ListTrainingJobs (Maybe SortOrder) Source #
The sort order for results. The default is Ascending
.
listTrainingJobs_lastModifiedTimeAfter :: Lens' ListTrainingJobs (Maybe UTCTime) Source #
A filter that returns only training jobs modified after the specified time (timestamp).
listTrainingJobs_creationTimeBefore :: Lens' ListTrainingJobs (Maybe UTCTime) Source #
A filter that returns only training jobs created before the specified time (timestamp).
listTrainingJobs_statusEquals :: Lens' ListTrainingJobs (Maybe TrainingJobStatus) Source #
A filter that retrieves only training jobs with a specific status.
listTrainingJobs_maxResults :: Lens' ListTrainingJobs (Maybe Natural) Source #
The maximum number of training jobs to return in the response.
listTrainingJobs_sortBy :: Lens' ListTrainingJobs (Maybe SortBy) Source #
The field to sort results by. The default is CreationTime
.
Destructuring the Response
data ListTrainingJobsResponse Source #
See: newListTrainingJobsResponse
smart constructor.
ListTrainingJobsResponse' | |
|
Instances
newListTrainingJobsResponse Source #
Create a value of ListTrainingJobsResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:nextToken:ListTrainingJobs'
, listTrainingJobsResponse_nextToken
- If the response is truncated, Amazon SageMaker returns this token. To
retrieve the next set of training jobs, use it in the subsequent
request.
$sel:httpStatus:ListTrainingJobsResponse'
, listTrainingJobsResponse_httpStatus
- The response's http status code.
$sel:trainingJobSummaries:ListTrainingJobsResponse'
, listTrainingJobsResponse_trainingJobSummaries
- An array of TrainingJobSummary
objects, each listing a training job.
Response Lenses
listTrainingJobsResponse_nextToken :: Lens' ListTrainingJobsResponse (Maybe Text) Source #
If the response is truncated, Amazon SageMaker returns this token. To retrieve the next set of training jobs, use it in the subsequent request.
listTrainingJobsResponse_httpStatus :: Lens' ListTrainingJobsResponse Int Source #
The response's http status code.
listTrainingJobsResponse_trainingJobSummaries :: Lens' ListTrainingJobsResponse [TrainingJobSummary] Source #
An array of TrainingJobSummary
objects, each listing a training job.