12#ifndef IOVDBSVC_CORALCRESTMANAGER_H
13#define IOVDBSVC_CORALCRESTMANAGER_H
21#include "CrestApi/CrestApiBase.h"
22#include "CrestApi/CrestRequest.h"
24#include "CoolKernel/ChannelSelection.h"
25#include "CoolKernel/ValidityKey.h"
26#include "CoolKernel/IFolder.h"
31 static inline const std::string
prefix1{
"http://"};
32 static inline const std::string
prefix2 {
"https://"};
36 static std::map<std::string, std::string>
getGlobalTagMap(
const std::string & crest_path,
const std::string& globaltag);
48 std::pair<std::vector<cool::ChannelId> , std::vector<std::string>>
getChannelList();
55 std::vector<std::pair<cool::ValidityKey,std::string>>
getIovsForTag(uint64_t since, uint64_t until);
57 std::vector<coral::AttributeList>
getVectorPayload(coral::AttributeListSpecification* pSpec,
const std::string & chId);
59 coral::AttributeList
getPayload(coral::AttributeListSpecification* pSpec,
const std::string & chId);
61 std::vector<std::string>
channelIds(cool::ValidityKey since);
67 std::optional<Crest::TagDto>
m_Tag;
70 coral::AttributeList
createAttributeList(coral::AttributeListSpecification * pSpec,nlohmann::json& j ,
const std::vector<std::pair<std::string, Crest::TypeId>> & tSpec);
71 std::pair<uint64_t,uint64_t>
getIovInterval(
const std::string& tag,
const uint64_t since,
const uint64_t until);
72 std::pair<uint64_t,uint64_t>
getSinceUntilPair(std::vector<uint64_t>& v,
const uint64_t since,
const uint64_t until);
Header file for CrestContainer class.
static std::map< std::string, std::string > getGlobalTagMap(const std::string &crest_path, const std::string &globaltag)
std::vector< std::pair< cool::ValidityKey, std::string > > getIovsForTag(uint64_t since, uint64_t until)
std::vector< std::string > channelIds(cool::ValidityKey since)
IOVDbNamespace::FolderType determineFolderType()
std::vector< uint64_t > loadPayloadForHash(uint64_t since, const std::string &hash)
std::string dumpPayload(cool::ValidityKey since)
Crest::TagDto & getTagDto()
std::vector< coral::AttributeList > getVectorPayload(coral::AttributeListSpecification *pSpec, const std::string &chId)
void initCrestContainer()
std::optional< Crest::TagMetaDto > m_TagMeta
std::string getFolderDescription()
coral::AttributeList createAttributeList(coral::AttributeListSpecification *pSpec, nlohmann::json &j, const std::vector< std::pair< std::string, Crest::TypeId > > &tSpec)
std::optional< Crest::CrestContainer > m_crest_cont
std::optional< bool > m_isVectorPayload
std::optional< Crest::TagDto > m_Tag
std::string parseTypeName(const std::string &description)
CoralCrestManager(const std::string &crest_path, const std::string &crestTag)
static const std::string prefix1
std::pair< uint64_t, uint64_t > getIovInterval(const std::string &tag, const uint64_t since, const uint64_t until)
std::string getPayloadSpec()
std::pair< std::vector< cool::ChannelId >, std::vector< std::string > > getChannelList()
coral::AttributeList getPayload(coral::AttributeListSpecification *pSpec, const std::string &chId)
std::pair< uint64_t, uint64_t > getSinceUntilPair(std::vector< uint64_t > &v, const uint64_t since, const uint64_t until)
std::unique_ptr< Crest::CrestApiBase > m_crestCl
Crest::TagInfoDto getTagInfoDto()
coral::AttributeListSpecification * getAttributeListSpec()
static const std::string prefix2
const std::string m_crestTag
void selectIov(cool::ValidityKey since)
std::string description
glabal timer - how long have I taken so far?