XrdCmsClientConfig.hh

Go to the documentation of this file.
00001 #ifndef _CMS_CLIENTCONFIG_H
00002 #define _CMS_CLIENTCONFIG_H
00003 /******************************************************************************/
00004 /*                                                                            */
00005 /*                 X r d C m s C l i e n t C o n f i g . h h                  */
00006 /*                                                                            */
00007 /* (c) 2007 by the Board of Trustees of the Leland Stanford, Jr., University  */
00008 /*                            All Rights Reserved                             */
00009 /*   Produced by Andrew Hanushevsky for Stanford University under contract    */
00010 /*              DE-AC02-76-SFO0515 with the Department of Energy              */
00011 /******************************************************************************/
00012 
00013 //          $Id: XrdCmsClientConfig.hh 24468 2008-06-22 16:47:03Z ganis $
00014 
00015 #include "XrdOuc/XrdOucTList.hh"
00016 #include "XrdOuc/XrdOuca2x.hh"
00017   
00018 class XrdOucStream;
00019 class XrdSysError;
00020 
00021 #define ODC_FAILOVER 'f'
00022 #define ODC_ROUNDROB 'r'
00023   
00024 class XrdCmsClientConfig
00025 {
00026 public:
00027 
00028 enum configHow  {configMeta   = 1, configNorm  = 2, configProxy  = 4};
00029 enum configWhat {configMan    = 1, configSuper = 2, configServer = 4};
00030 
00031 int           Configure(char *cfn, configWhat What, configHow How);
00032 
00033 int           ConWait;      // Seconds to wait for a manager connection
00034 int           RepWait;      // Seconds to wait for manager replies
00035 int           RepWaitMS;    // RepWait*1000 for poll()
00036 int           RepDelay;     // Seconds to delay before retrying manager
00037 int           RepNone;      // Max number of consecutive non-responses
00038 int           PrepWait;     // Millisecond wait between prepare requests
00039 int           haveMeta;     // Have a meta manager (only if we are a manager)
00040 
00041 char         *CMSPath;      // Path to the local cmsd for target nodes
00042 char         *myHost;
00043 const char   *myName;
00044 
00045 XrdOucTList  *ManList;      // List of managers for remote redirection
00046 XrdOucTList  *PanList;      // List of managers for proxy  redirection
00047 unsigned char SMode;        // Manager selection mode
00048 unsigned char SModeP;       // Manager selection mode (proxy)
00049 
00050 enum {FailOver = 'f', RoundRob = 'r'};
00051 
00052       XrdCmsClientConfig()
00053                   {ConWait = 10; RepWait = 3; RepWaitMS = 3000; RepDelay = 5;
00054                    PrepWait = 33; ManList = PanList = 0;
00055                    SMode = SModeP = FailOver;
00056                    CMSPath = 0; RepNone = 8; isMeta = 0; haveMeta = 0;
00057                   }
00058      ~XrdCmsClientConfig();
00059 
00060 private:
00061 int isMeta;   // We are  a meta manager
00062 int isMan;    // We are  a      manager
00063 
00064 int ConfigProc(char *cfn);
00065 int ConfigXeq(char *var, XrdOucStream &Config);
00066 int xapath(XrdOucStream &Config);
00067 int xconw(XrdOucStream  &Config);
00068 int xmang(XrdOucStream  &Config);
00069 int xreqs(XrdOucStream  &Config);
00070 int xtrac(XrdOucStream  &Config);
00071 };
00072 #endif

Generated on Tue Jul 5 14:46:23 2011 for ROOT_528-00b_version by  doxygen 1.5.1