Update the total object size limit used by the size controller. The limit must be positive and takes effect when the size controller next runs. Returns false if no size controller is active for this cache (i.e., objectSizeTrackingEnabled is false or sizeControllerIntervalMs == 0), or if totalObjectSizeLimit is zero.
| 453 | // objectSizeTrackingEnabled is false or sizeControllerIntervalMs == 0), |
| 454 | // or if totalObjectSizeLimit is zero. |
| 455 | bool setTotalObjectSizeLimit(size_t totalObjectSizeLimit) { |
| 456 | if (totalObjectSizeLimit == 0 || sizeController_ == nullptr) { |
| 457 | return false; |
| 458 | } |
| 459 | sizeController_->setTotalObjectSizeLimit(totalObjectSizeLimit); |
| 460 | return true; |
| 461 | } |
| 462 | |
| 463 | // Get the expiry timestamp of the object |
| 464 | // @param object object shared pointer returned from ObjectCache APIs |
no outgoing calls