Skip to content
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

Fix high cpu load due to recurring prune job in SDK #96

Merged
merged 3 commits into from
Apr 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions NOTICE-3RD-PARTY-CONTENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
|distlib|0.3.8|Python Software Foundation License|
|distro|1.8.0|Apache 2.0|
|fasteners|0.19|Apache 2.0|
|filelock|3.13.1|The Unlicense (Unlicense)|
|filelock|3.13.3|The Unlicense (Unlicense)|
|gcovr|5.2|BSD|
|identify|2.5.35|MIT|
|idna|3.6|BSD|
|Jinja2|3.1.3|New BSD|
|lxml|5.1.0|New BSD|
|lxml|5.2.1|New BSD|
|MarkupSafe|2.1.5|New BSD|
|node-semver|0.6.1|MIT|
|nodeenv|1.8.0|BSD|
Expand Down
11 changes: 7 additions & 4 deletions app/src/Launcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,21 @@
#include "sdk/Logger.h"

#include <csignal>
#include <memory>

std::unique_ptr<example::SampleApp> myApp;

void signal_handler(int sig) {
velocitas::logger().error("App terminated due to: Signal {}", sig);
exit(-1);
velocitas::logger().info("App terminated due to: Signal {}", sig);
myApp->stop();
}

int main(int argc, char** argv) {
signal(SIGINT, signal_handler);

example::SampleApp myApp;
myApp = std::make_unique<example::SampleApp>();
try {
myApp.run();
myApp->run();
} catch (const std::exception& e) {
velocitas::logger().error("App terminated due to: {}", e.what());
} catch (...) {
Expand Down
2 changes: 1 addition & 1 deletion conanfile.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[requires]
vehicle-model/generated
vehicle-app-sdk/0.5.0
vehicle-app-sdk/0.5.1

[generators]
cmake
Loading