The linked SFSE question covers the problem in more detail, but generally, if I'm in Apex and have a Cache.OrgPartition, how can I tell if it actually has any capacity to cache data without calling getCapactiy()?
I don't want to waste resources trying to cache things into an empty cache. Nor to I want to call the potentially expensive getCapacity() method when I'm trying to use the cache to avoid expensive operations.
How can I detect that a packaged Platform Cache Partition has no capacity allocated?
Escrever um comentário...
0/9000