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

Unsupported runtime not handled properly #370

Open
krucod3 opened this issue Sep 5, 2024 · 3 comments
Open

Unsupported runtime not handled properly #370

krucod3 opened this issue Sep 5, 2024 · 3 comments
Assignees
Labels
bug Something isn't working. Issue will appear in the change log "Bug Fixes" minor Minor bug
Milestone

Comments

@krucod3
Copy link
Contributor

krucod3 commented Sep 5, 2024

Currently setting the runtime of a workload to something wrong is not handled correctly.

Current Behavior

If a workload is initially scheduled with a wrong runtime name, the workload stays in a Pending(Initial) state.
Additionally if the runtime is changed for a running workload, a retry (20 times) is started to schedule the workload to the new not existing runtime.

The ank CLI also did not exit after updating the workload back to an existing workload as it never received a removed for the old workload.

Expected Behavior

The starting of the workload shall fail.

Steps to Reproduce

  1. create a workload with a not existing runtime name, e.g., "not_existing"
  2. observe the workload states

Or

  1. update a running workload to use a not existing runtime name, e.g., "not_existing"
  2. observe the workload states

Context (Environment)

Logs

Additional Information

Final result

To be filled by the one closing the issue.

@krucod3 krucod3 added the bug Something isn't working. Issue will appear in the change log "Bug Fixes" label Sep 5, 2024
@krucod3
Copy link
Contributor Author

krucod3 commented Sep 10, 2024

The initial definition of a workload with an unknown runtime can be fixed by adding the following to the runtime_manager.rs add_workload method:

            self.update_state_tx
                .report_workload_execution_state(
                    &workload_spec.instance_name,
                    ExecutionState::starting_failed(format!(
                        "Runtime '{}' not found.",
                        workload_spec.runtime
                    )),
                )
                .await;

@krucod3 krucod3 added this to the v0.5 milestone Sep 19, 2024
@windsource windsource added the minor Minor bug label Oct 2, 2024
@krucod3 krucod3 self-assigned this Oct 29, 2024
@krucod3
Copy link
Contributor Author

krucod3 commented Nov 5, 2024

Let's shift this to the v0.6 as it is a minor and we don't have the time for it now.

@krucod3 krucod3 modified the milestones: v0.5, v0.6 Nov 5, 2024
@windsource
Copy link
Contributor

I think we should handle an unsupported runtime for a specific agent. In general, if a startup configuration is provided and no agent is registered, then all runtimes will be unsupported. Only an agent knows which runtimes it supports. But I think @krucod3, that is what you mean, or?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working. Issue will appear in the change log "Bug Fixes" minor Minor bug
Projects
None yet
Development

No branches or pull requests

2 participants