Exit#
-
void YR::Exit()#
Exit the current function instance.
This function is not supported for local calls (either in LOCAL_MODE or local calls within CLUSTER_MODE). If called locally, it will throw a “Not support exit out of cluster” exception.
void AddOneAndPut(int x) { YR::KV().Set("key", std::to_string(x)); // The function instance will exit after setting the key and value YR::Exit(); } YR_INVOKE(AddOneAndPut);
- Throws:
Exception – If called in a local environment, it throws an exception with the message “Not support exit out of cluster”.