85 lines
1.9 KiB
C++
85 lines
1.9 KiB
C++
/***************************************************************************
|
|
Replication 관련 Data 객체 정의
|
|
-----------------------------------------
|
|
begin : 2010/03/09
|
|
copyright : (C) 2005 Solbox Inc.
|
|
author : Storage Dev Team
|
|
email : storage.sd@solbox.com
|
|
version : 3.3
|
|
|
|
CopyRight(C) 2005 Solbox Inc. All Rights reserved.
|
|
Redistribution and use in source and binary forms, with or with out
|
|
modification, are not permitted in outside of Solbox Inc.
|
|
***************************************************************************/
|
|
|
|
#ifndef __REPLICATION_DATA_H__
|
|
#define __REPLICATION_DATA_H__
|
|
|
|
#include <list>
|
|
#include <string>
|
|
#include <time.h>
|
|
|
|
// CSourceData class
|
|
class CSourceData
|
|
{
|
|
public :
|
|
// RCDB 의 URI 정보
|
|
std::string m_szURI;
|
|
// RCDB의 filename_hash 정보
|
|
std::string m_szFileNameHash;
|
|
// RCDB의 hostname 정보
|
|
std::string m_szOriginHostName;
|
|
|
|
// NEW 2014-06-16
|
|
// 서비스별 RCDB table 분리 (RCDB 신규 형상)에 따라...
|
|
// Query 처리가 간편하도록 서비스 정보 필드 추가 (RCDB sp_svc_tran_id, CCDB svc_seq )
|
|
std::string m_szServiceSeq;
|
|
|
|
// 파일의 크기. RCDB의 get_content_length
|
|
unsigned long long m_nContentLength;
|
|
|
|
// Replication 해야할 갯수
|
|
int m_nReplicationCount;
|
|
|
|
};
|
|
|
|
|
|
// CRetryData class
|
|
class CRetryData
|
|
{
|
|
public :
|
|
// 실패 개수
|
|
unsigned int m_uFailCount;
|
|
|
|
// 실패 시각(default=now)
|
|
time_t m_timeFailed;
|
|
|
|
// 성공한 FHS 정보
|
|
std::list<std::string> m_listSuccessHost;
|
|
|
|
// 작업 시도 대상(source 정보)
|
|
CSourceData m_OriginData;
|
|
|
|
// 생성자. 현재 시각으로 time설정
|
|
inline CRetryData() { time(&m_timeFailed); }
|
|
|
|
};
|
|
|
|
|
|
// CCompleteData class
|
|
class CCompleteData
|
|
{
|
|
public :
|
|
// content 가 생성된 장비 host name
|
|
std::string m_szTargetHostName;
|
|
|
|
// 생성된 content 의 filename_hash 정보
|
|
std::string m_szTargetFileNameHash;
|
|
|
|
// 원본 정보
|
|
CSourceData m_OriginData;
|
|
};
|
|
|
|
|
|
#endif // __REPLICATION_DATA_H__
|