mirror of
https://github.com/ceph/ceph
synced 2025-01-05 02:32:59 +00:00
f72b881249
Fixes: http://tracker.ceph.com/issues/19012 Signed-off-by: liuchang0812 <liuchang0812@gmail.com>
32 lines
720 B
C++
32 lines
720 B
C++
// -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
|
|
// vim: ts=8 sw=2 smarttab
|
|
#ifndef CEPH_LIBRBD_LIBRBDADMINSOCKETHOOK_H
|
|
#define CEPH_LIBRBD_LIBRBDADMINSOCKETHOOK_H
|
|
|
|
#include <map>
|
|
|
|
#include "common/admin_socket.h"
|
|
|
|
namespace librbd {
|
|
|
|
struct ImageCtx;
|
|
class LibrbdAdminSocketCommand;
|
|
|
|
class LibrbdAdminSocketHook : public AdminSocketHook {
|
|
public:
|
|
LibrbdAdminSocketHook(ImageCtx *ictx);
|
|
~LibrbdAdminSocketHook() override;
|
|
|
|
bool call(std::string command, cmdmap_t& cmdmap, std::string format,
|
|
bufferlist& out) override;
|
|
|
|
private:
|
|
typedef std::map<std::string,LibrbdAdminSocketCommand*> Commands;
|
|
|
|
AdminSocket *admin_socket;
|
|
Commands commands;
|
|
};
|
|
}
|
|
|
|
#endif
|