Skip to content

Commit

Permalink
Fix high cpu load due to recurring prune job in SDK (eclipse-velocita…
Browse files Browse the repository at this point in the history
  • Loading branch information
BjoernAtBosch authored Apr 4, 2024
1 parent 74e8b17 commit 17fb477
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
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

0 comments on commit 17fb477

Please sign in to comment.