Commit b1840206 authored by David COME's avatar David COME
Browse files

Added interface for ClientProxy

parent d34a5f88
/*
* File: ClientInterface.hpp
* Author: dcome
*
* Created on March 18, 2014, 12:27 PM
*/
#ifndef CLIENTINTERFACE_HPP
#define CLIENTINTERFACE_HPP
#include "castor/tape/legacymsg/RtcpJobRqstMsgBody.hpp"
#include "castor/tape/tapeserver/exception/Exception.hpp"
#include "castor/tape/tapegateway/GatewayMessage.hpp"
#include "castor/tape/tapegateway/ClientType.hpp"
#include "castor/tape/tapegateway/VolumeMode.hpp"
#include "castor/tape/tapegateway/FilesToMigrateList.hpp"
#include "castor/tape/tapegateway/FileMigrationReportList.hpp"
#include "castor/tape/tapegateway/FilesToRecallList.hpp"
#include "castor/tape/tapegateway/FileRecallReportList.hpp"
#include "../threading/Threading.hpp"
namespace castor {
namespace tape {
namespace tapeserver {
namespace daemon {
class ClientInterface {
public :
/**
* Class holding the timing information for the request/reply,
* and the message sequence Id.
*/
class RequestReport {
public:
RequestReport(): transactionId(0),
connectDuration(0), sendRecvDuration(0) {}
uint32_t transactionId;
double connectDuration;
double sendRecvDuration;
};
virtual tapegateway::FilesToRecallList * getFilesToRecall(uint64_t files,
uint64_t bytes, RequestReport &report)
throw (castor::tape::Exception) = 0;
};
}}}}
#endif /* CLIENTINTERFACE_HPP */
......@@ -33,6 +33,7 @@
#include "castor/tape/tapegateway/FileMigrationReportList.hpp"
#include "castor/tape/tapegateway/FilesToRecallList.hpp"
#include "castor/tape/tapegateway/FileRecallReportList.hpp"
#include "castor/tape/tapeserver/daemon/ClientInterface.hpp"
#include "../threading/Threading.hpp"
namespace castor {
......@@ -44,7 +45,7 @@ namespace daemon {
* The client address will have been received from the VDQM by the main
* process.
*/
class ClientProxy {
class ClientProxy : public ClientInterface {
public:
/**
* Constructor: contact client, gather initial information about the
......@@ -55,19 +56,6 @@ namespace daemon {
ClientProxy(const legacymsg::RtcpJobRqstMsgBody & clientRequest)
throw (castor::tape::Exception);
/**
* Class holding the timing information for the request/reply,
* and the message sequence Id.
*/
class RequestReport {
public:
RequestReport(): transactionId(0),
connectDuration(0), sendRecvDuration(0) {}
uint32_t transactionId;
double connectDuration;
double sendRecvDuration;
};
/**
* Class holding the result of a Volume request
*/
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment