wrench::XRootD::UpdateCacheMessage

class UpdateCacheMessage : public wrench::XRootD::Message

A message sent to a XRootD Node to update the cache.

Public Functions

UpdateCacheMessage(simgrid::s4u::Mailbox *answer_mailbox, std::shared_ptr<StorageServiceFileReadRequestMessage> original, Node *node, std::shared_ptr<DataFile> file, std::set<std::shared_ptr<FileLocation>> locations, double payload, std::shared_ptr<bool> answered)

Constructor.

Parameters
  • answer_mailbox – The mailbox the final answer should be sent to

  • original – The original file read request being responded too. If this is a file locate search, this should be null

  • node – The node where the search was initiated

  • file – The file that was found

  • locations – All locations that where found in this subtree

  • payload – The message size in bytes

  • answered – A shared boolean for if the answer has been sent to the client. This should be the same for all messages searching for this request. Used to prevent the multiple response problem

UpdateCacheMessage(UpdateCacheMessage &other)

Reference Copy Constructor.

Parameters

other – The message to copy.

UpdateCacheMessage(UpdateCacheMessage *other)

Pointer Copy Constructor.

Parameters

other – The message to copy.

Public Members

simgrid::s4u::Mailbox *answer_mailbox

Mailbox to which the FINAL answer message should be sent.

std::shared_ptr<bool> answered

Whether or not the calling client has been answered yet. Used to prevent answer_mailbox spamming for multiple file hits.

std::shared_ptr<DataFile> file

The file found.

set<std::shared_ptr<FileLocation>> locations

the locations to cache

Node *node

The highest node in the tree to return to when caching (should be the node the original message was sent)

std::shared_ptr<StorageServiceFileReadRequestMessage> original

The original file read request that kicked off the search (if null this was a lookup request)