16 #ifndef IMPALA_RUNTIME_DISK_IO_MGR_STRESS_H
17 #define IMPALA_RUNTIME_DISK_IO_MGR_STRESS_H
20 #include <boost/scoped_ptr.hpp>
21 #include <boost/thread/mutex.hpp>
22 #include <boost/thread/condition_variable.hpp>
23 #include <boost/thread/thread.hpp>
24 #include <boost/unordered_map.hpp>
38 DiskIoMgrStress(
int num_disks,
int num_threads_per_disk,
int num_clients,
39 bool includes_cancellation);
std::vector< File > files_
DiskIoMgrStress(int num_disks, int num_threads_per_disk, int num_clients, bool includes_cancellation)
boost::thread_group readers_
Thread group for reader threads.
int num_clients_
Array of clients.
bool includes_cancellation_
If true, tests cancelling readers.
volatile bool shutdown_
Flag to signal that client reader threads should exit.
boost::scoped_ptr< DiskIoMgr > io_mgr_
io manager
void ClientThread(int client_id)
MemTracker dummy_tracker_
Dummy mem tracker.
This class is thread-safe.
void CancelRandomReader()
Possibly cancels a random reader.
void Run(int sec)
Run the test for 'sec'. If 0, run forever.