排解常見問題
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
如果遇到任何問題,請參閱下列章節尋求協助。
Fleet Engine 中的狀態遺失
使用 Fleet Engine 時,請設計可預測失敗情況的實作方式。舉例來說,如果您向 Fleet Engine 提出更新車輛的要求,系統可能會回應錯誤訊息,指出車輛不存在。您的實作項目應在新的狀態下重新建立車輛。
在極不可能發生的 Fleet Engine 重大故障情況下,您可能需要重新建立大部分或所有車輛和任務。如果建立率過高,系統會進行配額檢查以避免阻斷服務 (DoS) 攻擊,因此部分要求可能會再次因配額問題而失敗。在這種情況下,請使用重試的倒退策略來降低重建率。
重試
請務必確保系統會針對 Fleet Engine 的要求實作重試,因為這些要求可能偶爾會失敗。根據預設,Fleet Engine 用戶端程式庫會重試。
駕駛員應用程式中狀態遺失
如果驅動程式應用程式停止運作,應用程式必須在 Driver SDK 中重新建立目前的狀態。應用程式應嘗試重新建立工作,確保工作存在並還原目前狀態。應用程式也應重新建立並明確設定 Driver SDK 的停靠站清單。
注意:除了指出實體是否已存在於資料庫中,以及何時存在的錯誤以外,這些還原作業必須自行執行,不得依賴 Fleet Engine 提供的資訊。如果實體確實存在,則系統可吸收該錯誤,並使用實體的 ID 更新實體。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-02-28 (世界標準時間)。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-02-28 (世界標準時間)。"],[[["Fleet Engine implementations should be designed to handle failures and potential data loss by recreating vehicles and tasks when necessary."],["In case of Fleet Engine failures, use a backoff strategy to manage the recreation rate and avoid quota issues."],["Implement retries for Fleet Engine requests to address occasional failures, leveraging client library defaults or custom mechanisms."],["Driver apps should autonomously restore state after crashes by recreating tasks and stops within the Driver SDK, relying on error handling for existing entities."]]],["Implement error handling for Fleet Engine failures, such as vehicle non-existence, by recreating entities. In catastrophic failures, recreate vehicles and tasks, using a backoff strategy if quota issues arise. Implement request retries, as provided by Fleet Engine client libraries. If the driver app crashes, autonomously recreate tasks and stop lists within the Driver SDK, relying only on Fleet Engine errors to determine if entities already exist for update purposes.\n"]]