STLdb

PrevUpHomeNext

Struct template SharedLogInfo

stldb::SharedLogInfo

Synopsis

// In header: </Users/bobw/workspaces/STLdb/stldb_lib/stldb/logger.h>

template<typename void_alloc_t, typename mutex_type> 
struct SharedLogInfo {
  // types
  typedef void_alloc_t::template rebind< char >::other                                          shm_char_alloc_t;
  typedef boost::interprocess::basic_string< char, std::char_traits< char >, shm_char_alloc_t > shm_string;      
  typedef stldb::commit_buffer_t< void_alloc_t > *                                              waiting_write;   
  typedef void_alloc_t::template rebind< waiting_write >::other                                 deque_alloc_t;   

  // construct/copy/destruct
  SharedLogInfo(const void_alloc_t &);

  // public member functions
  template<typename Archive> void serialize(Archive &, const unsigned int);

  // public data members
  mutex_type _queue_mutex;
  mutex_type _file_mutex;
  transaction_id_t _next_lsn;
  transaction_id_t _last_write_txn_id;
  transaction_id_t _last_sync_txn_id;
  boost::interprocess::deque< waiting_write, deque_alloc_t > waiting_txns;
  shm_string log_dir;
  shm_string log_filename;
  boost::interprocess::offset_t log_len;
  boost::interprocess::offset_t log_max_len;
  bool log_sync;
  struct log_stats stats;
};

Description

The Logging information kept in shared memory

SharedLogInfo public construct/copy/destruct

  1. SharedLogInfo(const void_alloc_t & alloc);

SharedLogInfo public member functions

  1. template<typename Archive> 
      void serialize(Archive & ar, const unsigned int version);

PrevUpHomeNext