CernVM-FS  2.12.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
NfsMapsLeveldb::ForkAwareEnv Class Reference
Inheritance diagram for NfsMapsLeveldb::ForkAwareEnv:
Collaboration diagram for NfsMapsLeveldb::ForkAwareEnv:

Public Member Functions

 ForkAwareEnv (NfsMapsLeveldb *maps)
void StartThread (void(*f)(void *), void *a)
void Schedule (void(*function)(void *), void *arg)
void WaitForBGThreads ()
void SleepForMicroseconds (int micros)

Static Private Member Functions

static void * MainFakeThread (void *data)

Private Attributes

atomic_int32 num_bg_threads_

Detailed Description

Leveldb's background threads must not be started before cvmfs has forked. Before forking, we run the processes in specially created threads. We make sure, these threads are terminated before forking.

Definition at line 58 of file nfs_maps_leveldb.h.

Constructor & Destructor Documentation

NfsMapsLeveldb::ForkAwareEnv::ForkAwareEnv ( NfsMapsLeveldb maps)

Definition at line 38 of file

Member Function Documentation

void * NfsMapsLeveldb::ForkAwareEnv::MainFakeThread ( void *  data)

Definition at line 92 of file

void NfsMapsLeveldb::ForkAwareEnv::Schedule ( void(*)(void *)  function,
void *  arg 

Definition at line 57 of file

Here is the call graph for this function:

void NfsMapsLeveldb::ForkAwareEnv::SleepForMicroseconds ( int  micros)

Leveldb's usleep might collide with the ALARM timer

Definition at line 87 of file

Here is the call graph for this function:

void NfsMapsLeveldb::ForkAwareEnv::StartThread ( void(*)(void *)  f,
void *  a 

Definition at line 46 of file

void NfsMapsLeveldb::ForkAwareEnv::WaitForBGThreads ( )

Definition at line 78 of file

Referenced by NfsMapsLeveldb::Create().

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

NfsMapsLeveldb* NfsMapsLeveldb::ForkAwareEnv::maps_

Definition at line 69 of file nfs_maps_leveldb.h.

atomic_int32 NfsMapsLeveldb::ForkAwareEnv::num_bg_threads_

Definition at line 70 of file nfs_maps_leveldb.h.

Referenced by ForkAwareEnv(), and MainFakeThread().

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