Building the API client library requires Maven to be installed.
To install the API client library to your local Maven repository, simply execute:
mvn install
To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
mvn deploy
Refer to the official documentation for more information.
Add this dependency to your project's POM:
<dependency>
<groupId>org.kubeflow.client</groupId>
<artifactId>client-java-api</artifactId>
<version>0.1.0-SNAPSHOT</version>
<scope>compile</scope>
</dependency>
Add this dependency to your project's build file:
compile "org.kubeflow.client:client-java-api:0.1.0-SNAPSHOT"
At first generate the JAR by executing:
mvn package
Then manually install the following JARs:
- target/client-java-api-0.1.0-SNAPSHOT.jar
- target/lib/*.jar
Please follow the installation instruction and execute the following Java code:
import org.kubeflow.client.*;
import org.kubeflow.client.auth.*;
import org.kubeflow.client.models.*;
import org.kubeflow.client.apis.ApisApi;
import java.io.File;
import java.util.*;
public class ApisApiExample {
public static void main(String[] args) {
ApisApi apiInstance = new ApisApi();
try {
V1APIGroupList result = apiInstance.getAPIVersions();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ApisApi#getAPIVersions");
e.printStackTrace();
}
}
}
All URIs are relative to https://localhost
Class | Method | HTTP request | Description |
---|---|---|---|
ApisApi | getAPIVersions | GET /apis/ | |
KubeflowOrgApi | getAPIGroup | GET /apis/kubeflow.org/ | |
KubeflowOrgV1alpha2Api | createNamespacedTFJob | POST /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs | |
KubeflowOrgV1alpha2Api | deleteCollectionNamespacedTFJob | DELETE /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs | |
KubeflowOrgV1alpha2Api | deleteNamespacedTFJob | DELETE /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs/{name} | |
KubeflowOrgV1alpha2Api | getAPIResources | GET /apis/kubeflow.org/v1alpha2/ | |
KubeflowOrgV1alpha2Api | listNamespacedTFJob | GET /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs | |
KubeflowOrgV1alpha2Api | listTFJobForAllNamespaces | GET /apis/kubeflow.org/v1alpha2/tfjobs | |
KubeflowOrgV1alpha2Api | patchNamespacedTFJob | PATCH /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs/{name} | |
KubeflowOrgV1alpha2Api | readNamespacedTFJob | GET /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs/{name} | |
KubeflowOrgV1alpha2Api | replaceNamespacedTFJob | PUT /apis/kubeflow.org/v1alpha2/namespaces/{namespace}/tfjobs/{name} |
- V1alpha2TFJob
- V1alpha2TFJobCondition
- V1alpha2TFJobList
- V1alpha2TFJobSpec
- V1alpha2TFJobStatus
- V1alpha2TFReplicaSpec
- V1alpha2TFReplicaStatus
All endpoints do not require authorization. Authentication schemes defined for the API:
It's recommended to create an instance of ApiClient
per thread in a multithreaded environment to avoid any potential issues.