DbEnv::repmgr_site_list API Ref

#include <db_cxx.h>

int DbEnv::repmgr_site_list(u_int *countp, DB_REPMGR_SITE **listp);


Description: DbEnv::repmgr_site_list

The DbEnv::repmgr_site_list method returns the status of the sites currently known by the replication manager.

The DbEnv::repmgr_site_list method creates a statistical structure of type DB_REPMGR_SITE and copies a pointer to it into a user-specified memory location.

Statistical structures are stored in allocated memory. If application-specific allocation routines have been declared (see DbEnv::set_alloc for more information), they are used to allocate the memory; otherwise, the standard C library malloc(3) is used. The caller is responsible for deallocating the memory. To deallocate the memory, free the memory reference; references inside the returned memory need not be individually freed.

The following DB_REPMGR_SITE fields will be filled in:


int eid; char host[]; u_int port; u_int32_t status;

The DbEnv::repmgr_site_list method may be called at any time during the life of the application.

The DbEnv::repmgr_site_list method either returns a non-zero error value or throws an exception that encapsulates a non-zero error value on failure, and returns 0 on success.

Parameters
countp listp


Class DbEnv
See Also Replication and Related Methods

APIRef

Copyright (c) 1996,2008 Oracle. All rights reserved.