Skip to content

First version of new API for Launch Manager - #377

Open
SimonKozik wants to merge 3 commits into
eclipse-score:mainfrom
etas-contrib:feature/new-public-api-for-lm
Open

First version of new API for Launch Manager#377
SimonKozik wants to merge 3 commits into
eclipse-score:mainfrom
etas-contrib:feature/new-public-api-for-lm

Conversation

@SimonKozik

Copy link
Copy Markdown
Contributor

First draft of new API for Launch Manager

@github-actions

github-actions Bot commented Jul 28, 2026

Copy link
Copy Markdown

License Check Results

🚀 The license check job ran with the Bazel command:

bazel run --lockfile_mode=error //:license-check

Status: ⚠️ Needs Review

Click to expand output
[License Check Output]
Extracting Bazel installation...
Starting local Bazel server (8.6.0) and connecting to it...
INFO: Invocation ID: b6752bb5-0ea6-48ad-abcb-62bf61f6ced5
Computing main repo mapping: 
Computing main repo mapping: 
Loading: 
Loading: 0 packages loaded
Loading: 0 packages loaded
Loading: 0 packages loaded
    currently loading: 
Loading: 0 packages loaded
    currently loading: 
Loading: 0 packages loaded
    currently loading: 
Analyzing: target //:license-check (1 packages loaded, 0 targets configured)
Analyzing: target //:license-check (1 packages loaded, 0 targets configured)

Analyzing: target //:license-check (37 packages loaded, 10 targets configured)

Analyzing: target //:license-check (80 packages loaded, 10 targets configured)

Analyzing: target //:license-check (89 packages loaded, 17 targets configured)

Analyzing: target //:license-check (144 packages loaded, 2767 targets configured)

Analyzing: target //:license-check (156 packages loaded, 5498 targets configured)

Analyzing: target //:license-check (161 packages loaded, 5541 targets configured)

Analyzing: target //:license-check (161 packages loaded, 5547 targets configured)

Analyzing: target //:license-check (162 packages loaded, 5547 targets configured)

Analyzing: target //:license-check (164 packages loaded, 7434 targets configured)

Analyzing: target //:license-check (166 packages loaded, 8406 targets configured)

Analyzing: target //:license-check (167 packages loaded, 10275 targets configured)

Analyzing: target //:license-check (168 packages loaded, 10283 targets configured)

Analyzing: target //:license-check (168 packages loaded, 10283 targets configured)

Analyzing: target //:license-check (168 packages loaded, 10283 targets configured)

INFO: Analyzed target //:license-check (169 packages loaded, 10409 targets configured).
[14 / 16] [Prepa] JavaToolchainCompileBootClasspath external/rules_java+/toolchains/platformclasspath.jar
[15 / 16] Building license.check.license_check.jar (); 0s disk-cache, multiplex-worker
INFO: Found 1 target...
Target //:license.check.license_check up-to-date:
  bazel-bin/license.check.license_check
  bazel-bin/license.check.license_check.jar
INFO: Elapsed time: 28.777s, Critical Path: 2.56s
INFO: 16 processes: 12 internal, 3 processwrapper-sandbox, 1 worker.
INFO: Build completed successfully, 16 total actions
INFO: Running command line: bazel-bin/license.check.license_check ./formatted.txt <args omitted>
usage: org.eclipse.dash.licenses.cli.Main [-batch <int>] [-cd <url>]
       [-confidence <int>] [-ef <url>] [-excludeSources <sources>] [-help] [-lic
       <url>] [-project <shortname>] [-repo <url>] [-review] [-summary <file>]
       [-timeout <seconds>] [-token <token>]

@github-actions

Copy link
Copy Markdown

The created documentation from the pull request is available at: docu-html

@paulquiring

Copy link
Copy Markdown
Contributor

It looks like it could work. To see if this if this is the right fit in combination with score::mw::com a test would be good before we switch to this.

@paulquiring
paulquiring self-requested a review July 29, 2026 05:29

/// @brief Activation happened automatically as part of a recovery action,
/// without an explicit State Manager request.
kRecoveryAction = 1

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should add reason

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume this will mean we need to adapt ActivationCallback then.
https://github.com/eclipse-score/lifecycle/pull/377/changes#diff-0112cf4be18e494bec2720f425278091273c52be4ffbe12f527cd85178077895R66-R67

Do you have something in mind?

@pawelrutkaq
pawelrutkaq self-requested a review July 29, 2026 08:30
@NicolasFussberger

Copy link
Copy Markdown
Contributor

It looks like it could work. To see if this if this is the right fit in combination with score::mw::com a test would be good before we switch to this.

I like this suggestion. Would it be possible to add a dummy details/lm_controlimpl.hpp with a test that just shows how the API interaction would look like from the users perspective?

Comment thread score/launch_manager/src/lm_control/src/fixed_string.hpp
/// @error kRunTargetDoesntExist Name of the requested Run Target does not exist in current configuration.
/// @error kCommunicationError Connection with Launch Manager cannot be established and request cannot be
/// sent.
virtual score::Result<void> activate_run_target(std::string_view runTargetName, bool force = false) = 0;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this not be RunTargetName

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@NicolasFussberger do you remember why we went with std::string_view here?

I have feeling that RunTargetName maybe better here... As this is what probably will travel through mw::com

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For consistency, RunTargetName is probably better.
Depending on how the data is represented in the mw::com interface it may then require an additional copy though.

Comment thread score/launch_manager/src/lm_control/src/ilm_control.hpp
/// @error kCallbackInProgress A new callback cannot be registered because the
/// current callback is still executing. Retry after it returns.
/// @error kInvalidArguments The callback is empty.
virtual score::Result<void> register_run_target_activation_callback(ActivationCallback callback) = 0;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK within the context of the callback, you may not call other mw::methods / send events.
If this is true, it is not easily supported to trigger the next run target activation after the previous one finished (in the scope of the callback). User would need to store the information provided by the callback and then pick this up from a different thread.

@eduard-moskalchuk do you have some insights if this is true?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

5 participants