tdaq-develop-2025-02-12
ots::RemoteWebUsers Class Reference

#include <otsdaq/WebUsersUtilities/RemoteWebUsers.h>

Inheritance diagram for ots::RemoteWebUsers:
ots::SOAPMessenger

Public Member Functions

 RemoteWebUsers (xdaq::Application *application, XDAQ_CONST_CALL xdaq::ApplicationDescriptor *gatewaySupervisorDescriptor)
 
bool xmlRequestToGateway (cgicc::Cgicc &cgi, std::ostringstream *out, HttpXmlDocument *xmldoc, const AllSupervisorInfo &allSupervisorInfo, WebUsers::RequestUserInfo &userInfo)
 
std::string getActiveUserList (void)
 
void sendSystemMessage (const std::string &toUser, const std::string &message, bool doEmail=false)
 
void sendSystemMessage (const std::string &toUser, const std::string &subject, const std::string &message, bool doEmail=false)
 
void makeSystemLogEntry (const std::string &entryText)
 
std::pair< std::string, TableGroupKeygetLastTableGroup (const std::string &actionOfLastGroup, std::string &returnedActionTimeString)
 actionOfLastGroup = "Configured" or "Started", for example More...
 
void getLastTableGroups (std::map< std::string, std::tuple< std::string, TableGroupKey, std::string >> &theGroups)
 
- Public Member Functions inherited from ots::SOAPMessenger
 SOAPMessenger (xdaq::Application *application)
 
 SOAPMessenger (const SOAPMessenger &aSOAPMessenger)
 
std::string send (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, xoap::MessageReference message)
 
std::string send (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, SOAPCommand soapCommand)
 
std::string send (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, std::string command)
 
std::string send (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, std::string command, SOAPParameters parameters)
 
std::string sendStatus (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, std::string message)
 
xoap::MessageReference sendWithSOAPReply (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, xoap::MessageReference message)
 
xoap::MessageReference sendWithSOAPReply (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, SOAPCommand soapCommand)
 
xoap::MessageReference sendWithSOAPReply (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, std::string command)
 
xoap::MessageReference sendWithSOAPReply (XDAQ_CONST_CALL xdaq::ApplicationDescriptor *d, std::string command, SOAPParameters parameters)
 

Public Attributes

XDAQ_CONST_CALL xdaq::ApplicationDescriptor * gatewaySupervisorDescriptor_
 

Additional Inherited Members

- Protected Attributes inherited from ots::SOAPMessenger
xdaq::Application * theApplication_
 

Detailed Description

RemoteWebUsers This class provides the functionality for client supervisors to check with the Gateway Supervisor to verify user access. It also provides the functionality for client supervisors to retreive user info.

Definition at line 22 of file RemoteWebUsers.h.

Constructor & Destructor Documentation

◆ RemoteWebUsers()

RemoteWebUsers::RemoteWebUsers ( xdaq::Application *  application,
XDAQ_CONST_CALL xdaq::ApplicationDescriptor *  gatewaySupervisorDescriptor 
)

User Notes:

  • use xmlRequestGateway to check security from outside the Supervisor and Wizard

Example usage: at void CoreSupervisorBase::requestWrapper(xgi::Input* in, xgi::Output* out)

Definition at line 30 of file RemoteWebUsers.cc.

Member Function Documentation

◆ getActiveUserList()

std::string RemoteWebUsers::getActiveUserList ( void  )

getActiveUserList if lastUpdateTime is not too recent as spec'd by ACTIVE_USERS_UPDATE_THRESHOLD if server responds with

Definition at line 173 of file RemoteWebUsers.cc.

◆ getLastTableGroup()

std::pair< std::string, TableGroupKey > RemoteWebUsers::getLastTableGroup ( const std::string &  actionOfLastGroup,
std::string &  actionTimeString 
)

actionOfLastGroup = "Configured" or "Started", for example

getLastTableGroup request last "Configured" or "Started" group, for example returns empty "" for actionTimeString on failure returns "Wed Dec 31 18:00:01 1969 CST" for actionTimeString (in CST) if action never has occurred

Definition at line 261 of file RemoteWebUsers.cc.

◆ getLastTableGroups()

void RemoteWebUsers::getLastTableGroups ( std::map< std::string, std::tuple< std::string, TableGroupKey, std::string >> &  theGroups)

getLastTableGroups request last "Configured" or "Started" group, for example returns empty "" for actionTimeString on failure returns "Wed Dec 31 18:00:01 1969 CST" for actionTimeString (in CST) if action never has occurred

Definition at line 200 of file RemoteWebUsers.cc.

◆ makeSystemLogEntry()

void RemoteWebUsers::makeSystemLogEntry ( const std::string &  entryText)

makeSystemLogEntry make system logbook through Supervisor

Definition at line 329 of file RemoteWebUsers.cc.

◆ sendSystemMessage() [1/2]

void RemoteWebUsers::sendSystemMessage ( const std::string &  toUser,
const std::string &  message,
bool  doEmail = false 
)

sendSystemMessage send system message to toUser through Supervisor toUser wild card * is to all users

Definition at line 298 of file RemoteWebUsers.cc.

◆ sendSystemMessage() [2/2]

void RemoteWebUsers::sendSystemMessage ( const std::string &  toUser,
const std::string &  subject,
const std::string &  message,
bool  doEmail = false 
)

sendSystemMessage send system message to toUser comma separate variable (CSV) list through Supervisor toUser wild card * is to all users

Definition at line 309 of file RemoteWebUsers.cc.

◆ xmlRequestToGateway()

bool RemoteWebUsers::xmlRequestToGateway ( cgicc::Cgicc &  cgi,
std::ostringstream *  out,
HttpXmlDocument xmldoc,
const AllSupervisorInfo allSupervisorInfo,
WebUsers::RequestUserInfo userInfo 
)

for external supervisors to check with Supervisor for login if false, user request handling code should just return.. out is handled on false; on true, out is untouched

xmlRequestGateway if false, user code should just return.. out is handled on false; on true, out is untouched

Definition at line 44 of file RemoteWebUsers.cc.

Member Data Documentation

◆ gatewaySupervisorDescriptor_

XDAQ_CONST_CALL xdaq::ApplicationDescriptor* ots::RemoteWebUsers::gatewaySupervisorDescriptor_

const_cast away the const so that this line is compatible with slf6 and slf7 versions of xdaq where they changed to XDAQ_CONST_CALL xdaq::ApplicationDescriptor* in slf7

XDAQ_CONST_CALL is defined in "otsdaq/Macros/CoutMacros.h"

Definition at line 34 of file RemoteWebUsers.h.


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