mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-10-17 22:10:54 +00:00
26 lines
447 B
C++
26 lines
447 B
C++
|
#pragma once
|
|||
|
|
|||
|
#include <string>
|
|||
|
#include <boost/noncopyable.hpp>
|
|||
|
|
|||
|
|
|||
|
namespace DB
|
|||
|
{
|
|||
|
|
|||
|
|
|||
|
/** Обеспечивает, что с одной директорией с данными может одновременно работать не более одного сервера.
|
|||
|
*/
|
|||
|
class StatusFile : private boost::noncopyable
|
|||
|
{
|
|||
|
public:
|
|||
|
StatusFile(const std::string & path_);
|
|||
|
~StatusFile();
|
|||
|
|
|||
|
private:
|
|||
|
const std::string path;
|
|||
|
int fd = -1;
|
|||
|
};
|
|||
|
|
|||
|
|
|||
|
}
|