Loading...
Searching...
No Matches
XrdBwm Class Reference

`#include <XrdBwm.hh>`

Inheritance diagram for XrdBwm:
Collaboration diagram for XrdBwm:

## Public Member Functions

| XrdBwm ()
virtual | ~XrdBwm ()
int | chmod (const char *Name, XrdSfsMode Mode, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *opaque=0)
virtual int | Configure (XrdSysError &)
int | exists (const char *fileName, XrdSfsFileExistence &exists_flag, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *opaque=0)
int | fsctl (const int cmd, const char *args, XrdOucErrInfo &out_error, const XrdSecEntity *client)
int | getStats (char *buff, int blen)
const char * | getVersion ()
int | mkdir (const char *dirName, XrdSfsMode Mode, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *opaque=0)
XrdSfsDirectory * | newDir (char *user=0, int monid=0)
XrdSfsFile * | newFile (char *user=0, int monid=0)
int | prepare (XrdSfsPrep &pargs, XrdOucErrInfo &out_error, const XrdSecEntity *client=0)
int | rem (const char *path, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *info=0)
int | remdir (const char *dirName, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *info=0)
int | rename (const char *oldFileName, const char *newFileName, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *infoO=0, const char *infoN=0)
int | stat (const char *Name, mode_t &mode, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *opaque=0)
int | stat (const char *Name, struct stat *buf, XrdOucErrInfo &out_error, const XrdSecEntity *client, const char *opaque=0)
int | truncate (const char *Name, XrdSfsFileOffset fileOffset, XrdOucErrInfo &out_error, const XrdSecEntity *client=0, const char *opaque=0)
Public Member Functions inherited from XrdSfsFileSystem
| XrdSfsFileSystem ()
| Constructor and Destructor.
virtual | ~XrdSfsFileSystem ()
virtual int | chksum (csFunc Func, const char *csName, const char *path, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)
virtual void | Connect (const XrdSecEntity *client=0)
virtual void | Disc (const XrdSecEntity *client=0)
virtual void | EnvInfo (XrdOucEnv *envP)
virtual int | FAttr (XrdSfsFACtl *faReq, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)
uint64_t | Features ()
virtual int | FSctl (const int cmd, XrdSfsFSctl &args, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)
virtual int | getChkPSize ()
virtual int | gpFile (gpfFunc &gpAct, XrdSfsGPFile &gpReq, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)
virtual XrdSfsDirectory * | newDir (XrdOucErrInfo &eInfo)
virtual XrdSfsFile * | newFile (XrdOucErrInfo &eInfo)

## Public Attributes

char | Authorize
char * | ConfigFN
char * | HostName
char * | HostPref
char * | myDomain
int | myDomLen
XrdVersionInfo * | myVersion
char | Reserved [7]

## Protected Member Functions

virtual int | ConfigXeq (char *var, XrdOucStream &, XrdSysError &)
int | Emsg (const char *, XrdOucErrInfo &, const char *, const char *, const char *y="")
int | Emsg (const char *, XrdOucErrInfo &, int, const char *, const char *y="")
int | Stall (XrdOucErrInfo &, int, const char *)

## Friends

class | XrdBwmDirectory
class | XrdBwmFile

## Additional Inherited Members

Public Types inherited from XrdSfsFileSystem
enum | csFunc { csCalc = 0 , csGet , csSize }
enum | gpfFunc { gpfCancel =0 , gpfGet , gpfPut }
Protected Attributes inherited from XrdSfsFileSystem
uint64_t | FeatureSet
| Adjust features at initialization.

## Detailed Description

Definition at line 149 of file XrdBwm.hh.

## Constructor & Destructor Documentation

## XrdBwm()

XrdBwm::XrdBwm | ( |  | ) |

Definition at line 89 of file XrdBwm.cc.

{
XrdNetAddr myAddr(0);
char buff[256], *bp;
int myPort, i;
// Establish defaults
//
Authorization = 0;
Authorize = 0;
AuthLib = 0;
AuthParm = 0;
Logger = 0;
PolLib = 0;
PolParm = 0;
PolSlotsIn = 1;
PolSlotsOut = 1;
// Obtain port number we will be using
//
myPort = (bp = getenv("XRDPORT")) ? strtol(bp, (char **)NULL, 10) : 0;
// Establish our hostname and address
//
myAddr.Port(myPort);
HostName = strdup(myAddr.Name("*unknown*"));
myAddr.Format(buff, sizeof(buff), XrdNetAddr::fmtAdv6, XrdNetAddr::old6Map4);
locResp = strdup(buff); locRlen = strlen(buff);
for (i = 0; HostName[i] && HostName[i] != '.'; i++) {}
HostName[i] = '\0';
HostPref = strdup(HostName);
HostName[i] = '.';
myDomain = &HostName[i+1];
myDomLen = strlen(myDomain);
myVersion = &XrdVERSIONINFOVAR(XrdSfsGetFileSystem);
// Set the configuration file name abd dummy handle
//
ConfigFN = 0;
dummyHandle = XrdBwmHandle::Alloc("*", "/", "?", "?", 0);
}
XrdSfsGetFileSystem
XrdSfsFileSystem * XrdSfsGetFileSystem(XrdSfsFileSystem *native_fs, XrdSysLogger *lp, const char *configfn)
Definition XrdBwm.cc:147
XrdBwmHandle::Alloc
static XrdBwmHandle * Alloc(const char *theUsr, const char *thePath, const char *lclNode, const char *rmtNode, int Incoming)
Definition XrdBwmHandle.cc:168
XrdBwm::myVersion
XrdVersionInfo * myVersion
Definition XrdBwm.hh:244
XrdBwm::myDomain
char * myDomain
Definition XrdBwm.hh:249
XrdBwm::myDomLen
int myDomLen
Definition XrdBwm.hh:250
XrdBwm::ConfigFN
char * ConfigFN
Definition XrdBwm.hh:246
XrdBwm::HostPref
char * HostPref
Definition XrdBwm.hh:248
XrdBwm::HostName
char * HostName
Definition XrdBwm.hh:247
XrdBwm::Authorize
char Authorize
Definition XrdBwm.hh:251
XrdNetAddrInfo::old6Map4
static const int old6Map4
Use deprecated IPV6 mapped format.
Definition XrdNetAddrInfo.hh:106
XrdNetAddrInfo::fmtAdv6
@ fmtAdv6
Definition XrdNetAddrInfo.hh:102

References XrdBwmHandle::Alloc(), Authorize, ConfigFN, XrdNetAddrInfo::fmtAdv6, XrdNetAddrInfo::Format(), HostName, HostPref, myDomain, myDomLen, myVersion, XrdNetAddrInfo::Name(), XrdNetAddrInfo::old6Map4, XrdNetAddr::Port(), and XrdSfsGetFileSystem().

Here is the call graph for this function:

## ~XrdBwm()

virtual XrdBwm::~XrdBwm | ( |  | ) |

inline virtual

Definition at line 238 of file XrdBwm.hh.

{} // Too complicate to delete :-)

## Member Function Documentation

## chmod()

int XrdBwm::chmod | ( | const char * | path,
|  | XrdSfsMode | mode,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

virtual

Change file mode settings.

Parameters

  path | - Pointer to the path of the file in question.
  mode | - The new file mode setting.
  eInfo | - The object where error info or results are to be returned.
  client | - Client's identify (see common description).
  opaque | - Path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 701 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("chmod", einfo, ENOTSUP, "change", path);
}
XrdBwmFS
XrdBwm XrdBwmFS
Definition XrdBwm.cc:83
XrdBwm::Emsg
int Emsg(const char *, XrdOucErrInfo &, int, const char *, const char *y="")
Definition XrdBwm.cc:961

References Mode, and XrdBwmFS.

## Configure()

int XrdBwm::Configure | ( | XrdSysError & | Eroute | ) |

virtual

Definition at line 77 of file XrdBwmConfig.cc.

{
/*
Function: Establish default values using a configuration file.
Input: None.
Output: 0 upon success or !0 otherwise.
*/
char *var;
int cfgFD, retc, NoGo = 0;
XrdOucEnv myEnv;
XrdOucStream Config(&Eroute, getenv("XRDINSTANCE"), &myEnv, "=====> ");
// Print warm-up message
//
Eroute.Say("++++++ Bwm initialization started.");
// Get the debug level from the command line
//
if (getenv("XRDDEBUG")) BwmTrace.What = TRACE_ALL;
// If there is no config file, return with the defaults sets.
//
if( !ConfigFN || !*ConfigFN)
Eroute.Emsg("Config", "Configuration file not specified.");
else {
// Try to open the configuration file.
//
if ( (cfgFD = open(ConfigFN, O_RDONLY, 0)) < 0)
return Eroute.Emsg("Config", errno, "open config file",
ConfigFN);
Config.Attach(cfgFD);
static const char *cvec[] = { "*** bwm ofs plugin config:", 0 };
Config.Capture(cvec);
// Now start reading records until eof.
//
while((var = Config.GetMyFirstWord()))
{if (!strncmp(var, "bwm.", 4))
if (ConfigXeq(var+4,Config,Eroute)) {Config.Echo();NoGo=1;}
}
// Now check if any errors occurred during file i/o
//
if ((retc = Config.LastError()))
NoGo = Eroute.Emsg("Config", -retc, "read config file",
ConfigFN);
Config.Close();
}
// Determine whether we should initialize authorization
//
if (Authorize) NoGo |= setupAuth(Eroute);
// Establish scheduling policy
//
if (PolLib) NoGo |= setupPolicy(Eroute);
else Policy = new XrdBwmPolicy1(PolSlotsIn, PolSlotsOut);
// Start logger object
//
if (!NoGo && Logger) NoGo = Logger->Start(&Eroute);
// Inform the handle of the policy and logger
//
if (!NoGo) XrdBwmHandle::setPolicy(Policy, Logger);
// All done
//
Eroute.Say("------ Bwm initialization ", (NoGo ? "failed." : "completed."));
return NoGo;
}
BwmTrace
XrdOucTrace BwmTrace
open
#define open
Definition XrdPosix.hh:76
TRACE_ALL
#define TRACE_ALL
Definition XrdTrace.hh:35
XrdBwmHandle::setPolicy
static int setPolicy(XrdBwmPolicy *pP, XrdBwmLogger *lP)
Definition XrdBwmHandle.cc:377
XrdBwm::ConfigXeq
virtual int ConfigXeq(char *var, XrdOucStream &, XrdSysError &)
Definition XrdBwmConfig.cc:157
XrdOucTrace::What
int What
Definition XrdOucTrace.hh:46
XrdSysError::Emsg
int Emsg(const char *esfx, int ecode, const char *text1, const char *text2=0)
Definition XrdSysError.cc:95
XrdSysError::Say
void Say(const char *text1, const char *text2=0, const char *txt3=0, const char *text4=0, const char *text5=0, const char *txt6=0)
Definition XrdSysError.cc:141
XrdCms::Config
XrdCmsConfig Config
Definition XrdCmsConfig.cc:108

References Authorize, BwmTrace, ConfigFN, ConfigXeq(), XrdSysError::Emsg(), open, XrdSysError::Say(), XrdBwmHandle::setPolicy(), and TRACE_ALL.

Here is the call graph for this function:

## ConfigXeq()

int XrdBwm::ConfigXeq | ( | char * | var,
|  | XrdOucStream & | Config,
|  | XrdSysError & | Eroute )

protected virtual

Definition at line 157 of file XrdBwmConfig.cc.

{
TS_Bit("authorize", Authorize, 1);
TS_Xeq("authlib", xalib);
TS_Xeq("log", xlog);
TS_Xeq("policy", xpol);
TS_Xeq("trace", xtrace);
// No match found, complain.
//
Eroute.Say("Config warning: ignoring unknown directive '",var,"'.");
Config.Echo();
return 0;
}
TS_Bit
#define TS_Bit(x, m, v)
Definition XrdAccConfig.cc:73
TS_Xeq
#define TS_Xeq(x, m)
Definition XrdConfig.cc:160

References Authorize, XrdSysError::Say(), TS_Bit, and TS_Xeq.

Referenced by Configure().

Here is the call graph for this function:
Here is the caller graph for this function:

## Emsg() [1/2]

int XrdBwm::Emsg | ( | const char * | pfx,
|  | XrdOucErrInfo & | einfo,
|  | const char * | item,
|  | const char * | op,
|  | const char * | y = "" )

protected

Definition at line 993 of file XrdBwm.cc.

{
char buffer[MAXPATHLEN+80];
// Format the error message
//
snprintf(buffer,sizeof(buffer),"Unable to %s %s; %s missing",
op, target, item);
// Print it out if debugging is enabled
//
#ifndef NODEBUG
BwmEroute.Emsg(pfx, einfo.getErrUser(), buffer);
#endif
// Place the error message in the error object and return
//
einfo.setErrInfo(EINVAL, buffer);
return SFS_ERROR;
}
BwmEroute
XrdSysError BwmEroute(0)
Definition XrdBwm.cc:69
SFS_ERROR
#define SFS_ERROR
Definition XrdSfsInterface.hh:109
XrdOucErrInfo::getErrUser
const char * getErrUser()
Definition XrdOucErrInfo.hh:297
XrdOucErrInfo::setErrInfo
int setErrInfo(int code, const char *emsg)
Definition XrdOucErrInfo.hh:147

References BwmEroute, XrdOucErrInfo::getErrUser(), XrdOucErrInfo::setErrInfo(), and SFS_ERROR.

Here is the call graph for this function:

## Emsg() [2/2]

int XrdBwm::Emsg | ( | const char * | pfx,
|  | XrdOucErrInfo & | einfo,
|  | int | ecode,
|  | const char * | op,
|  | const char * | y = "" )

protected

Definition at line 961 of file XrdBwm.cc.

{
const char *etext;
char buffer[MAXPATHLEN+80];
// Get the reason for the error
//
if (ecode < 0) ecode = -ecode;
etext = BwmEroute.ec2text(ecode);
// Format the error message
//
snprintf(buffer,sizeof(buffer),"Unable to %s %s; %s", op, target, etext);
// Print it out if debugging is enabled
//
#ifndef NODEBUG
BwmEroute.Emsg(pfx, einfo.getErrUser(), buffer);
#endif
// Place the error message in the error object and return
//
einfo.setErrInfo(ecode, buffer);
return SFS_ERROR;
}
XrdSysError::ec2text
static const char * ec2text(int ecode)
Definition XrdSysError.cc:79

References BwmEroute, XrdOucErrInfo::getErrUser(), XrdOucErrInfo::setErrInfo(), and SFS_ERROR.

Here is the call graph for this function:

## exists()

int XrdBwm::exists | ( | const char * | path,
|  | XrdSfsFileExistence & | eFlag,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

virtual

Return directory/file existence information (short stat).

Parameters

  path | - Pointer to the path of the file/directory in question.
  eFlag | - Where the results are to be returned.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - Path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, SFS_STALL, or SFS_STARTED When SFS_OK is returned, eFlag must be properly set, as follows: XrdSfsFileExistNo - path does not exist XrdSfsFileExistIsFile - path refers to an online file XrdSfsFileExistIsDirectory - path refers to an online directory XrdSfsFileExistIsOffline - path refers to an offline file XrdSfsFileExistIsOther - path is neither a file nor directory

Implements XrdSfsFileSystem.

Definition at line 726 of file XrdBwm.cc.

{
file_exists=XrdSfsFileExistNo;
return SFS_OK;
}
XrdSfsFileExistNo
@ XrdSfsFileExistNo
Definition XrdSfsInterface.hh:135
SFS_OK
#define SFS_OK
Definition XrdSfsInterface.hh:108

References SFS_OK, and XrdSfsFileExistNo.

## fsctl()

int XrdBwm::fsctl | ( | const int | cmd,
|  | const char * | args,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client )

virtual

Perform a filesystem control operation (version 1)

Parameters

  cmd | - The operation to be performed: SFS_FSCTL_LOCATE Locate a file or file servers SFS_FSCTL_STATCC Return cluster config status SFS_FSCTL_STATFS Return physical filesystem information SFS_FSCTL_STATLS Return logical filesystem information SFS_FSCTL_STATXA Return extended attributes
  args | - Arguments specific to cmd. SFS_FSCTL_LOCATE args points to the path to be located "" path is the first exported path "*" return all current servers "*&zwj;/" return servers exporting path o/w return servers having the path SFS_FSCTL_STATFS Path in the filesystem in question. SFS_FSCTL_STATLS Path in the filesystem in question. SFS_FSCTL_STATXA Path of the file whose xattr is wanted.
  eInfo | - The object where error info or results are to be returned.
  client | - Client's identify (see common description).

Returns
  SFS_OK a null response is sent.
  SFS_DATA error.code length of the data to be sent. error.message contains the data to be sent.
  SFS_STARTED Operation started result will be returned via callback. Valid only for for SFS_FSCTL_LOCATE, SFS_FSCTL_STATFS, and SFS_FSCTL_STATXA o/w one of SFS_ERROR, SFS_REDIRECT, or SFS_STALL.

Implements XrdSfsFileSystem.

Definition at line 758 of file XrdBwm.cc.

{
// Operation is not supported
//
return XrdBwmFS.Emsg("fsctl", einfo, ENOTSUP, "fsctl", args);
}

References XrdBwmFS.

## getStats()

int XrdBwm::getStats | ( | char * | buff,
|  | int | blen )

inline virtual

Return statistical information.

Parameters

  buff | - Pointer to the buffer where results are to be returned. Statistics should be in standard XML format. If buff is nil then only maximum size information is wanted.
  blen | - The length available in buff.

Returns
  Number of bytes placed in buff. When buff is nil, the maximum number of bytes that could have been placed in buff.

Implements XrdSfsFileSystem.

Definition at line 183 of file XrdBwm.hh.

{return 0;}

## getVersion()

const char * XrdBwm::getVersion | ( |  | ) |

virtual

Get version string.

Returns
  The version string. Normally this is the XrdVERSION value.

Implements XrdSfsFileSystem.

Definition at line 784 of file XrdBwm.cc.

{return XrdVERSION;}

## mkdir()

int XrdBwm::mkdir | ( | const char * | path,
|  | XrdSfsMode | mode,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

virtual

Create a directory.

Parameters

  path | - Pointer to the path of the directory to be created.
  mode | - The directory mode setting.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - Path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 790 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("mkdir", einfo, ENOTSUP, "mkdir", path);
}

References Mode, and XrdBwmFS.

## newDir()

XrdSfsDirectory * XrdBwm::newDir | ( | char * | user = 0,
|  | int | MonID = 0 )

inline virtual

Obtain a new director object to be used for future directory requests.

Parameters

  user | - Text identifying the client responsible for this call. The pointer may be null if identification is missing.
  MonID | - The monitoring identifier assigned to this and all future requests using the returned object.

Returns
  pointer- Pointer to an XrdSfsDirectory object.
  nil - Insufficient memory to allocate an object.

Implements XrdSfsFileSystem.

Definition at line 158 of file XrdBwm.hh.

{return (XrdSfsDirectory *)new XrdBwmDirectory(user,monid);}
XrdBwm::XrdBwmDirectory
friend class XrdBwmDirectory
Definition XrdBwm.hh:151

References XrdBwmDirectory.

Here is the call graph for this function:

## newFile()

XrdSfsFile * XrdBwm::newFile | ( | char * | user = 0,
|  | int | MonID = 0 )

inline virtual

Obtain a new file object to be used for a future file requests.

Parameters

  user | - Text identifying the client responsible for this call. The pointer may be null if identification is missing.
  MonID | - The monitoring identifier assigned to this and all future requests using the returned object.

Returns
  pointer- Pointer to an XrdSfsFile object.
  nil - Insufficient memory to allocate an object.

Implements XrdSfsFileSystem.

Definition at line 161 of file XrdBwm.hh.

{return (XrdSfsFile *)new XrdBwmFile(user,monid);}
XrdBwm::XrdBwmFile
friend class XrdBwmFile
Definition XrdBwm.hh:152

References XrdBwmFile.

Here is the call graph for this function:

## prepare()

int XrdBwm::prepare | ( | XrdSfsPrep & | pargs,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client = 0 )

virtual

Prepare a file for future processing.

Parameters

  pargs | - The preapre arguments.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 818 of file XrdBwm.cc.

{
return 0;
}

## rem()

int XrdBwm::rem | ( | const char * | path,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

inline virtual

Remove a file.

Parameters

  path | - Pointer to the path of the file to be removed.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - Path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 197 of file XrdBwm.hh.

{return remove('f', path, out_error, client, info);}

## remdir()

int XrdBwm::remdir | ( | const char * | path,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

inline virtual

Remove a directory.

Parameters

  path | - Pointer to the path of the directory to be removed.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - Path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 203 of file XrdBwm.hh.

{return remove('d',dirName,out_error,client,info);}

## rename()

int XrdBwm::rename | ( | const char * | oPath,
|  | const char * | nPath,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaqueO = 0,
|  | const char * | opaqueN = 0 )

virtual

Rename a file or directory.

Parameters

  oPath | - Pointer to the path to be renamed.
  nPath | - Pointer to the path oPath is to have.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaqueO | - oPath's CGI information (see common description).
  opaqueN | - nPath's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 855 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("rename", einfo, ENOTSUP, "rename", old_name);
}

References XrdBwmFS.

## Stall()

int XrdBwm::Stall | ( | XrdOucErrInfo & | einfo,
|  | int | stime,
|  | const char * | path )

protected

Definition at line 1022 of file XrdBwm.cc.

{
EPNAME("Stall")
#ifndef NODEBUG
const char *tident = einfo.getErrUser();
#endif
// Trace the stall
//
ZTRACE(delay, "Stall " <<stime <<" for " <<path);
// Place the error message in the error object and return
//
einfo.setErrInfo(0, "");
return stime;
}
tident
#define tident
Definition XrdBwmHandle.cc:109
EPNAME
#define EPNAME(x)
Definition XrdBwmTrace.hh:56
ZTRACE
#define ZTRACE(act, x)
Definition XrdBwmTrace.hh:52

References EPNAME, XrdOucErrInfo::getErrUser(), XrdOucErrInfo::setErrInfo(), tident, and ZTRACE.

Here is the call graph for this function:

## stat() [1/2]

int XrdBwm::stat | ( | const char * | path,
|  | mode_t & | mode,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

virtual

Return mode information on a file or directory.

Parameters

  path | - Pointer to the path in question.
  mode | - Where full mode information is to be returned.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, SFS_STALL, or SFS_STARTED When SFS_OK is returned, mode must contain mode information. If the mode is -1 then it is taken as an offline file.

Implements XrdSfsFileSystem.

Definition at line 907 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("stat", einfo, ENOTSUP, "locate", path);
}

References XrdBwmFS.

## stat() [2/2]

int XrdBwm::stat | ( | const char * | Name,
|  | struct stat * | buf,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client,
|  | const char * | opaque = 0 )

virtual

Return state information on a file or directory.

Parameters

  Name | - Pointer to the path in question.
  buf | - Pointer to the structure where info it to be returned.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, SFS_STALL, or SFS_STARTED When SFS_OK is returned, buf must contain stat information.

Implements XrdSfsFileSystem.

Definition at line 883 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("stat", einfo, ENOTSUP, "locate", path);
}

References stat(), and XrdBwmFS.

Referenced by stat().

Here is the call graph for this function:
Here is the caller graph for this function:

## truncate()

int XrdBwm::truncate | ( | const char * | path,
|  | XrdSfsFileOffset | fsize,
|  | XrdOucErrInfo & | eInfo,
|  | const XrdSecEntity * | client = 0,
|  | const char * | opaque = 0 )

virtual

Truncate a file.

Parameters

  path | - Pointer to the path of the file to be truncated.
  fsize | - The size that the file is to have.
  eInfo | - The object where error info is to be returned.
  client | - Client's identify (see common description).
  opaque | - path's CGI information (see common description).

Returns
  One of SFS_OK, SFS_ERROR, SFS_REDIRECT, or SFS_STALL

Implements XrdSfsFileSystem.

Definition at line 935 of file XrdBwm.cc.

{
// Return an error
//
return XrdBwmFS.Emsg("truncate", einfo, ENOTSUP, "truncate", path);
}

References XrdBwmFS.

## Friends And Related Symbol Documentation

## XrdBwmDirectory

friend class XrdBwmDirectory

friend

Definition at line 151 of file XrdBwm.hh.

References XrdBwmDirectory.

Referenced by newDir(), and XrdBwmDirectory.

## XrdBwmFile

friend class XrdBwmFile

friend

Definition at line 152 of file XrdBwm.hh.

References XrdBwmFile.

Referenced by newFile(), and XrdBwmFile.

## Member Data Documentation

## Authorize

char XrdBwm::Authorize

Definition at line 251 of file XrdBwm.hh.

Referenced by XrdBwm(), Configure(), and ConfigXeq().

## ConfigFN

char* XrdBwm::ConfigFN

Definition at line 246 of file XrdBwm.hh.

Referenced by XrdBwm(), and Configure().

## HostName

char* XrdBwm::HostName

Definition at line 247 of file XrdBwm.hh.

Referenced by XrdBwm().

## HostPref

char* XrdBwm::HostPref

Definition at line 248 of file XrdBwm.hh.

Referenced by XrdBwm().

## myDomain

char* XrdBwm::myDomain

Definition at line 249 of file XrdBwm.hh.

Referenced by XrdBwm().

## myDomLen

int XrdBwm::myDomLen

Definition at line 250 of file XrdBwm.hh.

Referenced by XrdBwm().

## myVersion

XrdVersionInfo* XrdBwm::myVersion

Definition at line 244 of file XrdBwm.hh.

Referenced by XrdBwm().

## Reserved

char XrdBwm::Reserved[7]

Definition at line 252 of file XrdBwm.hh.

The documentation for this class was generated from the following files:

- XrdBwm.hh
- XrdBwm.cc
- XrdBwmConfig.cc