Resource Tuner
|
#include <cstdint>
#include "ErrCodes.h"
#include "Request.h"
#include "RequestQueue.h"
#include "ThreadPool.h"
#include "CocoTable.h"
#include "RateLimiter.h"
#include "RequestManager.h"
#include "ResourceRegistry.h"
#include "PropertiesRegistry.h"
#include "ServerInternal.h"
#include "TargetRegistry.h"
Go to the source code of this file.
Functions | |
ErrCode | fetchProperties () |
Initializes the Properties store. | |
ErrCode | submitResProvisionRequest (void *request) |
Submit a Resource Provisioning Request from a Client for processing. | |
int8_t | submitPropGetRequest (const std::string &prop, std::string &buffer, const std::string &defValue) |
Gets a property from the Config Store. | |
int8_t | submitPropSetRequest (const std::string &prop, const std::string &value) |
Modifies an already existing property in the Config Store. | |
ErrCode | submitPropRequest (void *request) |
Submit an incoming Prop Request from a Client, for processing. | |
ErrCode fetchProperties | ( | ) |
Initializes the Properties store.
This function will read and Parse the Property Config YAML file.
int8_t submitPropGetRequest | ( | const std::string & | prop, |
std::string & | buffer, | ||
const std::string & | defValue | ||
) |
Gets a property from the Config Store.
Note: This API is meant to be used internally, i.e. by other Resource Tuner modules like Signals and not the End-Client Directly. Client Facing APIs are provided in Core/Client/APIs/
prop | Name of the Property to be fetched. |
buffer | A buffer to hold the result, i.e. the property value corresponding to the specified name. |
defValue | Value to return in case a property with the specified Name is not found in the Config Store |
ErrCode submitPropRequest | ( | void * | request | ) |
Submit an incoming Prop Request from a Client, for processing.
This API accepts both Prop Get and Set Requests from the Client, and processes them accordingly.
request | Encapsulation type for the the Prop Request |
int8_t submitPropSetRequest | ( | const std::string & | prop, |
const std::string & | value | ||
) |
Modifies an already existing property in the Config Store.
Note: This API is meant to be used internally i.e. by other Resource Tuner modules like Signals and not the End-Client Directly. Client Facing APIs are provided in Core/Client/APIs/
prop | Name of the Property to be modified. |
value | A buffer holding the new the property value. |
ErrCode submitResProvisionRequest | ( | void * | request | ) |
Submit a Resource Provisioning Request from a Client for processing.
Note: This API acts an interface for other Resource Tuner components like Signals to submit a Resource Provisioning Request to the Resource Tuner Server, and subsequently provision the desired Resources.
request | A buffer holding the Request. |