RemoteCacheClient
public
class
RemoteCacheClient
extends Object
implements
ICacheClient
java.lang.Object | |
↳ | com.android.tradefed.cache.remote.RemoteCacheClient |
การใช้งาน RemoteActionCache ที่ใช้การเรียก gRPC ไปยังเซิร์ฟเวอร์ API ระยะไกล
สรุป
ช่อง | |
---|---|
public
static
final
Duration |
REMOTE_TIMEOUT
|
ตัวสร้างแบบสาธารณะ | |
---|---|
RemoteCacheClient(File workFolder, String instanceName, ManagedChannel channel, CallCredentials callCredentials, ByteStreamDownloader downloader, ByteStreamUploader uploader)
|
เมธอดสาธารณะ | |
---|---|
ExecutableActionResult
|
lookupCache(ExecutableAction action)
ค้นหา |
void
|
uploadCache(ExecutableAction action, ExecutableActionResult actionResult)
อัปโหลดผลลัพธ์สำหรับ |
ช่อง
REMOTE_TIMEOUT
public static final Duration REMOTE_TIMEOUT
ตัวสร้างแบบสาธารณะ
RemoteCacheClient
public RemoteCacheClient (File workFolder, String instanceName, ManagedChannel channel, CallCredentials callCredentials, ByteStreamDownloader downloader, ByteStreamUploader uploader)
พารามิเตอร์ | |
---|---|
workFolder |
File |
instanceName |
String |
channel |
ManagedChannel |
callCredentials |
CallCredentials |
downloader |
ByteStreamDownloader |
uploader |
ByteStreamUploader |
เมธอดสาธารณะ
lookupCache
public ExecutableActionResult lookupCache (ExecutableAction action)
ค้นหา ExecutableActionResult
สำหรับ action
โปรดทราบว่าผู้เรียกใช้ควรลบไฟล์เอาต์พุตหลังจากใช้งานเพื่อไม่ให้พื้นที่ในดิสก์เต็ม
พารามิเตอร์ | |
---|---|
action |
ExecutableAction : ExecutableAction ที่ควรแสดงผลลัพธ์ |
คิกรีเทิร์น | |
---|---|
ExecutableActionResult |
ExecutableActionResult ของ action หากมีผลลัพธ์ มิเช่นนั้นจะเป็น Null |
uploadCache
public void uploadCache (ExecutableAction action, ExecutableActionResult actionResult)
อัปโหลดผลลัพธ์สำหรับ ExecutableAction
หากผลลัพธ์ของ action
ไม่มีอยู่ ระบบจะจัดเก็บ actionResult
มิฉะนั้น ระบบจะอัปเดตผลลัพธ์
พารามิเตอร์ | |
---|---|
action |
ExecutableAction : การดำเนินการที่ทำให้เกิดผลลัพธ์ |
actionResult |
ExecutableActionResult : ผลลัพธ์การดำเนินการที่จะเชื่อมโยงกับ action |