Essentially, you invoke call
method template of the service_t
base class by providing a messagetype and message arguments:
call<cocaine::io::storage::read>(collection, key);
In this example, cocaine::io::storage::read
is the message type from cocaine/messages.hpp
— https://github.com/cocaine/cocaine-core/blob/v0.11/include/cocaine/messages.hpp#L291, in v0.11 branch this file defines all interfaces for builtin services.
Here's the Issue for this topic on GH: https://github.com/cocaine/cocaine-framework-native/issues/16