MySQL 9.0.0
Source Code Documentation
Gcs_xcom_state_exchange_interface Class Referenceabstract

#include <gcs_xcom_state_exchange.h>

Inheritance diagram for Gcs_xcom_state_exchange_interface:
[legend]

Public Member Functions

virtual ~Gcs_xcom_state_exchange_interface ()=default
 
virtual void init ()=0
 Accomplishes all necessary initialization steps. More...
 
virtual void reset ()=0
 If messages were buffered during its processing, they are discarded and internal structures needed are cleaned up. More...
 
virtual void reset_with_flush ()=0
 Has the same behavior as the reset but additionally flushes buffered messages. More...
 
virtual void end ()=0
 If messages were buffered during its processing, they are delivered to upper layers and internal structures needed are cleaned up. More...
 
virtual bool state_exchange (synode_no configuration_id, std::vector< Gcs_member_identifier * > &total, std::vector< Gcs_member_identifier * > &left, std::vector< Gcs_member_identifier * > &joined, std::vector< std::unique_ptr< Gcs_message_data > > &exchangeable_data, Gcs_view *current_view, std::string *group, const Gcs_member_identifier &local_info, const Gcs_xcom_nodes &xcom_nodes)=0
 Signals the module to start a State Exchange. More...
 
virtual bool process_member_state (Xcom_member_state *ms_info, const Gcs_member_identifier &p_id, Gcs_protocol_version maximum_supported_protocol_version, Gcs_protocol_version used_protocol_version)=0
 Processes a member state message on an ongoing State Exchange round. More...
 
virtual std::vector< Gcs_xcom_node_informationcompute_incompatible_members ()=0
 Compute the set of incompatible members after the state exchange has finished. More...
 
virtual bool process_recovery_state ()=0
 Recovers any missing packets required for the member to join the group. More...
 
virtual Gcs_xcom_view_identifierget_new_view_id ()=0
 Retrieves the new view identifier after a State Exchange. More...
 
virtual std::set< Gcs_member_identifier * > * get_joined ()=0
 
virtual std::set< Gcs_member_identifier * > * get_left ()=0
 
virtual std::set< Gcs_member_identifier * > * get_total ()=0
 
virtual std::string * get_group ()=0
 
virtual std::map< Gcs_member_identifier, Xcom_member_state * > * get_member_states ()=0
 
virtual void compute_maximum_supported_protocol_version ()=0
 Computes the maximum protocol version supported by the group. More...
 

Constructor & Destructor Documentation

◆ ~Gcs_xcom_state_exchange_interface()

virtual Gcs_xcom_state_exchange_interface::~Gcs_xcom_state_exchange_interface ( )
virtualdefault

Member Function Documentation

◆ compute_incompatible_members()

virtual std::vector< Gcs_xcom_node_information > Gcs_xcom_state_exchange_interface::compute_incompatible_members ( )
pure virtual

Compute the set of incompatible members after the state exchange has finished.

A member M is incompatible if it is attempting to join a group that is using protocol X, but M is using protocol Y s.t. X != Y.

Returns
the set of incompatible members

Implemented in Gcs_xcom_state_exchange.

◆ compute_maximum_supported_protocol_version()

virtual void Gcs_xcom_state_exchange_interface::compute_maximum_supported_protocol_version ( )
pure virtual

Computes the maximum protocol version supported by the group.

Implemented in Gcs_xcom_state_exchange.

◆ end()

virtual void Gcs_xcom_state_exchange_interface::end ( )
pure virtual

If messages were buffered during its processing, they are delivered to upper layers and internal structures needed are cleaned up.

Implemented in Gcs_xcom_state_exchange.

◆ get_group()

virtual std::string * Gcs_xcom_state_exchange_interface::get_group ( )
pure virtual
Returns
the group in which this State Exchange is occurring

Implemented in Gcs_xcom_state_exchange.

◆ get_joined()

virtual std::set< Gcs_member_identifier * > * Gcs_xcom_state_exchange_interface::get_joined ( )
pure virtual
Returns
the members that joined in this State Exchange round

Implemented in Gcs_xcom_state_exchange.

◆ get_left()

virtual std::set< Gcs_member_identifier * > * Gcs_xcom_state_exchange_interface::get_left ( )
pure virtual
Returns
the members that left in this State Exchange round

Implemented in Gcs_xcom_state_exchange.

◆ get_member_states()

virtual std::map< Gcs_member_identifier, Xcom_member_state * > * Gcs_xcom_state_exchange_interface::get_member_states ( )
pure virtual
Returns
the saved states

Implemented in Gcs_xcom_state_exchange.

◆ get_new_view_id()

virtual Gcs_xcom_view_identifier * Gcs_xcom_state_exchange_interface::get_new_view_id ( )
pure virtual

Retrieves the new view identifier after a State Exchange.

Returns
the new view identifier

Implemented in Gcs_xcom_state_exchange.

◆ get_total()

virtual std::set< Gcs_member_identifier * > * Gcs_xcom_state_exchange_interface::get_total ( )
pure virtual
Returns
All the members in this State Exchange round

Implemented in Gcs_xcom_state_exchange.

◆ init()

virtual void Gcs_xcom_state_exchange_interface::init ( )
pure virtual

Accomplishes all necessary initialization steps.

Implemented in Gcs_xcom_state_exchange.

◆ process_member_state()

virtual bool Gcs_xcom_state_exchange_interface::process_member_state ( Xcom_member_state ms_info,
const Gcs_member_identifier p_id,
Gcs_protocol_version  maximum_supported_protocol_version,
Gcs_protocol_version  used_protocol_version 
)
pure virtual

Processes a member state message on an ongoing State Exchange round.

Parameters
[in]ms_inforeceived Member State
[in]p_idthe node that the Member State pertains
[in]maximum_supported_protocol_versionmaximum supported protocol version
[in]used_protocol_versionprotocol version in use by a member during the state exchange phase
Returns
true if State Exchanged is to be finished and the view can be installed

Implemented in Gcs_xcom_state_exchange.

◆ process_recovery_state()

virtual bool Gcs_xcom_state_exchange_interface::process_recovery_state ( )
pure virtual

Recovers any missing packets required for the member to join the group.

Return values
trueif successful
falseotherwise

Implemented in Gcs_xcom_state_exchange.

◆ reset()

virtual void Gcs_xcom_state_exchange_interface::reset ( )
pure virtual

If messages were buffered during its processing, they are discarded and internal structures needed are cleaned up.

Implemented in Gcs_xcom_state_exchange.

◆ reset_with_flush()

virtual void Gcs_xcom_state_exchange_interface::reset_with_flush ( )
pure virtual

Has the same behavior as the reset but additionally flushes buffered messages.

Implemented in Gcs_xcom_state_exchange.

◆ state_exchange()

virtual bool Gcs_xcom_state_exchange_interface::state_exchange ( synode_no  configuration_id,
std::vector< Gcs_member_identifier * > &  total,
std::vector< Gcs_member_identifier * > &  left,
std::vector< Gcs_member_identifier * > &  joined,
std::vector< std::unique_ptr< Gcs_message_data > > &  exchangeable_data,
Gcs_view current_view,
std::string *  group,
const Gcs_member_identifier local_info,
const Gcs_xcom_nodes xcom_nodes 
)
pure virtual

Signals the module to start a State Exchange.

Parameters
[in]configuration_idConfiguration identifier in use when the state exchange phase started
[in]totalxcom total members in the new view
[in]leftxcom members that left in the new view
[in]joinedxcom members that joined in the new view
[in]exchangeable_datageneric exchanged data
[in]current_viewthe currently installed view
[in]groupgroup name
[in]local_infothe local GCS member identifier
[in]xcom_nodeslist of nodes
Returns
true if the member is leaving

Implemented in Gcs_xcom_state_exchange.


The documentation for this class was generated from the following file: