ไอคลัสเตอร์ไคลเอนต์
public interface IClusterClient
com.android.tradefed.cluster.IClusterClient |
อินเทอร์เฟซสำหรับการโต้ตอบกับแบ็กเอนด์ TFC
สรุป
ค่าคงที่ |
---|
String | TYPE_NAME ชื่อประเภทอ็อบเจกต์คอนฟิกูเรชันเฉพาะ |
วิธีการสาธารณะ |
---|
abstract IClusterEventUploader < ClusterCommandEvent > | getCommandEventUploader () รับ IClusterEventUploader ที่สามารถใช้เพื่ออัปโหลด ClusterCommandEvent s |
abstract ClusterCommand.State | getCommandState (String requestId, String commandId) กำหนดสถานะของคำสั่งคลัสเตอร์ |
default ClusterCommandStatus | getCommandStatus (String requestId, String commandId) รับสถานะคำสั่งของคำสั่งคลัสเตอร์ (สถานะและเหตุผลการยกเลิกหากยกเลิก) |
abstract IClusterEventUploader < ClusterHostEvent > | getHostEventUploader () รับ IClusterEventUploader ที่สามารถใช้เพื่ออัปโหลด ClusterHostEvent s |
abstract TestContext | getTestContext (String requestId, String commandId) |
abstract TestEnvironment | getTestEnvironment (String requestId) รับ TestEnvironment สำหรับคำขอ |
abstract | getTestResources (String requestId) รับ TestResource สำหรับคำขอ |
abstract | leaseHostCommands (String clusterId, String hostname, devices, nextClusterIds, int maxTasksTolease) leaseHostCommands (String clusterId, String hostname, devices, nextClusterIds, int maxTasksTolease) leaseHostCommands (String clusterId, String hostname, devices, nextClusterIds, int maxTasksTolease) เช่า ClusterCommand สำหรับโฮสต์ Give |
abstract void | updateTestContext (String requestId, String commandId, TestContext testContext) |
ค่าคงที่
TYPE_NAME
public static final String TYPE_NAME
ชื่อประเภทอ็อบเจกต์คอนฟิกูเรชันเฉพาะ ใช้เพื่อดึงอินสแตนซ์ singleton จาก GlobalConfiguration
ค่าคงที่: "cluster_client"
วิธีการสาธารณะ
getCommandState
public abstract ClusterCommand.State getCommandState (String requestId,
String commandId)
กำหนดสถานะของคำสั่งคลัสเตอร์
พารามิเตอร์ |
---|
requestId | String : รหัสคำขอของคลัสเตอร์ |
commandId | String : ID คำสั่งคลัสเตอร์ |
รับสถานะคำสั่ง
public ClusterCommandStatus getCommandStatus (String requestId,
String commandId)
รับสถานะคำสั่งของคำสั่งคลัสเตอร์ (สถานะและเหตุผลการยกเลิกหากยกเลิก)
พารามิเตอร์ |
---|
requestId | String : รหัสคำขอของคลัสเตอร์ |
commandId | String : ID คำสั่งคลัสเตอร์ |
รับการทดสอบบริบท
public abstract TestContext getTestContext (String requestId,
String commandId)
พารามิเตอร์ |
---|
requestId | String |
commandId | String |
รับการทดสอบสภาพแวดล้อม
public abstract TestEnvironment getTestEnvironment (String requestId)
รับ TestEnvironment
สำหรับคำขอ
พ่น |
---|
| IOข้อยกเว้น |
| org.json.JSONException |
JSONException | |
getTestResources
public abstract getTestResources (String requestId)
รับ TestResource
สำหรับคำขอ
พ่น |
---|
| IOข้อยกเว้น |
| org.json.JSONException |
JSONException | |
คำสั่งเช่าโฮสต์
public abstract leaseHostCommands (String clusterId,
String hostname,
devices,
nextClusterIds,
int maxTasksTolease)
เช่า ClusterCommand
สำหรับโฮสต์ Give
พารามิเตอร์ |
---|
clusterId | String : รหัสคลัสเตอร์สำหรับโฮสต์ |
hostname | String : ชื่อโฮสต์ |
devices | : deviceInfos ที่โฮสต์มี |
nextClusterIds | : รายการ ID คลัสเตอร์ถัดไปที่จะเช่าคำสั่งจาก |
maxTasksTolease | int : จำนวนงานสูงสุดที่สามารถเช่าได้ในปัจจุบัน |
พ่น |
---|
| org.json.JSONException |
JSONException | |
อัปเดต TestContext
public abstract void updateTestContext (String requestId,
String commandId,
TestContext testContext)
พารามิเตอร์ |
---|
requestId | String |
commandId | String |
testContext | TestContext |