irods  4.2.8
About: iRODS (the integrated Rule Oriented Data System) is a distributed data-management system for creating data grids, digital libraries, persistent archives, and real-time data systems.
  Fossies Dox: irods-4.2.8.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

objDesc.hpp
Go to the documentation of this file.
1 
4 /* objDesc.h - header file for objDesc.c
5  */
6 
7 
8 
9 #ifndef OBJ_DESC_HPP
10 #define OBJ_DESC_HPP
11 
12 #include "rods.h"
13 #include "objInfo.h"
14 #include "dataObjInpOut.h"
15 #include "fileRename.h"
16 #include "miscUtil.h"
17 #include "structFileSync.h"
18 #include "structFileExtAndReg.h"
19 #include "dataObjOpenAndStat.h"
20 #include "rodsConnect.h"
21 
22 #include "boost/any.hpp"
23 
24 #define NUM_L1_DESC 1026 /* number of L1Desc */
25 
26 #define CHK_ORPHAN_CNT_LIMIT 20 /* number of failed check before stopping */
27 /* definition for getNumThreads */
28 
29 #define REG_CHKSUM 1
30 #define VERIFY_CHKSUM 2
31 
32 /* values in l1desc_t is the desired value. values in dataObjInfo are
33  * the values in rcat */
34 typedef struct l1desc {
35  int l3descInx;
36  int inuseFlag;
37  int oprType;
38  int openType;
39  int oprStatus;
45  rodsLong_t bytesWritten; /* mark whether it has been written */
46  rodsLong_t dataSize; /* this is the target size. The size in
47  * dataObjInfo is the registered size */
48  int replStatus; /* the replica status */
49  int chksumFlag; /* parsed from condition */
51  char chksum[NAME_LEN]; /* the input chksum */
53  int stageFlag;
54  int purgeCacheFlag; // JMC - backport 4537
55  int lockFd; // JMC - backport 4604
56  boost::any pluginData;
57  dataObjInfo_t *replDataObjInfo; /* if non NULL, repl to this dataObjInfo
58  * on close */
62 
63 extern "C" {
64 
65 int
67 
68 int
70 
71 int
72 freeL1Desc( int fileInx );
73 
74 int
75 fillL1desc( int l1descInx, dataObjInp_t *dataObjInp,
76  dataObjInfo_t *dataObjInfo, int replStatus, rodsLong_t dataSize );
77 int
78 getL1descIndexByDataObjInfo( const dataObjInfo_t * dataObjInfo );
79 int
80 getNumThreads( rsComm_t *rsComm, rodsLong_t dataSize, int inpNumThr,
81  keyValPair_t *condInput, char *destRescName, char *srcRescName, int oprType );
82 int
83 initDataOprInp( dataOprInp_t *dataOprInp, int l1descInx, int oprType );
84 int
85 initDataObjInfoForRepl( dataObjInfo_t *destDataObjInfo,
86  dataObjInfo_t *srcDataObjInfo, const char *_resc_name );
87 int
88 convL3descInx( int l3descInx );
89 int
90 initDataObjInfoWithInp( dataObjInfo_t *dataObjInfo, dataObjInp_t *dataObjInp );
91 int
92 allocL1desc();
93 int
94 freeL1desc( int l1descInx );
95 int
96 closeAllL1desc( rsComm_t *rsComm );
97 int
99 int
101 int
102 freeSpecCollDesc( int specCollInx );
103 int
104 initL1desc();
105 int
107 int
108 freeCollHandle( int handleInx );
109 int
110 rsInitQueryHandle( queryHandle_t *queryHandle, rsComm_t *rsComm );
111 int
112 allocAndSetL1descForZoneOpr( int l3descInx, dataObjInp_t *dataObjInp,
113  rodsServerHost_t *remoteZoneHost, openStat_t *openStat );
114 int
115 isL1descInuse();
116 
117 }
118 
119 #endif /* OBJ_DESC_H */
QueryHandle
Definition: miscUtil.h:81
allocL1desc
int allocL1desc()
Definition: objDesc.cpp:39
allocCollHandle
int allocCollHandle()
Definition: objDesc.cpp:585
l1desc::copiesNeeded
int copiesNeeded
Definition: objDesc.hpp:44
rsComm_t
Definition: rcConnect.h:145
l1desc::remoteZoneHost
rodsServerHost_t * remoteZoneHost
Definition: objDesc.hpp:59
l1desc::replDataObjInfo
dataObjInfo_t * replDataObjInfo
Definition: objDesc.hpp:57
structFileSync.h
freeL1Desc
int freeL1Desc(int fileInx)
rsInitQueryHandle
int rsInitQueryHandle(queryHandle_t *queryHandle, rsComm_t *rsComm)
Definition: objDesc.cpp:623
l1desc::lockFd
int lockFd
Definition: objDesc.hpp:55
l1desc::dataSize
rodsLong_t dataSize
Definition: objDesc.hpp:46
allocAndSetL1descForZoneOpr
int allocAndSetL1descForZoneOpr(int l3descInx, dataObjInp_t *dataObjInp, rodsServerHost_t *remoteZoneHost, openStat_t *openStat)
Definition: objDesc.cpp:638
l1desc::oprStatus
int oprStatus
Definition: objDesc.hpp:39
l1desc::remoteL1descInx
int remoteL1descInx
Definition: objDesc.hpp:52
l1desc::dataObjInfo
dataObjInfo_t * dataObjInfo
Definition: objDesc.hpp:42
l1desc::oprType
int oprType
Definition: objDesc.hpp:37
fillL1desc
int fillL1desc(int l1descInx, dataObjInp_t *dataObjInp, dataObjInfo_t *dataObjInfo, int replStatus, rodsLong_t dataSize)
Definition: objDesc.cpp:154
initL1desc
int initL1desc()
Definition: objDesc.cpp:33
l1desc::l3descInx
int l3descInx
Definition: objDesc.hpp:35
l1desc::in_pdmo
char in_pdmo[(1024+64)]
Definition: objDesc.hpp:60
l1desc::chksumFlag
int chksumFlag
Definition: objDesc.hpp:49
rodsConnect.h
freeCollHandle
int freeCollHandle(int handleInx)
Definition: objDesc.cpp:608
l1desc::openType
int openType
Definition: objDesc.hpp:38
isL1descInuse
int isL1descInuse()
Definition: objDesc.cpp:56
l1desc::chksum
char chksum[64]
Definition: objDesc.hpp:51
dataObjInpOut.h
l1desc::inuseFlag
int inuseFlag
Definition: objDesc.hpp:36
freeSpecCollDesc
int freeSpecCollDesc(int specCollInx)
Definition: objDesc.cpp:91
getNumThreads
int getNumThreads(rsComm_t *rsComm, rodsLong_t dataSize, int inpNumThr, keyValPair_t *condInput, char *destRescName, char *srcRescName, int oprType)
Definition: objDesc.cpp:279
l1desc::stageFlag
int stageFlag
Definition: objDesc.hpp:53
l1desc::dataObjInpReplFlag
int dataObjInpReplFlag
Definition: objDesc.hpp:40
initL1Desc
int initL1Desc()
DataObjInp
Definition: dataObjInpOut.h:65
l1desc::dataObjInp
dataObjInp_t * dataObjInp
Definition: objDesc.hpp:41
MAX_NAME_LEN
#define MAX_NAME_LEN
Definition: rodsDef.h:61
convL3descInx
int convL3descInx(int l3descInx)
Definition: objDesc.cpp:571
l1desc::srcL1descInx
int srcL1descInx
Definition: objDesc.hpp:50
OpenStat
Definition: dataObjOpenAndStat.h:8
initDataOprInp
int initDataOprInp(dataOprInp_t *dataOprInp, int l1descInx, int oprType)
Definition: objDesc.cpp:453
dataObjOpenAndStat.h
objInfo.h
rodsServerHost
Definition: rodsConnect.h:62
l1desc::bytesWritten
rodsLong_t bytesWritten
Definition: objDesc.hpp:45
l1desc::otherDataObjInfo
dataObjInfo_t * otherDataObjInfo
Definition: objDesc.hpp:43
fileRename.h
DataOprInp
Definition: dataObjInpOut.h:122
allocL1Desc
int allocL1Desc()
getL1descIndexByDataObjInfo
int getL1descIndexByDataObjInfo(const dataObjInfo_t *dataObjInfo)
Definition: objDesc.cpp:262
l1desc::replStatus
int replStatus
Definition: objDesc.hpp:48
l1desc
Definition: objDesc.hpp:34
initDataObjInfoForRepl
int initDataObjInfoForRepl(dataObjInfo_t *destDataObjInfo, dataObjInfo_t *srcDataObjInfo, const char *_resc_name)
Definition: objDesc.cpp:544
miscUtil.h
NAME_LEN
#define NAME_LEN
Definition: rodsDef.h:55
freeL1desc
int freeL1desc(int l1descInx)
Definition: objDesc.cpp:124
KeyValPair
Definition: objInfo.h:120
initDataObjInfoWithInp
int initDataObjInfoWithInp(dataObjInfo_t *dataObjInfo, dataObjInp_t *dataObjInp)
Definition: objDesc.cpp:217
initSpecCollDesc
int initSpecCollDesc()
Definition: objDesc.cpp:68
DataObjInfo
Definition: objInfo.h:129
l1desc::pluginData
boost::any pluginData
Definition: objDesc.hpp:56
structFileExtAndReg.h
allocSpecCollDesc
int allocSpecCollDesc()
Definition: objDesc.cpp:74
rods.h
closeAllL1desc
int closeAllL1desc(rsComm_t *rsComm)
Definition: objDesc.cpp:108
rodsLong_t
long long rodsLong_t
Definition: rodsType.h:32
l1desc_t
struct l1desc l1desc_t
l1desc::purgeCacheFlag
int purgeCacheFlag
Definition: objDesc.hpp:54