Skip to content

Files

Latest commit

faffdc0 · Aug 3, 2018

History

History

kubernetes

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Jul 17, 2018
Aug 3, 2018
Jul 17, 2018
Aug 3, 2018
Jul 17, 2018
Jul 17, 2018
Jul 17, 2018
Jul 18, 2018
Jul 18, 2018
Jul 18, 2018
Jul 18, 2018
Jul 17, 2018
Jul 17, 2018
Jul 17, 2018
Jul 18, 2018
Jul 18, 2018

README.md

client-java-api

Requirements

Building the API client library requires Maven to be installed.

Installation

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.

Maven users

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>

Gradle users

Add this dependency to your project's build file:

compile "org.kubeflow.client:client-java-api:0.1.0-SNAPSHOT"

Others

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

Getting Started

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();
        }
    }
}

Documentation for API Endpoints

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}

Documentation for Models

Documentation for Authorization

All endpoints do not require authorization. Authentication schemes defined for the API:

Recommendation

It's recommended to create an instance of ApiClient per thread in a multithreaded environment to avoid any potential issues.

Author