@Generated(value="OracleSDKGenerator", comments="API Version: 20190101") public class DataScienceAsyncClient extends Object implements DataScienceAsync
Async client implementation for DataScience service.
There are two ways to use async client:
InputStream
, like
getObject Api in object storage service, developers need to process the stream in AsyncHandler, and not anywhere else,
because the stream will be closed right after the AsyncHandler is invoked. Modifier and Type | Class and Description |
---|---|
static class |
DataScienceAsyncClient.Builder
Builder class for this client.
|
Modifier and Type | Field and Description |
---|---|
static Service |
SERVICE
Service instance for DataScience.
|
Constructor and Description |
---|
DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
List<ClientConfigurator> additionalClientConfigurators)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
List<ClientConfigurator> additionalClientConfigurators,
String endpoint)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories,
List<ClientConfigurator> additionalClientConfigurators,
String endpoint)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories,
List<ClientConfigurator> additionalClientConfigurators,
String endpoint,
com.oracle.bmc.http.internal.RestClientFactoryBuilder restClientFactoryBuilder)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider)
Creates a new service instance using the given authentication provider.
|
DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration)
Creates a new service instance using the given authentication provider and client configuration.
|
DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator)
Creates a new service instance using the given authentication provider and client configuration.
|
public static final Service SERVICE
Service instance for DataScience.
public DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider)
Creates a new service instance using the given authentication provider.
authenticationDetailsProvider
- The authentication details provider, required.public DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration)
Creates a new service instance using the given authentication provider and client configuration.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.public DataScienceAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.public DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
This is an advanced constructor for clients that want to take control over how requests are signed.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.defaultRequestSignerFactory
- The request signer factory used to create the request signer for this service.public DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, List<ClientConfigurator> additionalClientConfigurators)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
This is an advanced constructor for clients that want to take control over how requests are signed.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.defaultRequestSignerFactory
- The request signer factory used to create the request signer for this service.additionalClientConfigurators
- Additional client configurators to be run after the primary configurator.public DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, List<ClientConfigurator> additionalClientConfigurators, String endpoint)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
This is an advanced constructor for clients that want to take control over how requests are signed.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.defaultRequestSignerFactory
- The request signer factory used to create the request signer for this service.additionalClientConfigurators
- Additional client configurators to be run after the primary configurator.endpoint
- Endpoint, or null to leave unset (note, may be overridden by authenticationDetailsProvider
)public DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories, List<ClientConfigurator> additionalClientConfigurators, String endpoint)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
This is an advanced constructor for clients that want to take control over how requests are signed.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.defaultRequestSignerFactory
- The request signer factory used to create the request signer for this service.signingStrategyRequestSignerFactories
- The request signer factories for each signing strategy used to create the request signeradditionalClientConfigurators
- Additional client configurators to be run after the primary configurator.endpoint
- Endpoint, or null to leave unset (note, may be overridden by authenticationDetailsProvider
)public DataScienceAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories, List<ClientConfigurator> additionalClientConfigurators, String endpoint, com.oracle.bmc.http.internal.RestClientFactoryBuilder restClientFactoryBuilder)
Creates a new service instance using the given authentication provider and client configuration. Additionally, a Consumer can be provided that will be invoked whenever a REST Client is created to allow for additional configuration/customization.
This is an advanced constructor for clients that want to take control over how requests are signed.
authenticationDetailsProvider
- The authentication details provider, required.configuration
- The client configuration, optional.clientConfigurator
- ClientConfigurator that will be invoked for additional configuration of a REST client, optional.defaultRequestSignerFactory
- The request signer factory used to create the request signer for this service.signingStrategyRequestSignerFactories
- The request signer factories for each signing strategy used to create the request signeradditionalClientConfigurators
- Additional client configurators to be run after the primary configurator.endpoint
- Endpoint, or null to leave unset (note, may be overridden by authenticationDetailsProvider
)restClientFactoryBuilder
- the builder for the RestClientFactory
public static DataScienceAsyncClient.Builder builder()
Create a builder for this client.
public void setEndpoint(String endpoint)
DataScienceAsync
Sets the endpoint to call (ex, https://www.example.com).
setEndpoint
in interface DataScienceAsync
endpoint
- The endpoint of the serice.public String getEndpoint()
DataScienceAsync
Gets the set endpoint for REST call (ex, https://www.example.com)
getEndpoint
in interface DataScienceAsync
public void setRegion(Region region)
DataScienceAsync
Sets the region to call (ex, Region.US_PHOENIX_1).
Note, this will call setEndpoint
after resolving the endpoint. If the service is not available in this region, however, an IllegalArgumentException will be raised.
setRegion
in interface DataScienceAsync
region
- The region of the service.public void setRegion(String regionId)
DataScienceAsync
Sets the region to call (ex, ‘us-phoenix-1’).
Note, this will first try to map the region ID to a known Region and call
setRegion
.
If no known Region could be determined, it will create an endpoint based on the
default endpoint format (Region.formatDefaultRegionEndpoint(Service, String)
and then call setEndpoint
.
setRegion
in interface DataScienceAsync
regionId
- The public region ID.public void close()
close
in interface AutoCloseable
public Future<ActivateModelResponse> activateModel(ActivateModelRequest request, AsyncHandler<ActivateModelRequest,ActivateModelResponse> handler)
DataScienceAsync
Activates the model.
activateModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ActivateNotebookSessionResponse> activateNotebookSession(ActivateNotebookSessionRequest request, AsyncHandler<ActivateNotebookSessionRequest,ActivateNotebookSessionResponse> handler)
DataScienceAsync
Activates the notebook session.
activateNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CancelWorkRequestResponse> cancelWorkRequest(CancelWorkRequestRequest request, AsyncHandler<CancelWorkRequestRequest,CancelWorkRequestResponse> handler)
DataScienceAsync
Cancels a work request that has not started.
cancelWorkRequest
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeModelCompartmentResponse> changeModelCompartment(ChangeModelCompartmentRequest request, AsyncHandler<ChangeModelCompartmentRequest,ChangeModelCompartmentResponse> handler)
DataScienceAsync
Moves a model resource into a different compartment.
changeModelCompartment
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeNotebookSessionCompartmentResponse> changeNotebookSessionCompartment(ChangeNotebookSessionCompartmentRequest request, AsyncHandler<ChangeNotebookSessionCompartmentRequest,ChangeNotebookSessionCompartmentResponse> handler)
DataScienceAsync
Moves a notebook session resource into a different compartment.
changeNotebookSessionCompartment
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeProjectCompartmentResponse> changeProjectCompartment(ChangeProjectCompartmentRequest request, AsyncHandler<ChangeProjectCompartmentRequest,ChangeProjectCompartmentResponse> handler)
DataScienceAsync
Moves a project resource into a different compartment.
changeProjectCompartment
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateModelResponse> createModel(CreateModelRequest request, AsyncHandler<CreateModelRequest,CreateModelResponse> handler)
DataScienceAsync
Creates a new model.
createModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateModelArtifactResponse> createModelArtifact(CreateModelArtifactRequest request, AsyncHandler<CreateModelArtifactRequest,CreateModelArtifactResponse> handler)
DataScienceAsync
Creates model artifact for specified model.
createModelArtifact
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateModelProvenanceResponse> createModelProvenance(CreateModelProvenanceRequest request, AsyncHandler<CreateModelProvenanceRequest,CreateModelProvenanceResponse> handler)
DataScienceAsync
Creates provenance information for the specified model.
createModelProvenance
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateNotebookSessionResponse> createNotebookSession(CreateNotebookSessionRequest request, AsyncHandler<CreateNotebookSessionRequest,CreateNotebookSessionResponse> handler)
DataScienceAsync
Creates a new notebook session.
createNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateProjectResponse> createProject(CreateProjectRequest request, AsyncHandler<CreateProjectRequest,CreateProjectResponse> handler)
DataScienceAsync
Creates a new project.
createProject
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeactivateModelResponse> deactivateModel(DeactivateModelRequest request, AsyncHandler<DeactivateModelRequest,DeactivateModelResponse> handler)
DataScienceAsync
Deactivates the model.
deactivateModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeactivateNotebookSessionResponse> deactivateNotebookSession(DeactivateNotebookSessionRequest request, AsyncHandler<DeactivateNotebookSessionRequest,DeactivateNotebookSessionResponse> handler)
DataScienceAsync
Deactivates the notebook session.
deactivateNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteModelResponse> deleteModel(DeleteModelRequest request, AsyncHandler<DeleteModelRequest,DeleteModelResponse> handler)
DataScienceAsync
Deletes the specified model.
deleteModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteNotebookSessionResponse> deleteNotebookSession(DeleteNotebookSessionRequest request, AsyncHandler<DeleteNotebookSessionRequest,DeleteNotebookSessionResponse> handler)
DataScienceAsync
Deletes the specified notebook session. Any unsaved work in this notebook session will be lost.
deleteNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteProjectResponse> deleteProject(DeleteProjectRequest request, AsyncHandler<DeleteProjectRequest,DeleteProjectResponse> handler)
DataScienceAsync
Deletes the specified project. This operation will fail unless all associated resources (such as notebook sessions or models) are in a DELETED state. You must delete all associated resources before deleting a project.
deleteProject
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetModelResponse> getModel(GetModelRequest request, AsyncHandler<GetModelRequest,GetModelResponse> handler)
DataScienceAsync
Gets the specified model’s information.
getModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetModelArtifactContentResponse> getModelArtifactContent(GetModelArtifactContentRequest request, AsyncHandler<GetModelArtifactContentRequest,GetModelArtifactContentResponse> handler)
DataScienceAsync
Downloads model artifact content for specified model.
getModelArtifactContent
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetModelProvenanceResponse> getModelProvenance(GetModelProvenanceRequest request, AsyncHandler<GetModelProvenanceRequest,GetModelProvenanceResponse> handler)
DataScienceAsync
Gets provenance information for specified model.
getModelProvenance
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetNotebookSessionResponse> getNotebookSession(GetNotebookSessionRequest request, AsyncHandler<GetNotebookSessionRequest,GetNotebookSessionResponse> handler)
DataScienceAsync
Gets the specified notebook session’s information.
getNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetProjectResponse> getProject(GetProjectRequest request, AsyncHandler<GetProjectRequest,GetProjectResponse> handler)
DataScienceAsync
Gets the specified project’s information.
getProject
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetWorkRequestResponse> getWorkRequest(GetWorkRequestRequest request, AsyncHandler<GetWorkRequestRequest,GetWorkRequestResponse> handler)
DataScienceAsync
Gets the specified work request’s information.
getWorkRequest
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<HeadModelArtifactResponse> headModelArtifact(HeadModelArtifactRequest request, AsyncHandler<HeadModelArtifactRequest,HeadModelArtifactResponse> handler)
DataScienceAsync
Gets model artifact metadata for specified model.
headModelArtifact
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListModelsResponse> listModels(ListModelsRequest request, AsyncHandler<ListModelsRequest,ListModelsResponse> handler)
DataScienceAsync
Lists models in the specified compartment.
listModels
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListNotebookSessionShapesResponse> listNotebookSessionShapes(ListNotebookSessionShapesRequest request, AsyncHandler<ListNotebookSessionShapesRequest,ListNotebookSessionShapesResponse> handler)
DataScienceAsync
Lists the valid notebook session shapes.
listNotebookSessionShapes
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListNotebookSessionsResponse> listNotebookSessions(ListNotebookSessionsRequest request, AsyncHandler<ListNotebookSessionsRequest,ListNotebookSessionsResponse> handler)
DataScienceAsync
Lists notebook sessions in the specified compartment.
listNotebookSessions
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListProjectsResponse> listProjects(ListProjectsRequest request, AsyncHandler<ListProjectsRequest,ListProjectsResponse> handler)
DataScienceAsync
Lists projects in the specified compartment.
listProjects
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestErrorsResponse> listWorkRequestErrors(ListWorkRequestErrorsRequest request, AsyncHandler<ListWorkRequestErrorsRequest,ListWorkRequestErrorsResponse> handler)
DataScienceAsync
Lists work request errors for the specified work request.
listWorkRequestErrors
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestLogsResponse> listWorkRequestLogs(ListWorkRequestLogsRequest request, AsyncHandler<ListWorkRequestLogsRequest,ListWorkRequestLogsResponse> handler)
DataScienceAsync
Lists work request logs for the specified work request.
listWorkRequestLogs
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestsResponse> listWorkRequests(ListWorkRequestsRequest request, AsyncHandler<ListWorkRequestsRequest,ListWorkRequestsResponse> handler)
DataScienceAsync
Lists work requests in the specified compartment.
listWorkRequests
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateModelResponse> updateModel(UpdateModelRequest request, AsyncHandler<UpdateModelRequest,UpdateModelResponse> handler)
DataScienceAsync
Updates the properties of a model. You can update the displayName
, description
, freeformTags
, and definedTags
properties.
updateModel
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateModelProvenanceResponse> updateModelProvenance(UpdateModelProvenanceRequest request, AsyncHandler<UpdateModelProvenanceRequest,UpdateModelProvenanceResponse> handler)
DataScienceAsync
Updates provenance information for the specified model.
updateModelProvenance
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateNotebookSessionResponse> updateNotebookSession(UpdateNotebookSessionRequest request, AsyncHandler<UpdateNotebookSessionRequest,UpdateNotebookSessionResponse> handler)
DataScienceAsync
Updates the properties of a notebook session. You can update the displayName
, freeformTags
, and definedTags
properties.
When the notebook session is in the INACTIVE lifecycle state, you can update notebookSessionConfigurationDetails
and change shape
, subnetId
, and blockStorageSizeInGBs
.
Changes to the notebookSessionConfigurationDetails
will take effect the next time the ActivateNotebookSession
action is invoked on the notebook session resource.
updateNotebookSession
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateProjectResponse> updateProject(UpdateProjectRequest request, AsyncHandler<UpdateProjectRequest,UpdateProjectResponse> handler)
DataScienceAsync
Updates the properties of a project. You can update the displayName
, description
, freeformTags
, and definedTags
properties.
updateProject
in interface DataScienceAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.Copyright © 2016–2021. All rights reserved.