GNUnet  0.17.6
Macros | Typedefs | Functions
gnunet_consensus_service.h File Reference

Multi-peer set reconciliation. More...

#include "gnunet_common.h"
#include "gnunet_time_lib.h"
#include "gnunet_configuration_lib.h"
#include "gnunet_set_service.h"
Include dependency graph for gnunet_consensus_service.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


 Elements inserted into the consensus set by the client may not be larger than this constant, since types in the upper range are used by CONSENSUS internally. More...


typedef void(* GNUNET_CONSENSUS_ElementCallback) (void *cls, const struct GNUNET_SET_Element *element)
 Called when a new element was received from another peer, or an error occurred. More...
typedef void(* GNUNET_CONSENSUS_InsertDoneCallback) (void *cls, int success)
 Called when an insertion (transmission to consensus service, which does not imply fully consensus on this element with all other peers) was successful. More...
typedef void(* GNUNET_CONSENSUS_ConcludeCallback) (void *cls)
 Called when a conclusion was successful. More...


struct GNUNET_CONSENSUS_HandleGNUNET_CONSENSUS_create (const struct GNUNET_CONFIGURATION_Handle *cfg, unsigned int num_peers, const struct GNUNET_PeerIdentity *peers, const struct GNUNET_HashCode *session_id, struct GNUNET_TIME_Absolute start, struct GNUNET_TIME_Absolute deadline, GNUNET_CONSENSUS_ElementCallback new_element_cb, void *new_element_cls)
 Create a consensus session. More...
void GNUNET_CONSENSUS_insert (struct GNUNET_CONSENSUS_Handle *consensus, const struct GNUNET_SET_Element *element, GNUNET_CONSENSUS_InsertDoneCallback idc, void *idc_cls)
 Insert an element in the set being reconsiled. More...
void GNUNET_CONSENSUS_conclude (struct GNUNET_CONSENSUS_Handle *consensus, GNUNET_CONSENSUS_ConcludeCallback conclude, void *conclude_cls)
 We are finished inserting new elements into the consensus; try to conclude the consensus within a given time window. More...
void GNUNET_CONSENSUS_destroy (struct GNUNET_CONSENSUS_Handle *consensus)
 Destroy a consensus handle (free all state associated with it, no longer call any of the callbacks). More...

Detailed Description

Multi-peer set reconciliation.

Definition in file gnunet_consensus_service.h.