CapabilityStatusstatus=service.getStatus(Capability.DATASTORE_WRITE).getStatus();if(status==CapabilityStatus.DISABLED){// Datastore is in read-only mode.}
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["很难理解","hardToUnderstand","thumb-down"],["信息或示例代码不正确","incorrectInformationOrSampleCode","thumb-down"],["没有我需要的信息/示例","missingTheInformationSamplesINeed","thumb-down"],["翻译问题","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-08-20。"],[[["The Capabilities API allows applications to detect outages and scheduled downtime for specific API capabilities, helping to minimize application downtime by bypassing unavailable services."],["This API supports first-generation runtimes and can be utilized when upgrading to corresponding second-generation runtimes, with specific migration guidance provided for Java 11/17 runtimes."],["The API returns an `ENABLED` status for all services except \"Datastore writes,\" which returns `DISABLED` when Datastore is in read-only mode."],["You can query the availability of Datastore reads and writes separately, enabling you to handle read-only mode scenarios by displaying a custom message to users."],["The API can verify the status of services like BLOBSTORE, Datastore, Images, Mail, Memcache, Task Queue, and URL Fetch, allowing for more fault-tolerant applications."]]],[]]