IClusterClient

public interface IClusterClient

com.android.tradefed.cluster.IClusterClient


TFC 백엔드와 상호작용하기 위한 인터페이스입니다.

요약

상수

String TYPE_NAME

고유한 구성 객체 유형 이름입니다.

공개 메서드

abstract IClusterEventUploader<ClusterCommandEvent> getCommandEventUploader()

ClusterCommandEvent을 업로드하는 데 사용할 수 있는 IClusterEventUploader을 가져옵니다.

abstract ClusterCommand.State getCommandState(String requestId, String commandId)

클러스터 명령의 상태를 확인합니다.

default ClusterCommandStatus getCommandStatus(String requestId, String commandId)

클러스터 명령의 명령 상태를 가져옵니다 (취소된 경우 상태 및 취소 이유).

abstract IClusterEventUploader<ClusterHostEvent> getHostEventUploader()

ClusterHostEvent을 업로드하는 데 사용할 수 있는 IClusterEventUploader을 가져옵니다.

abstract TestContext getTestContext(String requestId, String commandId)
abstract TestEnvironment getTestEnvironment(String requestId)

요청의 TestEnvironment을 가져옵니다.

abstract List<TestResource> getTestResources(String requestId)

요청의 TestResource 가져오기

abstract List<ClusterCommand> leaseHostCommands(String clusterId, String hostname, List<ClusterDeviceInfo> devices, List<String> nextClusterIds, int maxTasksTolease)

지정된 호스트에 대해 ClusterCommand를 임대합니다.

abstract void updateTestContext(String requestId, String commandId, TestContext testContext)

상수

TYPE_NAME

public static final String TYPE_NAME

고유한 구성 객체 유형 이름입니다. GlobalConfiguration에서 싱글톤 인스턴스를 가져오는 데 사용됩니다.

상수 값: 'cluster_client'

공개 메서드

getCommandEventUploader

public abstract IClusterEventUploader<ClusterCommandEvent> getCommandEventUploader ()

ClusterCommandEvent을 업로드하는 데 사용할 수 있는 IClusterEventUploader을 가져옵니다.

반환
IClusterEventUploader<ClusterCommandEvent>

getCommandState

public abstract ClusterCommand.State getCommandState (String requestId, 
                String commandId)

클러스터 명령의 상태를 확인합니다.

매개변수
requestId String: 클러스터 요청 ID

commandId String: 클러스터 명령 ID

반환
ClusterCommand.State 클러스터 명령의 상태 또는 상태를 확인할 수 없는 경우 ClusterCommand.State.UNKNOWN

getCommandStatus

public ClusterCommandStatus getCommandStatus (String requestId, 
                String commandId)

클러스터 명령의 명령 상태를 가져옵니다 (취소된 경우 상태 및 취소 이유).

매개변수
requestId String: 클러스터 요청 ID

commandId String: 클러스터 명령 ID

반환
ClusterCommandStatus 명령어가 취소된 경우 상태와 취소 이유를 나타내는 ClusterCommandStatus입니다. 상태를 확인할 수 없는 경우 상태는 ClusterCommand.State.UNKNOWN입니다.

getHostEventUploader

public abstract IClusterEventUploader<ClusterHostEvent> getHostEventUploader ()

ClusterHostEvent을 업로드하는 데 사용할 수 있는 IClusterEventUploader을 가져옵니다.

반환
IClusterEventUploader<ClusterHostEvent>

getTestContext

public abstract TestContext getTestContext (String requestId, 
                String commandId)

매개변수
requestId String

commandId String

반환
TestContext

생성 값
IOException
JSONException

getTestEnvironment

public abstract TestEnvironment getTestEnvironment (String requestId)

요청의 TestEnvironment을 가져옵니다.

반환
TestEnvironment TestEnvironment 객체

생성 값
java.io.IOException
org.json.JSONException
IOException
JSONException

getTestResources

public abstract List<TestResource> getTestResources (String requestId)

요청의 TestResource 가져오기

반환
List<TestResource> TestResource 목록

생성 값
java.io.IOException
org.json.JSONException
IOException
JSONException

leaseHostCommands

public abstract List<ClusterCommand> leaseHostCommands (String clusterId, 
                String hostname, 
                List<ClusterDeviceInfo> devices, 
                List<String> nextClusterIds, 
                int maxTasksTolease)

지정된 호스트에 대해 ClusterCommand를 임대합니다.

매개변수
clusterId String: 호스트의 클러스터 ID

hostname String: 호스트 이름

devices List: 호스트가 보유한 deviceInfos

nextClusterIds List: 명령어를 임대할 다음 클러스터 ID 목록입니다.

maxTasksTolease int: 현재 임대할 수 있는 최대 작업 수

반환
List<ClusterCommand> ClusterCommand 목록

생성 값
org.json.JSONException
JSONException

updateTestContext

public abstract void updateTestContext (String requestId, 
                String commandId, 
                TestContext testContext)

매개변수
requestId String

commandId String

testContext TestContext

생성 값
IOException
JSONException