xrootd
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Types | Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
XrdSsiTaskReal Class Reference

#include <XrdSsiTaskReal.hh>

Inheritance diagram for XrdSsiTaskReal:
Inheritance graph
[legend]
Collaboration diagram for XrdSsiTaskReal:
Collaboration graph
[legend]

Classes

struct  dlQ
 

Public Types

enum  TaskStat {
  isPend =0, isWrite, isSync, isReady,
  isDone, isDead
}
 
enum  respType { isBad =0, isAlert, isData, isStream }
 
- Public Types inherited from XrdSsiStream
enum  StreamType { isActive = 0, isPassive }
 

Public Member Functions

void Detach (bool force=false)
 
void Finished (XrdSsiRequest &rqstR, const XrdSsiRespInfo &rInfo, bool cancel=false)
 
void * Implementation ()
 
bool Kill ()
 
int ID ()
 
void Init (XrdSsiRequest *rP, unsigned short tmo=0)
 
void PostError ()
 
const char * RequestID ()
 
void SchedError (XrdSsiErrInfo *eInfo=0)
 
void SendError ()
 
bool SendRequest (const char *node)
 
int SetBuff (XrdSsiErrInfo &eRef, char *buff, int blen, bool &last)
 
bool SetBuff (XrdSsiErrInfo &eRef, char *buff, int blen)
 
void SetTaskID (uint32_t tid, uint32_t sid)
 
int XeqEvent (XrdCl::XRootDStatus *status, XrdCl::AnyObject **respP)
 
void XeqEvFin ()
 
 XrdSsiTaskReal (XrdSsiSessReal *sP)
 
 ~XrdSsiTaskReal ()
 
- Public Member Functions inherited from XrdSsiEvent
void AddEvent (XrdCl::XRootDStatus *st, XrdCl::AnyObject *resp)
 
void ClrEvent ()
 
virtual void DoIt ()
 
virtual void HandleResponse (XrdCl::XRootDStatus *status, XrdCl::AnyObject *response)
 
 XrdSsiEvent ()
 
 ~XrdSsiEvent ()
 
- Public Member Functions inherited from XrdJob
 XrdJob (const char *desc="")
 
virtual ~XrdJob ()
 
- Public Member Functions inherited from XrdCl::ResponseHandler
virtual ~ResponseHandler ()
 
virtual void HandleResponseWithHosts (XRootDStatus *status, AnyObject *response, HostList *hostList)
 
- Public Member Functions inherited from XrdSsiResponder
void BindRequest (XrdSsiRequest &rqstR)
 
bool UnBindRequest ()
 
- Public Member Functions inherited from XrdSsiStream
virtual BufferGetBuff (XrdSsiErrInfo &eRef, int &dlen, bool &last)
 
StreamType Type ()
 
 XrdSsiStream (StreamType stype)
 
virtual ~XrdSsiStream ()
 

Public Attributes

dlQ attList
 
- Public Attributes inherited from XrdJob
XrdJobNextJob
 
const char * Comment
 

Private Member Functions

bool Ask4Resp ()
 
respType GetResp (XrdCl::AnyObject **respP, char *&dbuf, int &dlen)
 
bool RespErr (XrdCl::XRootDStatus *status)
 

Private Attributes

XrdSsiErrInfo errInfo
 
XrdSsiSessRealsessP
 
XrdSsiRequestrqstP
 
XrdCl::AnyObjectmdResp
 
XrdSysSemaphorewPost
 
char * dataBuff
 
int dataRlen
 
TaskStat tStat
 
uint32_t tskID
 
int defer
 
unsigned short tmOut
 
bool mhPend
 

Additional Inherited Members

- Static Public Member Functions inherited from XrdCl::ResponseHandler
static ResponseHandlerWrap (std::function< void(XRootDStatus &, AnyObject &)> func)
 
static ResponseHandlerWrap (std::function< void(XRootDStatus *, AnyObject *)> func)
 
- Static Public Attributes inherited from XrdSsiResponder
static const int MaxDirectXfr = 2097152
 
- Protected Types inherited from XrdSsiResponder
enum  Status { wasPosted =0, notPosted, notActive }
 
- Protected Member Functions inherited from XrdSsiResponder
void Alert (XrdSsiRespInfoMsg &aMsg)
 
char * GetRequest (int &dlen)
 
void ReleaseRequestBuffer ()
 
Status SetMetadata (const char *buff, int blen)
 
Status SetErrResponse (const char *eMsg, int eNum)
 
Status SetNilResponse ()
 
Status SetResponse (const char *buff, int blen)
 
Status SetResponse (long long fsize, int fdnum)
 
Status SetResponse (XrdSsiStream *strmP)
 
 XrdSsiResponder ()
 
virtual ~XrdSsiResponder ()
 
- Protected Attributes inherited from XrdSsiEvent
char tident [24]
 
- Protected Attributes inherited from XrdSsiStream
const StreamType SType
 
- Static Protected Attributes inherited from XrdSsiResponder
static const int MaxMetaDataSZ = 2097152
 2MB metadata limit More...
 

Member Enumeration Documentation

Enumerator
isBad 
isAlert 
isData 
isStream 
Enumerator
isPend 
isWrite 
isSync 
isReady 
isDone 
isDead 

Constructor & Destructor Documentation

XrdSsiTaskReal::XrdSsiTaskReal ( XrdSsiSessReal sP)
inline
XrdSsiTaskReal::~XrdSsiTaskReal ( )
inline

References mdResp.

Member Function Documentation

bool XrdSsiTaskReal::Ask4Resp ( )
private
void XrdSsiTaskReal::Detach ( bool  force = false)
void XrdSsiTaskReal::Finished ( XrdSsiRequest rqstR,
const XrdSsiRespInfo rInfo,
bool  cancel = false 
)
virtual

Notify the responder that a request either completed or was canceled. This allows the responder to release any resources given to the request object (e.g. data response buffer or a stream). This method is invoked when XrdSsiRequest::Finished() is called by the client.

Parameters
rqstPreference to the object describing the request.
rInforeference to the object describing the response.
cancelFalse -> the request/response interaction completed. True -> the request/response interaction aborted because of an error or the client requested that the request be canceled.

Implements XrdSsiResponder.

respType XrdSsiTaskReal::GetResp ( XrdCl::AnyObject **  respP,
char *&  dbuf,
int &  dlen 
)
private
int XrdSsiTaskReal::ID ( )
inline

References tskID.

void* XrdSsiTaskReal::Implementation ( )
inline
void XrdSsiTaskReal::Init ( XrdSsiRequest rP,
unsigned short  tmo = 0 
)
inline
bool XrdSsiTaskReal::Kill ( )
void XrdSsiTaskReal::PostError ( )
const char* XrdSsiTaskReal::RequestID ( )
inline
bool XrdSsiTaskReal::RespErr ( XrdCl::XRootDStatus status)
private
void XrdSsiTaskReal::SchedError ( XrdSsiErrInfo eInfo = 0)
void XrdSsiTaskReal::SendError ( )
bool XrdSsiTaskReal::SendRequest ( const char *  node)
int XrdSsiTaskReal::SetBuff ( XrdSsiErrInfo eRef,
char *  buff,
int  blen,
bool &  last 
)
virtual

Synchronously obtain data from a passive stream (client- or server-side).

Parameters
eRefThe object to receive any error description.
buffpointer to the buffer to receive the data. request object is notified that the operation completed.
blenthe length of the buffer (i.e. maximum that can be returned).
lastinput: should be set to false. output: if true it indicates that no more data remains to be returned either for this call or on the next call.
Returns
>0 The number of bytes placed in buff.
=0 No more data remains and the stream becomes invalid.
<0 Fatal error occurred; eRef holds the reason.

Reimplemented from XrdSsiStream.

bool XrdSsiTaskReal::SetBuff ( XrdSsiErrInfo eRef,
char *  buff,
int  blen 
)
virtual

Asynchronously obtain data from a passive stream (client-side only).

Parameters
eRefreference to where error information is to be placed for encountered before during the stream initiation. When data is ready for processing, the ProcessResponseData() callback is called on the request associated with this stream. Also see XrdSsiRequest::GetResponseData() helper method.
buffpointer to the buffer to receive the data. The buffer must remain valid until ProcessResponse() is called.
blenthe length of the buffer (i.e. maximum that can be returned).
Returns
true The stream has been successfully scheduled to return the data.
false The stream could not be scheduled; eRef holds the reason.

Reimplemented from XrdSsiStream.

void XrdSsiTaskReal::SetTaskID ( uint32_t  tid,
uint32_t  sid 
)
inline

References XrdSsiEvent::tident, and tskID.

int XrdSsiTaskReal::XeqEvent ( XrdCl::XRootDStatus status,
XrdCl::AnyObject **  respP 
)
virtual

Implements XrdSsiEvent.

void XrdSsiTaskReal::XeqEvFin ( )
virtual

Implements XrdSsiEvent.

Member Data Documentation

dlQ XrdSsiTaskReal::attList

Referenced by Init().

char* XrdSsiTaskReal::dataBuff
private
int XrdSsiTaskReal::dataRlen
private
int XrdSsiTaskReal::defer
private

Referenced by Init().

XrdSsiErrInfo XrdSsiTaskReal::errInfo
private
XrdCl::AnyObject* XrdSsiTaskReal::mdResp
private

Referenced by Init(), and ~XrdSsiTaskReal().

bool XrdSsiTaskReal::mhPend
private

Referenced by Init().

XrdSsiRequest* XrdSsiTaskReal::rqstP
private

Referenced by Init(), and RequestID().

XrdSsiSessReal* XrdSsiTaskReal::sessP
private
unsigned short XrdSsiTaskReal::tmOut
private

Referenced by Init().

uint32_t XrdSsiTaskReal::tskID
private

Referenced by ID(), and SetTaskID().

TaskStat XrdSsiTaskReal::tStat
private

Referenced by Init().

XrdSysSemaphore* XrdSsiTaskReal::wPost
private

Referenced by Init().


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