-
Notifications
You must be signed in to change notification settings - Fork 6
Launcher implementation #342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Launcher implementation #342
Conversation
This patch adds a new identifier pool utility to the common tools library. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch adds cloudprotocol state structures. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch adds storage state interfaces to the cm module. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch makes it possible to use instance ident with STL containers that require a less operator. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch adds support for the SHA3-224 hash algorithm in the crypto provider. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch enhances the platform filesystem interface by adding a method to set user quota. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch removes the redundant definition of the SHA1 digest size in the configuration header file. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
This patch adds a new communication interface to the cm module with API needed for storage state module. Signed-off-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Mykola Solianko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]> Reviewed-by: Mykola Solianko <[email protected]>
Signed-off-by: Mykola Solianko <[email protected]> Reviewed-by: Mykhailo Lohvynenko <[email protected]> Reviewed-by: Mykola Kobets <[email protected]> Reviewed-by: Oleksandr Grytsov <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
InstanceIdent-s should be sorted by service, then subject, then instance ind. Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
Signed-off-by: Mykola Kobets <[email protected]>
1891ddc
to
ad33223
Compare
/** | ||
* Max number of allowed connections. | ||
*/ | ||
static constexpr auto cMaxNumConnections = AOS_CONFIG_NETWORKMANAGER_CONNECTIONS_PER_INSTANCE_MAX_COUNT; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we have to rename config options to
AOS_CONFIG_CONNECTIONS_PER_INSTANCE_MAX_COUNT
AOS_CONFIG_CONNECTION_NAME_LEN
accordingly. And create appropriate consts int types.hpp then use these consts for NetworkManager and spec.
@@ -113,6 +113,20 @@ class IdentifierRangePool : public NonCopyable { | |||
return ErrorEnum::eNone; | |||
} | |||
|
|||
/** | |||
* Clear identifier in pool. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Clears
* @param value value to check for existence. | ||
* @return bool. | ||
*/ | ||
bool Exist(const T& value) const { return Find(value) != end(); } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just wrapper around Find and FindIf. Do we need it?
@@ -1586,6 +1586,17 @@ class InstanceStateType { | |||
using InstanceStateEnum = InstanceStateType::Enum; | |||
using InstanceState = EnumStringer<InstanceStateType>; | |||
|
|||
/** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be part of cloudprotocol desired status: cloudprotocol.InstanceInfo
/** | ||
* Auxiliary class to accumulate node information. | ||
*/ | ||
class NodeHandler { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move node hander and related structs to nodehandler.hpp
} | ||
|
||
if (auto err = RemoveOutdatedInstances(); !err.IsNone()) { | ||
LOG_ERR() << "Can't remove outdated instances" << Log::Field(err); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
void InstanceManager::OnServiceRemoved(const String& serviceID) | ||
{ | ||
(void)serviceID; | ||
// TODO: Clarify what to do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove all cached instances that belong to this service, cleanup state/storage.
If there are active instances, error should be returned.
* @param serviceVersion version of the service. | ||
* @param err Error. | ||
*/ | ||
void SetInstanceError(const InstanceIdent& id, const String& serviceVersion, const Error& err); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
id -> instanceIdent
* @param[out] info output structure to hold instance information. | ||
* @return Error. | ||
*/ | ||
Error GetInstanceInfo(const InstanceIdent& id, storage::InstanceInfo& info); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
|
||
Error InstanceManager::UpdateInstanceCache() | ||
{ | ||
auto instances = MakeUnique<StaticArray<storage::InstanceInfo, cMaxNumInstances>>(&mAllocator); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
empty line
No description provided.