Updated: April 19, 2023 |
Get a publish/subscribe provider handle
#include <pips/pips.h>
pips_provider_t* pips_get_provider(const char *opt_name)
This function queries the provider factory to retrieve a handle to a provider implementation. The provider can be specified by name, but it's better to pass in NULL to request the default provider. This way, you don't have to change (and hence, rebuild) the code if you want to use a different provider; you just have to update your PiPS configuration.
On success, a provider handle (which is a pointer to a pips_provider_t object). On error, this function returns NULL and sets errno.