mongoc_client_pool_set_ssl_opts() — MongoDB C Driver 1.9.2

- MongoDB C Driver 1.9.2 »
- API Reference »
- mongoc_client_pool_t

# mongoc_client_pool_set_ssl_opts()

## Synopsis

    #ifdef MONGOC_ENABLE_SSL
    void
    mongoc_client_pool_set_ssl_opts (mongoc_client_pool_t *pool,
                                     const mongoc_ssl_opt_t *opts);
    #endif

This function is identical to mongoc_client_set_ssl_opts() except for client pools. It ensures that all clients retrieved from mongoc_client_pool_pop() or mongoc_client_pool_try_pop() are configured with the same SSL settings.

The `mongoc_ssl_opt_t` struct is copied by the pool along with the strings it points to (`pem_file`, `pem_pwd`, `ca_file`, `ca_dir`, and `crl_file`) so they don’t have to remain valid after the call to `mongoc_client_pool_set_ssl_opts`.

## Parameters

- `pool`: A mongoc_client_pool_t.
- `opts`: A mongoc_ssl_opt_t.

## Thread Safety

This function can only be called once on a pool, and must be called before the first call to mongoc_client_pool_pop().

## Availability

This feature requires that the MongoDB C driver was compiled with `--enable-ssl`.

Created using Sphinx 1.6.5, based on Sphinx Readable Theme.